Python wrapper to interface with LocalDB and Production DB for common tasks for pixel modules.
Project description
Module QC Database Tools v2.0.2rc1
The package to regisiter ITkPixV1.1 modules, and generate YARR configs from ITk
production database using itkdb
API.
Set-Up and First-time Installation
A minimum of python version 3.7+ is required.
Virtual Python Environment
Creating the python virtual environment the standard way used the python version available on the operating system. For CentOS 7 this is version 3.6. If using CentOS 7, you can install python 3.8 following these instructions.
After installing python 3.8, create the virtual environment:
$ python3 -m venv venv
$ source venv/bin/activate
For future use:
$ source venv/bin/activate
Alternatively, anaconda or miniconda can also be installed.
For future use:
$ conda activate
Install
$ python -m pip install module-qc-database-tools
Environment Variables
If not already set elsewhere (e.g. ~/.bashrc
), copy .env.template
to .env
and update the values of the shell variables. Essentially, the following
variables regarding the production database should be available, shown below as
an example of environmental variables in ~/.bashrc
:
export INSTITUTION="LBNL_PIXEL_MODULES"
export ITKDB_ACCESS_CODE1="accesscode1"
export ITKDB_ACCESS_CODE2="accesscode2"
Module registration
Under construction...
Generate YARR configuration
This script has been tested on python 3.7+.
To generate YARR configuration for a given module, run generateYARRConfig
or
mqdbt generate-yarr-config
:
$ generateYARRConfig -sn [ATLAS SN] -o [outdir]
$ mqdbt generate-yarr-config -sn [ATLAS SN] -o [outdir]
Parameters:
-sn, --sn, required=True: ATLAS serial number of the module
-ch, --chipTemplate, default="configs/YARR/chip_template.json": provide the path of a chip config template to generate the new chip configs from
-o, --outdir, path to output directory config folder will be placed in. If not supplied, the config files will be pushed into mongoDB if connection is set up.
For example, to generate the YARR configs for the module 20UPGR91301046
with
all power configs:
$ generateYARRConfig -sn 20UPGR91301046 -o ~/module_data/.
$ mqdbt generate-yarr-config -sn 20UPGR91301046 -o ~/module_data/.
The time needed to generate warm and cold L2 configs for a quad module is about 4 seconds.
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
Built Distribution
File details
Details for the file module_qc_database_tools-2.0.2rc1.tar.gz
.
File metadata
- Download URL: module_qc_database_tools-2.0.2rc1.tar.gz
- Upload date:
- Size: 17.1 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/4.0.2 CPython/3.7.16
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 616851211e9dc94f8aeead4c1a7b09a72d87ddbef956155ce7cecee4af89b7bf |
|
MD5 | 51b7a4ef3d6752ffd4efee0a29746df8 |
|
BLAKE2b-256 | 250dad5b2c3914aab95607b88d51cc190c8303b780e227978f80d6d8f698824b |
File details
Details for the file module_qc_database_tools-2.0.2rc1-py3-none-any.whl
.
File metadata
- Download URL: module_qc_database_tools-2.0.2rc1-py3-none-any.whl
- Upload date:
- Size: 15.5 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/4.0.2 CPython/3.7.16
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | fbed4b2a085aa2e27b37e1e2902e94eea8db39784abb84e911274aa3683edbb1 |
|
MD5 | 4ba7d3002130ecc07253e3d1585780f6 |
|
BLAKE2b-256 | 206f16084747c6a6084ca0c7d7dac0e51d408ded6c4cf7cd3e7d66f06bbffe03 |