aboutsummaryrefslogtreecommitdiff
path: root/libcrystfel
AgeCommit message (Collapse)Author
2021-05-12FussinessThomas White
2021-05-12Fix build without MsgPack (again)Thomas White
2021-05-12Fix build without MsgPackThomas White
2021-05-12Rework header caching layerThomas White
This clears up multiple layering violations which were starting to get in the way. It enables "string" headers to be stored directly, and it will make it much simpler to add new header types in the future. Along the way, this changes all the floating point header stuff to use double precision. This is needed for EuXFEL event IDs. Closes: https://gitlab.desy.de/thomas.white/crystfel/-/issues/34
2021-05-12Fix convert_int and add convert_floatThomas White
convert_int was using strtod. Whoops!
2021-05-12MsgPack: Fix a silly copy/paste errorThomas White
2021-05-11Set panel for bad region when there is only one panelThomas White
When there is only one panel, we can safely assume that fs/ss bad regions refer to it without it being stated in the geometry file. This allows some older Pilatus geometry files to be used without complaints. A further improvement would be to determine the panel when all the data comes from one "slab" so the panel is still ambiguous. However, on further thought it seems like a lot of work to do this reliably in all cases. I'm not even sure that this case in particular is causing anyone problems. Closes: https://gitlab.desy.de/thomas.white/crystfel/-/issues/32
2021-05-07Add has_unique_axis()Thomas White
2021-05-07MsgPack: Warn if dtempl->peak_list is NULLThomas White
2021-05-07MsgPack: Use the right pointer for "bin" keysThomas White
2021-05-07MsgPack: Use top-level object directly if it is a mapThomas White
2021-04-30write_to_mtz: Fix column names and typesThomas White
2021-04-29MsgPack: Handle floating-point data, fix array readThomas White
2021-04-29MsgPack: Handle strings if they can be converted to integersThomas White
2021-04-28MsgPack: Remove warning about multiple objectsThomas White
If this happens once, it'll probably happen every frame. This makes things very noisy.
2021-04-27Complain if there are unused defaults in geometry fileThomas White
This will help to avoid mistakes when people put statements at the end of the geometry file, rather than the top. Closes https://gitlab.desy.de/thomas.white/crystfel/-/issues/20.
2021-04-27Fix #include in filters.cThomas White
2021-04-27Rename libcrystfel's config.h to libcrystfel-config.hThomas White
This removes the big potential for confusion, which has happened several times (see e.g. 095cbebaf6). It also fixes in-tree builds with CMake (but seriously, always use out-of-tree builds). Fixes #2.
2021-04-27Swap the order of iteration in filters.cThomas White
This code hasn't been looked at for a very long time, and can be made a bit faster by iterating in a more cache-friendly way.
2021-04-23Fix build without MsgPackThomas White
2021-04-23indexamajig: Generate a unique filename for ZMQ dataThomas White
The unique filename is needed by the GUI for looking up results in a stream. Otherwise, the filename is "(null)" for everything and the lookup just returns the first chunk in the stream. The filename is generated based on the unique serial number for each chunk, and is therefore unique across one run of indexamajig regardless of the number of worker processes (-j). This might have to change in future to accommodate jobs run across multiple nodes, if there is any demand for looking at results in one big concatenated stream. This also changes the condition for deciding when to look for a 'real' file, to take into account that there is always a non-NULL filename.
2021-04-23MsgPack: Implement peak list loadingThomas White
2021-04-23MsgPack: More build system fixesThomas White
The changes in b22f6f524 were incorrect. config.h should never be included from libcrystfel headers, because that will include the main CrystFEL program config.h instead.
2021-04-23Clarify some error messagesThomas White
2021-04-23MsgPack: improve an error messageThomas White
2021-04-23MsgPack: Implement extraction of image dataThomas White
2021-04-20MsgPack: Implement decoding numeric valuesThomas White
2021-04-20MsgPack: Improve a warning messageThomas White
2021-04-20image_read_data_block: Warn user if things go wrongThomas White
2021-04-20image_read_data_block: Set the correct data typeThomas White
2021-04-20Build system fixes for MsgPackThomas White
2021-04-19Unify loading of image data and header valuesThomas White
This moves the entry point for loading MsgPack data to a new function, image_read_data_block. Inside image.c, the image structure can be created using exactly the same functions as for data files.
2021-04-19Move file_exists to utils (and eliminate several duplicates)Thomas White
2021-04-16Remove requirement for data path to contain "/"Thomas White
For data formats other than HDF5, the location can be anything.
2021-04-16Meson: Update and fix MsgPack/ZMQ dependenciesThomas White
2021-04-15Separate ZMQ from MessagePack, switch to pub/sub socketThomas White
Indexamajig uses only ZMQ, to receive streaming data, while libcrystfel uses only msgpack to implement another type of image format. The two of these are eventually tied together in process_image, which does this: if ( have_zmq_data ) interpret_zmq_data_as_msgpack; - however, they would be easy to split up if we wanted to do something else (CBF data over ZMQ, anyone?). This commit also switches the ZMQ connector to use a pub/sub socket instead of a request/reply one. This matches changes in OnDA. At the moment, the MessagePack image reader simply dumps the object to disk.
2021-04-01Implement loading of saturation mapThomas White
2021-04-01FromFile indexer, stream2sol.py: Remove space escapingThomas White
This isn't necessary after all, for the same reason that im-sandbox doesn't need escaping: it can count off the fields where spaces aren't allowed, and anything left is the filename. I was over-thinking things.
2021-03-31FromFile indexer, stream2sol.py: Handle spaces in filenameThomas White
2021-03-31FromFile indexer, stream2sol.py: Add/update copyright commentsThomas White
2021-03-30Add header caching layerThomas White
This simultaneously implements --copy-header/--copy-hdf5-field and gives access to metadata (e.g. detector position or wavelength) when loading from a stream with header-specified values.
2021-03-26Add str_integration_methodThomas White
2021-03-25indexamajig: Add --camera-length-estimateThomas White
Unfortunately, PinkIndexer needs the real camera length for its centre refinement. Giving a fake value and scaling the resulting shift does not work - the indexing rate drops with even a small error. Ideally, this would work in the same way as --wavelength-estimate, by using a static value from the geometry file if it's given. However, this is rather complicated to implement because of the way all the units stuff is implemented. Therefore, this is left as an improvement for the future.
2021-03-25Add detgeom_mean_camera_lengthThomas White
2021-03-25PinkIndexer: fix conversion of detector shiftThomas White
2021-03-25FussinessThomas White
The FIXMEs have both already been fixed.
2021-03-25Avoid updating detector geometry structure during prediction refinementThomas White
This makes the behaviour consistent with the prediction itself, and removes another bit of mutable state.
2021-03-23Use crystal's detector shift during predictionThomas White
Previously, this was handled by updating the detector, but this could easily lead to strange double accounting.
2021-03-23Don't automatically set --no-refine --no-check-peaks with PinkIndexerThomas White
See c876486b for rationale.
2021-03-23CMake: ensure RPATH is always set for libcrystfelThomas White
This helps with finding dependencies installed in non-system locations.