Skip to main content

FlashCam File Format (FCIO) reader for python.

Project description

Installation

Run python3 -m pip install fcio to install from the pypi repository.

Description

fcio-py provides a read-only wrapper around the fcio.c io library used in fc250b based digitizer systems.

The wrapper exposes the fcio.c memory fields as closely as possible to standard c-structs using numpy ndarrays or scalars where applicable. For convenience all supported fcio records are exposed as iterable properties of the base FCIO class to preselect records of interest.

Usage

Simple code example

The following example opens an fcio file and prints some basic event content to stdout:

from fcio import fcio_open

filename = 'path/to/an/fcio/file'

with fcio_open(filename, extended=True) as io:
  print("#evtno run_time utc_unix_sec utc_unix_nsec ntraces bl_mean bl_std")
  for event in io.events:
    print(f"{event.eventnumber} {event.run_time:.09f} {event.utc_unix_sec} {event.utc_unix_nsec} {event.trace_list.size} {event.fpga_baseline.mean():.1f} {event.fpga_baseline.std():.2f}")

Differences to C usage

  • fcio-py codifies the assumption that a FCIOConfig record must be available and skips all previous records on opening
  • reading of zstd or gzip compressed files is possible using suprocesses. This requires zstd or gzip to be available. If a file ends in .zst or .gz respectively and the compression parameter is default, this will happen automatically.

Development

Development is best done in a local environment, e.g. using venv:

# create local environment:
export MY_ENV=fcio_dev
python3 -m venv $MY_ENV

# activate the environment
source $MY_ENV/bin/activate

This library depends on meson-python/meson as build tool and Cython/numpy to wrap the c-sources. These should be installed automatically wenn running python3 -m build. To allow a more traditional workflow a thin Makefile is available which wraps the python3 and meson specific commands.

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

fcio-0.7.9.tar.gz (159.6 kB view details)

Uploaded Source

Built Distributions

fcio-0.7.9-cp313-cp313-manylinux_2_17_x86_64.manylinux2014_x86_64.whl (286.6 kB view details)

Uploaded CPython 3.13manylinux: glibc 2.17+ x86-64

fcio-0.7.9-cp313-cp313-macosx_11_0_arm64.whl (231.0 kB view details)

Uploaded CPython 3.13macOS 11.0+ ARM64

fcio-0.7.9-cp312-cp312-manylinux_2_17_x86_64.manylinux2014_x86_64.whl (290.1 kB view details)

Uploaded CPython 3.12manylinux: glibc 2.17+ x86-64

fcio-0.7.9-cp312-cp312-macosx_11_0_arm64.whl (223.2 kB view details)

Uploaded CPython 3.12macOS 11.0+ ARM64

fcio-0.7.9-cp311-cp311-manylinux_2_17_x86_64.manylinux2014_x86_64.whl (298.8 kB view details)

Uploaded CPython 3.11manylinux: glibc 2.17+ x86-64

fcio-0.7.9-cp311-cp311-macosx_11_0_arm64.whl (222.5 kB view details)

Uploaded CPython 3.11macOS 11.0+ ARM64

fcio-0.7.9-cp310-cp310-manylinux_2_17_x86_64.manylinux2014_x86_64.whl (307.6 kB view details)

Uploaded CPython 3.10manylinux: glibc 2.17+ x86-64

fcio-0.7.9-cp310-cp310-macosx_11_0_arm64.whl (224.1 kB view details)

Uploaded CPython 3.10macOS 11.0+ ARM64

fcio-0.7.9-cp39-cp39-manylinux_2_17_x86_64.manylinux2014_x86_64.whl (307.5 kB view details)

Uploaded CPython 3.9manylinux: glibc 2.17+ x86-64

fcio-0.7.9-cp39-cp39-macosx_11_0_arm64.whl (224.9 kB view details)

Uploaded CPython 3.9macOS 11.0+ ARM64

File details

Details for the file fcio-0.7.9.tar.gz.

File metadata

  • Download URL: fcio-0.7.9.tar.gz
  • Upload date:
  • Size: 159.6 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/6.1.0 CPython/3.12.9

File hashes

Hashes for fcio-0.7.9.tar.gz
Algorithm Hash digest
SHA256 788c8d4ee8d5fa2d6dddb1f6294fbbfdc7fe87741aaa674597c3c24fcd6e63a4
MD5 49a45591a279d6f07ceb35068ae4709f
BLAKE2b-256 0f3076689f2e6b9a4a8c7c35d618ae521f1907f275af9c9b94ad0aca0967e0f3

See more details on using hashes here.

Provenance

The following attestation bundles were made for fcio-0.7.9.tar.gz:

Publisher: publish.yml on FlashCam/fcio-py

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

File details

Details for the file fcio-0.7.9-cp313-cp313-manylinux_2_17_x86_64.manylinux2014_x86_64.whl.

File metadata

File hashes

Hashes for fcio-0.7.9-cp313-cp313-manylinux_2_17_x86_64.manylinux2014_x86_64.whl
Algorithm Hash digest
SHA256 3d4cf1929823ecfb680f1afc6a8fdd2a2479ceed9df9868d6c43fbe06deeb423
MD5 208142806b49aabf00c862862504ee49
BLAKE2b-256 f44138ff20e6ff619615608436d934e4337c1b75efe0b00c389f80b692cdecc5

See more details on using hashes here.

Provenance

The following attestation bundles were made for fcio-0.7.9-cp313-cp313-manylinux_2_17_x86_64.manylinux2014_x86_64.whl:

Publisher: publish.yml on FlashCam/fcio-py

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

File details

Details for the file fcio-0.7.9-cp313-cp313-macosx_11_0_arm64.whl.

File metadata

File hashes

Hashes for fcio-0.7.9-cp313-cp313-macosx_11_0_arm64.whl
Algorithm Hash digest
SHA256 c047227d101072e31165b32803026f324cf2e4a9750c4829a37f9918d42604b1
MD5 23c063830e28148e0a4fb797611983be
BLAKE2b-256 a2451c6eb1e3d67e41d1e8f1ff156b5507f88fc214dc4211cee55c4c81f7a100

See more details on using hashes here.

Provenance

The following attestation bundles were made for fcio-0.7.9-cp313-cp313-macosx_11_0_arm64.whl:

Publisher: publish.yml on FlashCam/fcio-py

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

File details

Details for the file fcio-0.7.9-cp312-cp312-manylinux_2_17_x86_64.manylinux2014_x86_64.whl.

File metadata

File hashes

Hashes for fcio-0.7.9-cp312-cp312-manylinux_2_17_x86_64.manylinux2014_x86_64.whl
Algorithm Hash digest
SHA256 1c0b0da8bdb3b1987488e88b17e0b0fb1d5b2127969f1d8bc5aecdad83a78b99
MD5 dd07825c82c0b61f7b5de52e5586758d
BLAKE2b-256 8b43ca54ca6ae68f948ab533bb7b7dc3b705abd275a610e2d6df3fb2f49d6e29

See more details on using hashes here.

Provenance

The following attestation bundles were made for fcio-0.7.9-cp312-cp312-manylinux_2_17_x86_64.manylinux2014_x86_64.whl:

Publisher: publish.yml on FlashCam/fcio-py

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

File details

Details for the file fcio-0.7.9-cp312-cp312-macosx_11_0_arm64.whl.

File metadata

File hashes

Hashes for fcio-0.7.9-cp312-cp312-macosx_11_0_arm64.whl
Algorithm Hash digest
SHA256 3401437689f4c25243ea57f45e93ab2c26772ce9c157bad748a00758c679df75
MD5 18245e9f2926954164e224906414d6e9
BLAKE2b-256 e2123d16864e7b93355ef748e7973df102214bcc0e7a8da41929da00bb464501

See more details on using hashes here.

Provenance

The following attestation bundles were made for fcio-0.7.9-cp312-cp312-macosx_11_0_arm64.whl:

Publisher: publish.yml on FlashCam/fcio-py

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

File details

Details for the file fcio-0.7.9-cp311-cp311-manylinux_2_17_x86_64.manylinux2014_x86_64.whl.

File metadata

File hashes

Hashes for fcio-0.7.9-cp311-cp311-manylinux_2_17_x86_64.manylinux2014_x86_64.whl
Algorithm Hash digest
SHA256 4490323e723c25f9a0a367862328afae486b6ae50d2bf91c33acd0fe08cba721
MD5 9ddff9f60622134baa289b02af080a60
BLAKE2b-256 a08effc9ea7f944d87cbad46b5b54f16b8f5e091e7b846079baf2b901463967c

See more details on using hashes here.

Provenance

The following attestation bundles were made for fcio-0.7.9-cp311-cp311-manylinux_2_17_x86_64.manylinux2014_x86_64.whl:

Publisher: publish.yml on FlashCam/fcio-py

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

File details

Details for the file fcio-0.7.9-cp311-cp311-macosx_11_0_arm64.whl.

File metadata

File hashes

Hashes for fcio-0.7.9-cp311-cp311-macosx_11_0_arm64.whl
Algorithm Hash digest
SHA256 e2a380a809dd35eccfacdc9a4dab04a04a11c777a7bc98cb203dc3719b9661d6
MD5 b877dfc5c3a75b35f35b33bfda2830c4
BLAKE2b-256 22ae32940ffa6d47885fa9658e296c1ecc0b7a85578a94d169b926091fd35994

See more details on using hashes here.

Provenance

The following attestation bundles were made for fcio-0.7.9-cp311-cp311-macosx_11_0_arm64.whl:

Publisher: publish.yml on FlashCam/fcio-py

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

File details

Details for the file fcio-0.7.9-cp310-cp310-manylinux_2_17_x86_64.manylinux2014_x86_64.whl.

File metadata

File hashes

Hashes for fcio-0.7.9-cp310-cp310-manylinux_2_17_x86_64.manylinux2014_x86_64.whl
Algorithm Hash digest
SHA256 d4cfaaa416ef32f42970ad4510b35048701f3adf21e45de9a3e7be32aa818868
MD5 100320da6f14ade0a302ec24eef262f4
BLAKE2b-256 290869bf4579015f17a56b705c223e8cec947fd40c6a37e2ca02533d2df104c7

See more details on using hashes here.

Provenance

The following attestation bundles were made for fcio-0.7.9-cp310-cp310-manylinux_2_17_x86_64.manylinux2014_x86_64.whl:

Publisher: publish.yml on FlashCam/fcio-py

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

File details

Details for the file fcio-0.7.9-cp310-cp310-macosx_11_0_arm64.whl.

File metadata

File hashes

Hashes for fcio-0.7.9-cp310-cp310-macosx_11_0_arm64.whl
Algorithm Hash digest
SHA256 f67465cd220f734f3fd02b663a9238d613acf54e8344c84de47f85c956a0bc83
MD5 5dfa6b1cc0a83a3b85ba9e8bc2836759
BLAKE2b-256 abc05acd43548efe37c8536ec767e4d33c8541e86f7719f7f0f4d5198102b70f

See more details on using hashes here.

Provenance

The following attestation bundles were made for fcio-0.7.9-cp310-cp310-macosx_11_0_arm64.whl:

Publisher: publish.yml on FlashCam/fcio-py

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

File details

Details for the file fcio-0.7.9-cp39-cp39-manylinux_2_17_x86_64.manylinux2014_x86_64.whl.

File metadata

File hashes

Hashes for fcio-0.7.9-cp39-cp39-manylinux_2_17_x86_64.manylinux2014_x86_64.whl
Algorithm Hash digest
SHA256 0bd95ecff5580dd48281fa4a625982abeea43e9e494f63ee25a59cbf6f8f93dc
MD5 fe44687ab2bd99aa07610c30b74d87cd
BLAKE2b-256 da43be65ddb534716e189edcf27e98825abfd969c9ac47182f65f468dbcf362f

See more details on using hashes here.

Provenance

The following attestation bundles were made for fcio-0.7.9-cp39-cp39-manylinux_2_17_x86_64.manylinux2014_x86_64.whl:

Publisher: publish.yml on FlashCam/fcio-py

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

File details

Details for the file fcio-0.7.9-cp39-cp39-macosx_11_0_arm64.whl.

File metadata

  • Download URL: fcio-0.7.9-cp39-cp39-macosx_11_0_arm64.whl
  • Upload date:
  • Size: 224.9 kB
  • Tags: CPython 3.9, macOS 11.0+ ARM64
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/6.1.0 CPython/3.12.9

File hashes

Hashes for fcio-0.7.9-cp39-cp39-macosx_11_0_arm64.whl
Algorithm Hash digest
SHA256 e34cbc725c932fc8b06afa949d12b418c43a90609688f479cc579d3267778025
MD5 681a7a00ee194d36b7eec80d1b291b84
BLAKE2b-256 c9c9a3a3e5ad9f77cc93e3edf63fb153754f2f32eb2c490de96b78ebbb4fb957

See more details on using hashes here.

Provenance

The following attestation bundles were made for fcio-0.7.9-cp39-cp39-macosx_11_0_arm64.whl:

Publisher: publish.yml on FlashCam/fcio-py

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

Supported by

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