cloudlab-cmu / cloudcompchem

Cloud Comp Chem
4 stars 0 forks source link

Feature/dft calculator poc #8

Closed tommyh-ECL closed 6 months ago

tommyh-ECL commented 6 months ago

Added proof of concept code for single point energy calculations using pyscf! A single endpoint (at /energy) has been exposed which takes a payload with keys for functional, basis_set, charge, spin_multiplicity, and molecule. The molecule payload includes a nested structure with an atoms key that contains a list of Atom structures with keys for symbol and position. This provides the minimal set of information for which to perform single point energy calculations.

The docker image was built using a line from the build script:

docker build --pull -f deploy/Dockerfile -t "emeraldsci/cloudcompchem:test" .

And run from the command line using:

docker run -p 127.0.0.1:5000:5000 -it emeraldsci/cloudcompchem:test

The specific address my need to be tweaked to run on another machine. Once the server is running, then I used the requests package to call a simple post request to the endpoint and got a successful response! See below:

image

yiwenwang47 commented 6 months ago

works perfectly on my end