
Good morning, I am currently trying to create a python script that hides atoms and shows ribbons in a .pdb file. However, I am getting an error while trying to initialize a session. I've been trying to debug the problem to the best of my ability, but I am unable to figure out the issue. My code: ``` import chimerax.core.session as cxsession session = cxsession.Session('name') ``` My error: ``` File "./test.py", line 15, in <module> session = cxsession.Session('name') File "/opt/UCSF/ChimeraX/lib/python3.7/site-packages/chimerax/core/session.py", line 437, in __init__ self.app_name = app_name File "/opt/UCSF/ChimeraX/lib/python3.7/site-packages/chimerax/core/session.py", line 508, in __setattr__ if not name.startswith('_') and self.snapshot_methods(value, base_type=StateManager) is not None: File "/opt/UCSF/ChimeraX/lib/python3.7/site-packages/chimerax/core/session.py", line 535, in snapshot_methods from .serialize import PRIMITIVE_TYPES File "/opt/UCSF/ChimeraX/lib/python3.7/site-packages/chimerax/core/serialize.py", line 42, in <module> from ._serialize import msgpack_serialize_stream, msgpack_deserialize_stream, PRIMITIVE_TYPES ImportError: libpython3.7m.so.1.0: cannot open shared object file: No such file or directory ``` I look forward to your assistance. Best, Alexander -- *Alexander T. Julian* PhD Student, Department of Biology, Microbiology Bachelor of Science, Biomedical Engineering, Cell and Tissue Specialization 2021 Master of Advanced Study, Chemical Engineering 2021 Illinois Institute of Technology Chicago, IL 60616 *Phone (727)-735-7104*

Hi Alexander, Your error says it can't import libpython3.7m.so the Python language system library. That suggests that you ran your test.py script in a strange way. A few ways to run your Python script are $ chimerax test.py Don't start a graphical user interface. $ chimerax --nogui.py Start ChimeraX and after it starts use a ChimeraX command to open the script $ chimerax ChimeraX command "open test.py" Tom
On Apr 22, 2021, at 8:34 AM, Alexander Julian <ajulian@hawk.iit.edu> wrote:
Good morning,
I am currently trying to create a python script that hides atoms and shows ribbons in a .pdb file.
However, I am getting an error while trying to initialize a session. I've been trying to debug the problem to the best of my ability, but I am unable to figure out the issue.
My code: ``` import chimerax.core.session as cxsession session = cxsession.Session('name') ```
My error: ``` File "./test.py", line 15, in <module> session = cxsession.Session('name') File "/opt/UCSF/ChimeraX/lib/python3.7/site-packages/chimerax/core/session.py", line 437, in __init__ self.app_name = app_name File "/opt/UCSF/ChimeraX/lib/python3.7/site-packages/chimerax/core/session.py", line 508, in __setattr__ if not name.startswith('_') and self.snapshot_methods(value, base_type=StateManager) is not None: File "/opt/UCSF/ChimeraX/lib/python3.7/site-packages/chimerax/core/session.py", line 535, in snapshot_methods from .serialize import PRIMITIVE_TYPES File "/opt/UCSF/ChimeraX/lib/python3.7/site-packages/chimerax/core/serialize.py", line 42, in <module> from ._serialize import msgpack_serialize_stream, msgpack_deserialize_stream, PRIMITIVE_TYPES ImportError: libpython3.7m.so.1.0: cannot open shared object file: No such file or directory ```
I look forward to your assistance.
Best, Alexander
-- Alexander T. Julian PhD Student, Department of Biology, Microbiology Bachelor of Science, Biomedical Engineering, Cell and Tissue Specialization 2021 Master of Advanced Study, Chemical Engineering 2021 Illinois Institute of Technology Chicago, IL 60616 Phone (727)-735-7104 _______________________________________________ ChimeraX-users mailing list ChimeraX-users@cgl.ucsf.edu Manage subscription: https://www.rbvi.ucsf.edu/mailman/listinfo/chimerax-users
participants (2)
-
Alexander Julian
-
Tom Goddard