Python client for accessing the XENON experiment PMT data.
Project description
A helper package for managing the PMT database used by the XENONnT Dark Matter Experiment.
Basic Usage
import xepmts
# If you are using a notebook:
xepmts.notebook()
# use v1 client
db = xepmts.login("v1", token='YOUR-API-TOKEN')
# or the v2 client
db = xepmts.login("v2")
# set the number of items to pull per page
db.tpc.installs.items_per_page = 25
# get the next page
page = db.tpc.installs.next_page()
# iterate over pages:
for page in db.tpc.installs.pages():
df = page.df
# do something with data
# select only top array
top_array = db.tpc.installs.filter(array="top")
# iterate over top array pages
for page in top_array.pages():
df = page.df
# do something with data
query = dict(pmt_index=4)
# get the first page of results for this query as a list of dictionaries
docs = db.tpc.installs.find(query, max_results=25, page_number=1)
# same as find, but returns a dataframe
df = db.tpc.installs.find_df(query)
# insert documents into the database
docs = [{"pmt_index": 1, "position_x": 0, "position_y": 0}]
db.tpc.installs.insert_documents(docs)
Free software: MIT
Documentation: https://xepmts.readthedocs.io/
Features
TODO
Credits
This package was created with Cookiecutter and the briggySmalls/cookiecutter-pypackage project template.
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
xepmts-0.5.9.tar.gz
(11.7 kB
view details)
Built Distribution
xepmts-0.5.9-py3-none-any.whl
(11.4 kB
view details)
File details
Details for the file xepmts-0.5.9.tar.gz
.
File metadata
- Download URL: xepmts-0.5.9.tar.gz
- Upload date:
- Size: 11.7 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: poetry/1.1.12 CPython/3.10.4 Linux/5.15.32-1-MANJARO
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 6d99a00e2be1ef9723f88467d8b9c99f82ca63ad4b1791f06c1891ec76e38330 |
|
MD5 | acccd1c69aa490e8584663b7144b84a0 |
|
BLAKE2b-256 | 7adf9b7ddf1006679f4b3fabd8ea918cb55f1d53fcec5af67ebf0a369a2fdf07 |
File details
Details for the file xepmts-0.5.9-py3-none-any.whl
.
File metadata
- Download URL: xepmts-0.5.9-py3-none-any.whl
- Upload date:
- Size: 11.4 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: poetry/1.1.12 CPython/3.10.4 Linux/5.15.32-1-MANJARO
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 2370d9b02d04c32d5a2ccef44345a0a616fe7649a2ca32cb4396ae904d56dd35 |
|
MD5 | e568e68e2b4fc1cdb38e4660909f8b70 |
|
BLAKE2b-256 | 711e192f43e30f88a4862924af77a4974c107df3ea44900972dd14fbb15a0ac9 |