-
Notifications
You must be signed in to change notification settings - Fork 2
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
adds anr run rerun/examples/minimal #30
- Loading branch information
1 parent
58a3725
commit 2780d16
Showing
5 changed files
with
71 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,15 @@ | ||
# minimal | ||
|
||
## Download scripts | ||
wget https://raw.githubusercontent.com/rerun-io/rerun/main/examples/python/minimal/requirements.txt | ||
wget https://raw.githubusercontent.com/rerun-io/rerun/main/examples/python/minimal/main.py | ||
|
||
|
||
## Run scripts | ||
mamba activate rrVE | ||
pip install -r requirements.txt | ||
python main.py | ||
|
||
|
||
## Reference | ||
https://github.com/rerun-io/rerun/tree/main/examples/python/minimal |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,18 @@ | ||
#!/usr/bin/env python3 | ||
"""Demonstrates the most barebone usage of the Rerun SDK.""" | ||
from __future__ import annotations | ||
|
||
import sys | ||
|
||
import numpy as np | ||
import rerun as rr # pip install rerun-sdk | ||
|
||
# sanity-check since all other example scripts take arguments: | ||
assert len(sys.argv) == 1, f"{sys.argv[0]} does not take any arguments" | ||
|
||
rr.init("rerun_example_minimal", spawn=True) | ||
|
||
positions = np.vstack([xyz.ravel() for xyz in np.mgrid[3 * [slice(-10, 10, 10j)]]]).T | ||
colors = np.vstack([rgb.ravel() for rgb in np.mgrid[3 * [slice(0, 255, 10j)]]]).astype(np.uint8).T | ||
|
||
rr.log("my_points", rr.Points3D(positions, colors=colors, radii=0.5)) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,2 @@ | ||
numpy | ||
rerun-sdk |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,30 @@ | ||
## Some useful commands to manage your conda env: | ||
## LIST MAMBA ENVS: mamba list -n *VE # show list of installed packages | ||
## UPDATE MAMBA: mamba update -n base mamba | ||
## INSTALL MAMBA EV: mamba env create -f *VE.yml | ||
## UPDATE MAMBA ENV: mamba env update -f *VE.yml --prune | ||
## ACTIVATE MAMBA ENV: mamba activate *VE | ||
## REMOVE MAMBA ENV: mamba remove -n *VE --all | ||
|
||
name: rrVE | ||
channels: | ||
- conda-forge | ||
dependencies: | ||
- python=3.11 | ||
- pip | ||
- pip: | ||
- rerun-sdk | ||
#- matplotlib | ||
#- opencv-python | ||
#- scikit-learn | ||
#- notebook | ||
#- pandas | ||
#- seaborn | ||
#- opencv-contrib-python-headless #https://pypi.org/project/opencv-contrib-python-headless/#history | ||
#- araviq6 | ||
#- civiq6 | ||
#- cv2PySide6 | ||
#- qimage2ndarray | ||
#- numpy | ||
|
||
|