Skip to content

Instantly share code, notes, and snippets.

@rahulbhadani
Last active May 13, 2025 16:44
Show Gist options
  • Save rahulbhadani/b7ef3fef542b7ddc10ffd85c89c4fcf1 to your computer and use it in GitHub Desktop.
Save rahulbhadani/b7ef3fef542b7ddc10ffd85c89c4fcf1 to your computer and use it in GitHub Desktop.

Installing Rust and Cargo

curl https://sh.rustup.rs -sSf | sh

Installing UV

curl -LsSf https://astral.sh/uv/install.sh | sh

Close the terminal and reopen it.

Creating Python Virtual Environment

mkdir -p playground/stream
cd playground/stream
uv python install 3.12
uv init --name stream --no-package
uv venv --python 3.12
# activate virtual environment
source .venv/bin/activate
uv add strym
uv add ipykernel
uv add notebook

The above has to be done one time only.

For the subsequent session, do the following, after opening the new terminal

If you have an existing conda environment, deactivate using conda deactivate. If you have any other python virtual environment, deactivate that as well.

Using strym

cd playground/stream
source .venv/bin/activate
jupyter notebook

It will launch the jupyter notebook.

Create a new notebook, and add the following code:

import strym
from strym import strymread
# change the file name as per your convenience
file = "2021-06-04-12-01-39_2T3MWRFVXLW056972_CAN_Messages.csv"
r = strymread(file)
r.speed()

If you see the speed dataframe, it means strym is read to be used by you.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment