callat-qcd / lattedb

Lattice QCD database interface using EspressoDB as the content manager.
https://ithems.lbl.gov/lattedb
BSD 3-Clause "New" or "Revised" License
1 stars 0 forks source link

External API #7

Closed ckoerber closed 5 years ago

ckoerber commented 5 years ago

In order to be useful beyond bookkeeping, we should implement an API such that other python programs can use this module.

E.g., assume this module is configured and we have an external script like this

import lattedb

lattedb.init()

prop = lattedb.HisqPropagator.get(...) # query the db

prop.mpi = 135.0 # change in external script

prop.save() # update the db
ckoerber commented 5 years ago

Also it would be nice to have a remote web view / table where you can choose what you would like to import into, e.g., a local pandas DataFrame.

ckoerber commented 5 years ago

PR #8 now allows to pip install lattedb and thus make it accessible for external scripts.