<div dir="ltr">Tom, Eric, Greg-<div><br></div><div>Thank you so much for your responses. This is extremely helpful. I have a few options now, and I'm definitely unblocked. I'm especially interested in trying to use a ChimeraX server-- I can see that being really helpful to reduce the memory footprint of docker images.</div><div><br></div><div>My first step will be to just use subprocess to directly call the chimerax executable. That will certainly get the job done. My next step would be to try using chimerax as the python interpreter. From there, I'll take stock and see what's important to look at next.</div><div><br></div><div>Thanks so much again for your help!</div></div><br><div class="gmail_quote"><div dir="ltr" class="gmail_attr">On Tue, Jul 6, 2021 at 3:15 PM Tom Goddard <<a href="mailto:goddard@sonic.net">goddard@sonic.net</a>> wrote:<br></div><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex"><div style="overflow-wrap: break-word;">Here's a bit more info on installing a PyPi package in ChimeraX on Windows<div><br></div><div><span style="white-space:pre-wrap"> </span><a href="https://www.rbvi.ucsf.edu/pipermail/chimerax-users/2021-June/002304.html" target="_blank">https://www.rbvi.ucsf.edu/pipermail/chimerax-users/2021-June/002304.html</a></div><div><br></div><div>And if you are still interested in compiling ChimeraX there is info about that in the programming manual</div><div><br></div><div><span style="white-space:pre-wrap"> </span><a href="https://www.cgl.ucsf.edu/chimerax/docs/devel/building.html" target="_blank">https://www.cgl.ucsf.edu/chimerax/docs/devel/building.html</a></div><div><br></div><div> Tom</div><div><br><div><br><blockquote type="cite"><div>On Jul 6, 2021, at 12:21 PM, Tom Goddard <<a href="mailto:goddard@sonic.net" target="_blank">goddard@sonic.net</a>> wrote:</div><br><div><div style="overflow-wrap: break-word;">If you want to install additional PyPi packages into the ChimeraX Python use<div><br></div><div><span style="white-space:pre-wrap;background-color:rgb(255,255,255)"> </span><span style="white-space:pre-wrap;background-color:rgb(255,255,255)">chimerax -m pip install <NameOfPyPiPackage></span></div><div><span style="white-space:pre-wrap;background-color:rgb(255,255,255)"><br></span></div><div>as discussed in this message</div><div><div><br></div><div><span style="white-space:pre-wrap"> </span><a href="https://www.rbvi.ucsf.edu/pipermail/chimerax-users/2021-March/002000.html" target="_blank">https://www.rbvi.ucsf.edu/pipermail/chimerax-users/2021-March/002000.html</a><br><div><br></div><div>If you don't have permission to modify ChimeraX where you might need to use the --user option to pip install. On windows you probably need to use the chimerax-console.exe executable.</div><div><br></div><div><span style="white-space:pre-wrap"> </span>Tom</div><div><br><blockquote type="cite"><div>On Jul 6, 2021, at 11:29 AM, James Loy via ChimeraX-users <<a href="mailto:chimerax-users@cgl.ucsf.edu" target="_blank">chimerax-users@cgl.ucsf.edu</a>> wrote:</div><br><div><div dir="ltr">Tom, Eric--<div><br></div><div>Thanks for the responses!</div><div><br></div><div>We'd certainly like to read the cif files, but in addition, we'd like to add hydrogens to the protein as well. For an MVP, I was just going to have some script that calls the chimerax CLI. Something like this (in python):</div><div><br></div><div><font face="monospace">for code in pdb_codes:</font></div><div><font face="monospace"> subprocess.run(f"chimerax --nogui --cmd 'load {code}.cif; addh; save {code}.addh.cif; exit'"</font></div><div><br></div><div>This will likely be okay. But, if I am able to call a python script using chimera basically as the interpreter then that might work better. My only question would be how could I utilize other third party libraries? Say, if I were to use chimerax as the interpreter for the entire cif processing pipeline, then I would need to utilize a few outside modules.</div><div><br></div><div>Thanks again for your help-- I really appreciate it!</div><div>-James</div></div><br><div class="gmail_quote"><div dir="ltr" class="gmail_attr">On Tue, Jul 6, 2021 at 1:07 PM Eric Pettersen <<a href="mailto:pett@cgl.ucsf.edu" target="_blank">pett@cgl.ucsf.edu</a>> wrote:<br></div><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex"><div>If the <i>only</i><span style="font-style:normal"> thing you need ChimeraX for is to read/parse mmCIF </span>files, we do package that part as a separate library: <a href="https://github.com/RBVI/readcif" target="_blank">GitHub - RBVI/readcif: A fast C++ CIF and mmCIF parser</a><div><br></div><div><div>--Eric</div><div><br></div><div><span style="white-space:pre-wrap"> </span>Eric Pettersen</div><div><span style="white-space:pre-wrap"> </span>UCSF Computer Graphics Lab</div></div><div><br><div><br><blockquote type="cite"><div>On Jul 6, 2021, at 11:01 AM, Tom Goddard via ChimeraX-users <<a href="mailto:chimerax-users@cgl.ucsf.edu" target="_blank">chimerax-users@cgl.ucsf.edu</a>> wrote:</div><br><div><div>Hi James,<div><br></div><div> The ChimeraX Python modules have not been packaged to be used outside the ChimeraX application. I have tried making a chimerax module that can be installed in any Python (with the right version for binary compatibility) where all its Python capabilities can be used without needing the application user interface. But we have not distributed that, it has lots of problems. We have put it into two grant proposals to get funding for it but one proposal was not funded and the other we are still waiting to hear about.</div><div><br></div><div> In theory it shouldn't be hard to reuse specific parts of ChimeraX, for instance reading mmCIF files. That is in the mmcif ChimeraX Python module.</div><div><br></div><div><span style="white-space:pre-wrap"> </span><a href="https://github.com/RBVI/ChimeraX/tree/develop/src/bundles/mmcif" target="_blank">https://github.com/RBVI/ChimeraX/tree/develop/src/bundles/mmcif</a><br><div><br></div><div>But that needs various other ChimeraX modules (atomstruct, element, pyinstance, pdbconnect, readcif, logger, arrays) listed in the mmcif bundle_info.xml file</div><div><br></div><div><span style="white-space:pre-wrap"> </span><a href="https://github.com/RBVI/ChimeraX/blob/develop/src/bundles/mmcif/bundle_info.xml" target="_blank">https://github.com/RBVI/ChimeraX/blob/develop/src/bundles/mmcif/bundle_info.xml</a></div><div><br></div><div>and those in turn require some other ChimeraX Python modules. ChimeraX contains hundreds of Python modules, so how will you figure out which ones you need? The easy solution is to take them all. But there are more problems, because the ChimeraX application initializes many of the modules, for instance, letting the atomic data structures module know where the residue template files are located. So you also need to figure that out. These many obstacles are why we proposed funding to make the code more usable without running the ChimeraX application -- it will be a good bit of work.</div><div><br></div><div> So the standard solution is instead to just run your processing scripts with the ChimeraX application from the command-line</div><div><br></div><div><span style="white-space:pre-wrap"> </span>chimerax --nogui myscript.py</div><div><br></div><div> For compiling ChimeraX you must be using old ChimeraX source code (your example is fetching Python 3.7 but ChimeraX has used Python 3.8 for the last 9 months). The current ChimeraX build does not fetch third party libraries with rsync, it uses https and curl and does not need a password. So use the current ChimeraX source from github and you should not have that problem.</div><div><br></div><div><span style="white-space:pre-wrap"> </span><a href="https://github.com/RBVI/ChimeraX" target="_blank">https://github.com/RBVI/ChimeraX</a></div><div><br></div><div> Tom</div><div><br></div><div><br></div><div><br><blockquote type="cite"><div>On Jul 3, 2021, at 5:51 AM, James Loy via ChimeraX-users <<a href="mailto:chimerax-users@cgl.ucsf.edu" target="_blank">chimerax-users@cgl.ucsf.edu</a>> wrote:</div><br><div><div dir="ltr">Hello!<div><br></div><div>Thank you for creating such an amazing piece of software!</div><div><br></div><div>I'm trying to use portions of ChimeraX for part of a CIF file processing pipeline. In order to automate the process, I'm building a docker image that has ChimeraX installed. Ideally, we would like to use the pieces of ChimeraX we need by importing the relevant python modules. Is this possible? If so, must I build ChimeraX from source?</div><div><br></div><div>Additionally, I have tried several times to build v1.1.1 from source and I have not been able to. I am always prompted for a password when trying to rsync the dependencies:</div><div><div style="margin:0px;font-variant-numeric:normal;font-variant-east-asian:normal;font-stretch:normal;font-size:12px;line-height:normal;font-family:JuliaMono;background-color:rgba(242,242,206,0.94)"><span style="font-variant-ligatures:no-common-ligatures">/bin/sh -c 'rsync -a $1 .' -- <a href="http://plato.cgl.ucsf.edu/" target="_blank">plato.cgl.ucsf.edu</a>:/usr/local/projects/chimerax/www/data/prereqs/python/Python-3.7.8.tar.xz</span></div><div style="margin:0px;font-variant-numeric:normal;font-variant-east-asian:normal;font-stretch:normal;font-size:12px;line-height:normal;font-family:JuliaMono;background-color:rgba(242,242,206,0.94)"><span style="font-variant-ligatures:no-common-ligatures"><a href="mailto:user@plato.cgl.ucsf.edu" target="_blank">user@plato.cgl.ucsf.edu</a>'s password:</span></div></div><div>In order to build from source, do I need to register somewhere to get credentials?</div><div><br></div><div>Just to be clear, this CIF file processing pipeline is for academic (UT Austin) use, not commercial.</div><div><br></div><div>Thanks in advance!</div><div>James<br>-- <br><div dir="ltr"><div dir="ltr"><div><div dir="ltr"><div>James Loy, Ph. D.</div><div>614.915.9792<br></div><div><a href="https://www.linkedin.com/in/james-m-loy-ph-d-ba2256a/" target="_blank">LinkedIn</a><br></div></div></div></div></div></div></div>
_______________________________________________<br>ChimeraX-users mailing list<br><a href="mailto:ChimeraX-users@cgl.ucsf.edu" target="_blank">ChimeraX-users@cgl.ucsf.edu</a><br>Manage subscription:<br><a href="https://www.rbvi.ucsf.edu/mailman/listinfo/chimerax-users" target="_blank">https://www.rbvi.ucsf.edu/mailman/listinfo/chimerax-users</a><br></div></blockquote></div><br></div></div>_______________________________________________<br>ChimeraX-users mailing list<br><a href="mailto:ChimeraX-users@cgl.ucsf.edu" target="_blank">ChimeraX-users@cgl.ucsf.edu</a><br>Manage subscription:<br><a href="https://www.rbvi.ucsf.edu/mailman/listinfo/chimerax-users" target="_blank">https://www.rbvi.ucsf.edu/mailman/listinfo/chimerax-users</a><br></div></blockquote></div><br></div></div></blockquote></div><br clear="all"><div><br></div>-- <br><div dir="ltr"><div dir="ltr"><div><div dir="ltr"><div>James Loy, Ph. D.</div><div>614.915.9792<br></div><div><a href="https://www.linkedin.com/in/james-m-loy-ph-d-ba2256a/" target="_blank">LinkedIn</a><br></div></div></div></div></div>
_______________________________________________<br>ChimeraX-users mailing list<br><a href="mailto:ChimeraX-users@cgl.ucsf.edu" target="_blank">ChimeraX-users@cgl.ucsf.edu</a><br>Manage subscription:<br><a href="https://www.rbvi.ucsf.edu/mailman/listinfo/chimerax-users" target="_blank">https://www.rbvi.ucsf.edu/mailman/listinfo/chimerax-users</a><br></div></blockquote></div><br></div></div></div></div></blockquote></div><br></div></div></blockquote></div><br clear="all"><div><br></div>-- <br><div dir="ltr" class="gmail_signature"><div dir="ltr"><div><div dir="ltr"><div>James Loy, Ph. D.</div><div>614.915.9792<br></div><div><a href="https://www.linkedin.com/in/james-m-loy-ph-d-ba2256a/" target="_blank">LinkedIn</a><br></div></div></div></div></div>