Python package for reading Bruker OPUS files.
Go to file
tomkee 999779cb9c
Merge pull request #1 from tommyhlw/patch-1
Update opus_reader.py
2018-11-07 17:04:27 +01:00
brukeropusreader Linting, meta_data initialization, adding TIM and SFM 2018-11-07 16:51:21 +01:00
conf Extracting spectras with highest average 2017-08-01 11:27:19 +02:00
tests Extracting spectras with highest average 2017-08-01 11:27:19 +02:00
.gitignore Moving bruker opus reader to python 3 2017-10-10 16:52:26 +02:00
LICENSE.txt Preparing package 2018-07-11 00:20:47 +02:00
README.md Removing hyphens 2018-07-12 11:37:51 +02:00
example.py Removing hyphens 2018-07-12 11:37:51 +02:00
requirements.in Removing matplotlib dependency 2017-11-09 09:43:47 +01:00
requirements.txt Removing matplotlib dependency 2017-11-09 09:43:47 +01:00
setup.py Removing hyphens 2018-07-12 11:37:51 +02:00

README.md

Bruker OPUS Reader

Introduction

The brukeropusreader Python package enables reading the binary OPUS files generated by Bruker spectrometers.

Usage

Run the function brukeropusreader.opus_reader to read OPUS files.

Structure of OPUS files

OPUS files consist of several series of spectra. Each series is described by a few parameters:

  • NPT (number of points)
  • FXV (value of first wavelength)
  • LXV (value of last wavelength)
  • END (address of spectra series)

These parameters are found by searching for ASCII strings in the binary files. After finding a match with one of these parameters, we move the pointer a few bytes further to read the values. Unfortunately, there is no published open standard describing how much further the pointer should be moved. We empirically checked that this shift factor is 8 bytes for NPT, FXV, and LXV, and 12 bytes for END. In addition, each file contains some metadata about the hardware used for measurement.

Known issues

As Bruker's OPUS file format is not described openly, we do not know its exact structure. One problem is, given only a few series, how to decide which are absorption spectra? Our solution, empirically developed, is as follows:

  1. Remove broken series (such as ones where FXV > LXV, missing NPT information, etc.)
  2. Remove interferograms. (See simplerspec.) Interferograms have a starting value of 0.
  3. If after these two steps we still have more than one series left, choose the one with highest average value. We empirically verified that other series are usually random noise with values near 0.

Contact

For developer issues, please start a ticket in Github. You can also write to the dev team directly at brukeropusreader-dev@qed.ai. For other issues, please write to: brukeropusreader@qed.ai

License

Copyright (c) 2018 Quantitative Engineering Design. All rights reserved. This project is released under the terms of the AGPL license, which is included in LICENSE.txt.

-- QED | https://qed.ai