xylib
xylib is a portable library for reading files that contain x-y data from
powder diffraction, spectroscopy or other experimental methods.
Supported formats:
- plain text (CSV or TSV or space-separated-values)
- Crystallographic Information File for Powder Diffraction (pdCIF)
- Siemens/Bruker UXD
- Siemens/Bruker RAW ver. 1/2/3/4
- Philips UDF
- Philips RD (raw scan) V3
- Rigaku DAT
- Sietronics Sieray CPI
- DBWS/DMPLOT data file
- Canberra MCA (only one of Canberra MCA formats?)
- XFIT/Koalariet XDD
- RIET7/LHPM/CSRIET/ILL_D1A5/PSI_DMC DAT
- Vamas ISO14976
(only experiment modes: SEM or MAPSV or MAPSVDP are supported;
only REGULAR scan_mode is supported)
- Princeton Instruments WinSpec SPE
(only 1-D data is supported)
The library is written in C++, but it comes with C and Python bindings.
It also comes with a tiny program xyconv, which converts
supported formats to TSV.
For API description, see xylib/xylib.h file.
Licence: LGPL
DOWNLOAD
Binary packages:
Source:
To build from source, you need:
- C++ compiler (we tested GCC, MinGW, Visual C++)
- Boost libraries (only headers).
On Unix, just type ./configure && make.
If you downloaded the source from svn, run autoreconf -i first.
MISC NOTES
The file sample-urls contains links to files in formats handled by xylib.
In addition to C++ API, we provide C API and very simple Python bindings.
So far we had no requests for binding to other languages.
Documentation for programmers who want to extend xylib is
in the file README.dev.
freshmeat provides new version notifications.
xylib is used by:
CREDITS
- Google - the library was started as Google Summer of Code 2007 project
by Peng ZHANG, mentored by Marcin Wojdyr from Fityk organization.
- Michael Richardson provided VAMAS specification and sample files.
- David Hovis provided a WinSpec file format specification and sample files.
- Pablo Bianucci provided his code for reading WinSpec format and sample files.
- Brian H. Toby suggested adding pdCIF format.
- Martijn Fransen provided very useful specifications of Philips formats.
- Vincent Favre-Nicolin provided PSI_DMC and ILL_D1A5 samples;
reading his ObjCryst library was also helpful.
- Janos Vegh sent us his VAMAS reading routines (long time ago, before this
project started).
- Andreas Breslau added Bruker V3 (RAW1.01) support.
- Bjørn Tore Lønstad provided Bruker RAW V3 format specification and samples.
HISTORY
- 0.6 (2010-04-29)
- fixed reading of Bruker v3 files
- changes in API, added C API
- 0.5 (2010-01-04)
- added support for compressed files *.gz (requires zlib) and *.bz2 (bzlib)
- 0.4 (2009-06-11)
- added file caching (for details see xylib/cache.h)
- changes to parsing text files in which numeric data is mixed with text
- 0.3 (2008-06-03)
- added Bruker binary RAW1.01 format
- fixed bug in reading one-column ascii files
- 0.2 (2008-03-09)