questions about python version in sniper

87 views
Skip to first unread message

Ryan

unread,
Jul 20, 2019, 10:56:26 PM7/20/19
to Sniper simulator
Hi, when i tried to import numpy and torch in sniper scripts, i got this error:
python2.7.2.jpg

it  indicates that the python version used by the sniper is 2.7.2. but my python version actually is 2.7.15, if i type python on terminal and import numpy, i got correct result:
python2.7.15.jpg



where's wrong? how can i use numpy within sniper?  thanks!

Kamil Khan

unread,
Jul 22, 2019, 9:06:00 PM7/22/19
to Sniper simulator
Sniper uses its own stripped version of python. It may not include some of Numpy's dependencies. 

Ryan

unread,
Jul 25, 2019, 9:03:28 AM7/25/19
to Sniper simulator
thanks for your reply! I think so too. Is the python version used by sniper can be specified?
What can I do to make the sniper support extra python libraries? For example, calling local site-packages directly...

khyati

unread,
Jan 3, 2025, 4:01:12 AMJan 3
to Sniper simulator
Hi, 
Were you able to solve this issue? I am facing something similar. I want to run sniper within a conda env which has all the required python packages installed. Currently, I am unable to run even python code that imports torch.

Thanks,
Khyati

Reply all
Reply to author
Forward
0 new messages