Singularity is similar to docker used mostly for cluster tasks. I am having issues using Python api with it. I used:
singularity run --nv docker://stereolabs/zed:3.5-runtime-cuda11.0-ubuntu18.04
Dependencies are fine (nvidia-smi
)
The problem is permissions are screwed up:
>>> import pyzed
>>> import pyzed.sl
Traceback (most recent call last):
File "<stdin>", line 1, in <module>
ModuleNotFoundError: No module named 'pyzed.sl'
It happens because
Singularity> ls /usr/local/zed/
ls: cannot open directory '/usr/local/zed/': Permission denied
Singularity> ls /usr/local/lib/python3.6/dist-packages/pyzed
ls: cannot open directory '/usr/local/lib/python3.6/dist-packages/pyzed': Permission denied
I assume this is because singularity inherits system privilege and you don’t typically use it with root. Does anyone know if there are any easy workarounds? It currently seems likely impossible to use zed api if you don’t have any root.