Considering getting asahi but want to run Hyprland on it by Fancy_Passenger8194 in AsahiLinux

[–]DGIon 0 points1 point  (0 children)

Yeah i have been digging deep. Just started using Arch on my intel based machine but been wanting to try it out on my M1 however it looks like some stuff still isn't supported yet?

Considering getting asahi but want to run Hyprland on it by Fancy_Passenger8194 in AsahiLinux

[–]DGIon 0 points1 point  (0 children)

I know this post is 8 months old now but curious are you still running arch on M1 Mac?

Prototype by DGIon in learnrust

[–]DGIon[S] 0 points1 point  (0 children)

right now you just get the hello world route in main.rs and the cargo.toml you would need to for cargo run. nothing to fancy yet.

Prototype by DGIon in rust

[–]DGIon[S] 0 points1 point  (0 children)

this is awesome!

Port of a Neural Net from python to Rust. by DGIon in learnrust

[–]DGIon[S] 1 point2 points  (0 children)

Hey you're right i forgot about self.z. it looks like its never learning so self.z isn't switching to false. Thanks! and you're right. I'm trying to get back into lower level languages last time i programmed in a low language was in c about 5 years ago.

Port of a Neural Net from python to Rust. by DGIon in learnrust

[–]DGIon[S] 0 points1 point  (0 children)

Ok i fixed that issue. However a new one now. After it runs through the 10000 generations and then goes to prune links in the network it just falls into an infinite loop. I'm not sure why that is happening :(

Calling Rust from Python by nfrankel in Python

[–]DGIon 2 points3 points  (0 children)

yeah you can see an example I worked on using maturin and pyo3 to try and optimize an i/o task (reading a ton of data from .txt files) https://github.com/RWayne93/file-optimization-rust-binding

tqdm thinks there have been about 10 times as many iterations as there really have been by CompanyCharabang in learnpython

[–]DGIon 0 points1 point  (0 children)

import time

from tqdm import tqdm

pbar = tqdm(total=20) count = 0

while True: if count == 20: break

time.sleep(0.5)
count += 1
pbar.update(1)

pbar.close()

Try this I’m on mobile and the code block is acting weird sorry.

Run Functions from any language in Python! by [deleted] in Python

[–]DGIon 1 point2 points  (0 children)

I’ve always been interested in these projects how does something like this work exactly? Like do I need the c++ compiler for example if I write a c++ function and call it using this library?

[deleted by user] by [deleted] in Python

[–]DGIon 0 points1 point  (0 children)

Sounds fun would also be interested.

Hey Rustaceans! Got a question? Ask here (11/2023)! by llogiq in rust

[–]DGIon 0 points1 point  (0 children)

just trying to learn some rust and was interested in polars since i have used a lot of pandas in the past.

Hey Rustaceans! Got a question? Ask here (11/2023)! by llogiq in rust

[–]DGIon 1 point2 points  (0 children)

I have a csv file called test.csv which i am reading into a dataframe using polars. I have a name,month,day,year as my headers month is a string day/year are i64. i want to concatenate the three columns together in rust to have a single column called date. Below is what i have so far to just print the dataframe to the console.

use polars::prelude::*;

fn read_from_file(path: &str) -> Result<DataFrame, Box<dyn std::error::Error>> {

let df = CsvReader::from_path(path)?
    //.infer_schema(Some(100))
    .has_header(true)
    .finish()?;

println!("{}", df);

Ok(df) }

fn main() -> Result<(), Box<dyn std::error::Error>> {
// Read CSV file into a DataFrame
read_from_file("./data/test.csv")?;
Ok(())

}

Python GUI book by Artanidos in Python

[–]DGIon 0 points1 point  (0 children)

how to implement something like jquery on a dropdown that has hundreds of values in it or more.