Skip to main content

Retrieve g4edge test data from Python

Project description

g4edge test data

GitHub tag (latest by date) GitHub Workflow Status pre-commit Code style: black GitHub issues GitHub pull requests License

Install (with pip):

$ python -m pip install g4edge-testdata

Usage

Instantiating a G4EdgeTestData object:

from g4edgetestdata import G4EdgeTestData

g4data = G4EdgeTestData()

Clones g4edge/testdata in a temporary location (not preserved across system reboots), unless the environment variable G4EDGE_TESTDATA is set and points to the location of an existing g4edge/testdata clone.

Alternatively, the path to an existing g4edge/testdata clone can be provided to the class constructor:

from g4edgetestdata import G4EdgeTestData

g4data = G4EdgeTestData("path/to/g4edge/testdata")

Access to data files is provided through the square brackets operator:

>>> g4data["gdml/001_box.gdml"]
PosixPath('/tmp/g4edge-testdata-gipert/data/gdml/001_box.gdml')

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

g4edge_testdata-0.1.0.tar.gz (16.6 kB view hashes)

Uploaded Source

Built Distribution

g4edge_testdata-0.1.0-py3-none-any.whl (16.0 kB view hashes)

Uploaded Python 3

Supported by

AWS AWS Cloud computing and Security Sponsor Datadog Datadog Monitoring Fastly Fastly CDN Google Google Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page