You can run this notebook online in a Binder session or view it on Github.
QCPortal¶
Full QCPortal documentation is available.
QCPortal is a data viewer for a QCFractal server. QCPortal can be used with any QCFractal server including one that you build on your own, but for these examples we will use the MolSSI QCArchive server. To begin we first construct a client that points to a QCFractal server instance, here we explicitly add the molssi.org
server.
[1]:
import qcportal as ptl
client = ptl.FractalClient("api.qcarchive.molssi.org")
client
[1]:
FractalClient
- Server: The MolSSI QCArchive Server
- Address: https://api.qcarchive.molssi.org/
- Username: None
Finding Collections¶
One of the main ways to explore the QCArchive is to examine Collection
s which are structures that allow easy manipulation of data in preset ways. Several example of Collection
s contained within the QCArchive are as follows:
Dataset
- A dataset where each record is a single molecule and many methods can be applied to each record.ReactionDataset
- A dataset where each record is a combinations of molecule (e.g. interaction and reaction energies) and many methods can be applied to each record.OpenFFWorkflow
- A workflow collection for torsiondrives and contstrained optimization developed with the Open Force Field Iniative.TorsionDriveDataset
- A datas set which organizes many molecular torsion scans together for data exploration, analysis, and methodology comparison (see the TorsionDrive Dataset example for more details).
[2]:
client.list_collections().head()
[2]:
tagline | ||
---|---|---|
collection | name | |
Dataset | OpenFF Discrepancy Benchmark 1 | None |
OpenFF NCI250K Boron 1 | None | |
OpenFF Optimization Set 1 | None | |
OpenFF VEHICLe Set 1 | None | |
SMIRNOFF Coverage Set 1 | None |
Specific Collection
types can be queried to limit the amount of collections to browse through:
[4]:
client.list_collections("ReactionDataset").head()
[4]:
tagline | ||
---|---|---|
collection | name | |
ReactionDataset | A21 | Equilibrium complexes from A24 database of sma... |
A24 | Interaction energies for small bimolecular com... | |
ACONF | Conformation energies for alkanes | |
AlkBind12 | Binding energies of saturated and unsaturated ... | |
AlkIsod14 | Isodesmic reaction energies for alkanes N=3--8 |
Exploring Collections¶
Collections can be obtained by pulling their data from the centeral server. A collection is primarily metadata and extremely large collections can be pulled in a few seconds. For this example we will explore S22 dataset which is a small interaction energy dataset of 22 common dimers such as the water dimer, methane dimer, and more. To obtain this collection:
[5]:
ds = client.get_collection("ReactionDataset", "S22")
print(ds)
ReactionDataset(name=`S22`, id='1', client='https://api.qcarchive.molssi.org/')
Stastistics and Visualization¶
Visual statics and plotting can be generated by the visualize
command:
[6]:
ds.visualize(method="B2PLYP", basis=["def2-svp", "def2-tzvp"], bench="S220", kind="violin")
Conclusion¶
These are just some of the capabilities QCPortal offers; check out more examples and the QCPortal documentation. If you like the project, consider starring us on GitHub or if you have any questions, join our Slack channel.