Skip to main content

Parser for the DCM (Data Conservation format) format used by e.g. Vector, ETAS,...

Project description

dcmReader

Parser for the DCM (Data Conservation format) format used by e.g. Vector, ETAS,...

Basic usage

The read function of DcmParser parses the given DCM-file and stores internally the parsed values.

Sample program: from dcmReader.dcm_reader import DcmReader

dcm = DcmReader()
dcm.read("tests/Sample.dcm")

readFunctions = dcm.get_functions()
for fnc in readFunctions:
    print(fnc)

Will return:

ParameterFunction
  Version: 1.0
  Description: Function for parameters
BlockParameterFunction
  Version: 2.0
  Description: Function for block parameters
CharacteristicLineFunction
  Version: 3.0
  Description: Function for characteristic line functions
FixedCharacteristicLineFunction
  Version: 3.1
  Description: Function for fixed characteristic line functions
GroupCharacteristicLineFunction
  Version: 3.2
  Description: Function for group characteristic line functions
CharacteristicMapFunction
  Version: 4.0
  Description: Function for characteristic map functions
FixedCharacteristicMapFunction
  Version: 4.1
  Description: Function for fixed characteristic map functions
GroupCharacteristicMapFunction
  Version: 4.2
  Description: Function for group characteristic map functions
DistributionFunction
  Version: 5.0
  Description: Function for distribution functions

You can also save a DCM object to a file with the write function. The output is sorted first by FUNKTION then by LANGNAME. This can also be used to sort a DCM file:

from dcmReader.dcm_reader import DcmReader

dcm = DcmReader()
dcm.read("tests/Sample.dcm")
dcm.write("tests/Sample_sorted.dcm")

UnitTests

The UnitTests can be run in the tests directory by running python Tests.py

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

dcmreader-0.5.1.tar.gz (10.8 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

dcmreader-0.5.1-py3-none-any.whl (15.3 kB view details)

Uploaded Python 3

File details

Details for the file dcmreader-0.5.1.tar.gz.

File metadata

  • Download URL: dcmreader-0.5.1.tar.gz
  • Upload date:
  • Size: 10.8 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.9.25

File hashes

Hashes for dcmreader-0.5.1.tar.gz
Algorithm Hash digest
SHA256 22c82255772ebe55820bb507fe8ae11b07e62dd81b7e1094030f4c043131b6fd
MD5 586f97afd76ced2bc582ab404caae392
BLAKE2b-256 03a628b7c7fa6958ff076c18c401a2929bf2277f63cd8b3b17ef862ea521150d

See more details on using hashes here.

File details

Details for the file dcmreader-0.5.1-py3-none-any.whl.

File metadata

  • Download URL: dcmreader-0.5.1-py3-none-any.whl
  • Upload date:
  • Size: 15.3 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.9.25

File hashes

Hashes for dcmreader-0.5.1-py3-none-any.whl
Algorithm Hash digest
SHA256 d623f8debd65e5dcc34cb4bd583ec00198957f90039ac512442ae01092250cd3
MD5 01a6ba3c16b96f2c7a798b87b60e4164
BLAKE2b-256 91b943188ef528f82328ccf2374d94758bfb4d4e0c35378b2560ba3e99ba36a0

See more details on using hashes here.

Supported by

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