Skip to content

Latest commit

ย 

History

32 Commits

Folders and files

NameName
Last commit message
Last commit date
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 

Repository files navigation

โ„๏ธ Andrei's 2023 Advent of Code โ„๏ธ

Build Status

Learning Goals

  • Finish the first 12 days for Rust practice
  • Use tch in at least 5 problems
  • Dockerized CI with tch support for fun
  • Actually understand Rust-y implementations of cyclic data structures

Running the Code

The following instructions set up Torch support, albeit without GPU by default. They are geared towards Apple Silicon, though they should work OK on x86 as well.

  1. Set up Cargo

  2. Enable nightly Rust with rustup, since the project needs features currently only on nightly, like benchmarking support.

  3. Set up a Python Anaconda environment and activate it.

  4. Install PyTorch in this environment: conda install pytorch::pytorch torchvision torchaudio -c pytorch

    • Do not enable LIBTORCH_USE_PYTORCH.
  5. Now you can finally build and run problems:

cargo run --release --bin <XX_problem>

Special thanks to this repo for a simple example of running Torch and its Rust bindings!

See Also

About

๐Ÿ”” Continuing to learn Rust with AoC 2023 ๐ŸฆŒ https://adventofcode.com/2023/

Resources

Stars

0 stars

Watchers

1 watching

Forks

Releases

Packages

Used by

Contributors

Languages