-
Notifications
You must be signed in to change notification settings - Fork 9
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Setting up an environment for quantum computing #107
base: master
Are you sure you want to change the base?
Conversation
This is a baseline set of Python modules and a QM code (Psi4) to do some basic quantum computing simulation. Signed-off-by: Marcus D. Hanwell <[email protected]>
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The projectq
module is failing to build with the error below:
pp_opts.append("-I%s" % dir)
File "/tmp/pip-install-x4_s57sy/projectq/setup.py", line 63, in __str__
import pybind11
ModuleNotFoundError: No module named 'pybind11'
----------------------------------------
ERROR: Failed building wheel for projectq
docker/quantum/Dockerfile
Outdated
RUN apt-get update && \ | ||
apt-get install -y libblas-dev liblapack-dev && \ | ||
cd /root && \ | ||
pip install -r requirements.txt && \ |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
mkdir build && \ | ||
cd build && \ | ||
cmake ../psi4-1.3.2 && make -j10 install && \ | ||
rm -rf /usr/local/psi4/share/psi4/samples && \ |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I tried the psi4 inside the image and it's failing with the following:
root@2fc7f25c76b0:/tmp# /usr/local/psi4/bin/psi4 input.dat
Traceback (most recent call last):
File "/usr/local/psi4/bin/psi4", line 287, in <module>
exec(content)
File "<string>", line 35, in <module>
File "/usr/local/psi4/lib/psi4/driver/driver.py", line 556, in energy
wfn = procedures['energy'][lowername](lowername, molecule=molecule, **kwargs)
File "/usr/local/psi4/lib/psi4/driver/procrouting/proc.py", line 2002, in run_scf
scf_wfn = scf_helper(name, post_scf=False, **kwargs)
File "/usr/local/psi4/lib/psi4/driver/procrouting/proc.py", line 1276, in scf_helper
base_wfn = core.Wavefunction.build(scf_molecule, core.get_global_option('BASIS'))
File "/usr/local/psi4/lib/psi4/driver/p4util/python_helpers.py", line 115, in _core_wavefunction_build
basis = core.BasisSet.build(mol, "ORBITAL", basis)
File "/usr/local/psi4/lib/psi4/driver/p4util/python_helpers.py", line 80, in _pybuild_basis
mol.to_dict(), key, resolved_target, fitrole, other, return_dict=True, return_atomlist=return_atomlist)
File "/usr/local/psi4/lib/psi4/driver/qcdb/molecule.py", line 1461, in to_dict
compare_molrecs(validated_molrec, molrec, 6, 'to_dict', forgive=forgive, verbose=0)
File "/usr/local/psi4/lib/psi4/driver/qcdb/psiutil.py", line 255, in compare_molrecs
compare_dicts(xptd, cptd, tol, label, forgive=forgive, verbose=verbose)
File "/usr/local/psi4/lib/psi4/driver/qcdb/psiutil.py", line 152, in compare_dicts
raise ImportError("""Python module deepdiff not found. Solve by installing it: `conda install deepdiff -c conda-forge` or `pip install deepdiff`""")
ImportError: Python module deepdiff not found. Solve by installing it: `conda install deepdiff -c conda-forge` or `pip install deepdiff`
Printing out the relevant lines from the Psithon --> Python processed input file:
""","cswater")
core.IO.set_default_namespace("cswater")
oswater = cswater.clone()
oswater.set_multiplicity(2)
oswater.set_molecular_charge(1)
--> e = energy('b3lyp', molecule=cswater)
core.set_global_option("REFERENCE", "uhf")
e = energy('b3lyp', molecule=oswater)
core.set_global_option("REFERENCE", "rks")
e = energy('b3lyp5', molecule=cswater)
core.set_global_option("REFERENCE", "uks")
The example I was trying to run is: https://github.com/psi4/psi4/blob/master/samples/dft-b3lyp/input.dat
jinja2 | ||
cmake | ||
pint | ||
pydantic |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Add deepdiff
to the list of requirements.
It needs to be written, I was going to base it on what Bert shared in quantum notebooks. |
@cryos It looks like there are a couple of notebooks/calculations which one where we planning on using? |
@cjh1 I hadn't decided, I was just going to pick one and get something working to ensure all the pieces were functional. If it runs I think that needs some input from Bert on the next step as they are just examples that may not form the best driver. It might be good to get together and refresh on what we want to get into the driver/container. |
Yeah, we probably should do some planning on a workflow.
…On Tue, Oct 20, 2020 at 11:39 AM Marcus D. Hanwell ***@***.***> wrote:
@cjh1 <https://github.com/cjh1> I hadn't decided, I was just going to
pick one and get something working to ensure all the pieces were
functional. If it runs I think that needs some input from Bert on the next
step as they are just examples that may not form the best driver. It might
be good to get together and refresh on what we want to get into the
driver/container.
—
You are receiving this because you were mentioned.
Reply to this email directly, view it on GitHub
<#107 (comment)>,
or unsubscribe
<https://github.com/notifications/unsubscribe-auth/ABTL24QBT2DMA2BL47WMPHDSLXKMJANCNFSM4NCT5GHA>
.
|
…mongochemdeploy into quantum-computing
Signed-off-by: Brianna Major <[email protected]>
Signed-off-by: Brianna Major <[email protected]>
This calculation code comes from the notebook provided here: https://github.com/OpenChemistry/quantumnotebooks/blob/master/OpenChemistry-Quantum.ipynb Signed-off-by: Brianna Major <[email protected]>
Signed-off-by: Brianna Major <[email protected]>
Signed-off-by: Brianna Major <[email protected]>
Signed-off-by: Brianna Major <[email protected]>
Include Psi4 energy and properly format coordinates Signed-off-by: Brianna Major <[email protected]>
An explanation of the changes made up until a5edc5f can be found in this comment |
@bnmajor Could you provide a notebook showing how this container can be invoked? |
@cjh1 Yes I'll work on one |
Signed-off-by: Brianna Major <[email protected]>
Signed-off-by: Brianna Major <[email protected]>
docker/quantum/README.md
Outdated
- `tag`: <strong>1.0</strong> | ||
- `digest`: <strong>123</strong> (can be any value) | ||
- `clusterId`: (from GET /clusters) | ||
- `size`: <strong>2</strong> (can be any value) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
We should be able to do this via the UI @psavery? Also how do we get it registered automatically in the dev environment?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looks like we needed to add it to this list.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@cjh1 Yeah, that's to register it automatically.
You can also manually register it via the girder endpoint at localhost:8080/api/v1
under "images". If you do this, you can put whatever you want for the digest and the size, the digest is only used to see if the image has already been registered. The size isn't used for anything but display.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@bnmajor Lets add openchemistry/qiskit
to the list to be added automatically, then I think we can remove this block.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@bnmajor This works for me with the sample notebook with the inchikey change. Looking good, couple of inline comments.
docker/quantum/README.md
Outdated
docker image: | ||
|
||
``` | ||
docker build -t quantum:1.0 . |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Lets tag the image openchemistry/qiskit
docker/quantum/README.md
Outdated
- `tag`: <strong>1.0</strong> | ||
- `digest`: <strong>123</strong> (can be any value) | ||
- `clusterId`: (from GET /clusters) | ||
- `size`: <strong>2</strong> (can be any value) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@bnmajor Lets add openchemistry/qiskit
to the list to be added automatically, then I think we can remove this block.
Here is the sample notebook. |
Signed-off-by: Brianna Major <[email protected]>
Signed-off-by: Brianna Major <[email protected]>
This is a baseline set of Python modules and a QM code (Psi4) to do some
basic quantum computing simulation.