Improve plotting

This commit is contained in:
2024-03-31 23:08:19 +02:00
parent 8cad89d649
commit 30e775d8a2
122 changed files with 4640 additions and 1149 deletions

View File

@@ -28,11 +28,20 @@ void CalcRadialIntegration(const DiffractionExperiment &x, const AzimuthalIntegr
for (hsize_t i = 0; i < x_file_space.GetDimensions()[0]; i += stride) {
std::vector<hsize_t> start = {i, 0, 0};
x_dataset.ReadDirectChunk(buffer, start);
ul.unlock();
JFJochDecompress(uncompressed, CompressionAlgorithm::BSHUF_LZ4, buffer, x.GetPixelsNum());
rad_int.Process(uncompressed.data(), x.GetPixelsNum());
ul.lock();
bool image_loaded = true;
try {
x_dataset.ReadDirectChunk(buffer, start);
} catch (const std::exception &e) {
std::cerr << "Error reading image " << i << " " << e.what() << std::endl;
image_loaded = false;
}
if (image_loaded) {
ul.unlock();
JFJochDecompress(uncompressed, CompressionAlgorithm::BSHUF_LZ4, buffer, x.GetPixelsNum());
rad_int.Process(uncompressed.data(), x.GetPixelsNum());
ul.lock();
}
}
rad_int.GetResult(*result);