write rawfiles (single file) and read rawfiles in order (#66)

* read subfiles with unordered and missing frames

* save work debugging

* Revert "save work debugging"

This reverts commit e791992a05.

* Revert "read subfiles with unordered and missing frames"

This reverts commit 1177fd129d.

* throw when two frames have different frame numbers

* write single part RawFile (working beta)

* correct total number of frames in master file

* add new mythen file with syncd frames

* read frames with same frame number

* clang-tidy fixes, formatting, add tests

* improve readability in loop

* fix failing tests

---------

Co-authored-by: Bechir <bechir.brahem420@gmail.com>
This commit is contained in:
Bechir Braham
2024-05-07 10:46:24 +02:00
committed by GitHub
parent a4850892e0
commit 70acfbf4ac
33 changed files with 718 additions and 284 deletions

View File

@@ -46,15 +46,16 @@ struct sls_detector_header {
};
struct xy {
int row;
int col;
size_t row;
size_t col;
bool operator==(const xy &other) const { return row == other.row && col == other.col; }
bool operator!=(const xy &other) const { return !(*this == other); }
std::string to_string() const { return "{ x: " + std::to_string(row) + " y: " + std::to_string(col) + " }"; }
};
using dynamic_shape = std::vector<ssize_t>;
enum class DetectorType { Jungfrau, Eiger, Mythen3, Moench, ChipTestBoard };
enum class DetectorType { Jungfrau, Eiger, Mythen3, Moench, ChipTestBoard, Unknown };
enum class TimingMode { Auto, Trigger };
@@ -69,17 +70,4 @@ template <> TimingMode StringTo(const std::string & /*mode*/);
using DataTypeVariants = std::variant<uint16_t, uint32_t>;
struct RawFileConfig {
int module_gap_row{};
int module_gap_col{};
bool operator==(const RawFileConfig &other) const {
if (module_gap_col != other.module_gap_col)
return false;
if (module_gap_row != other.module_gap_row)
return false;
return true;
}
};
} // namespace aare