quick fix for reading a vector field from a file

This commit is contained in:
2024-05-16 10:24:09 +02:00
parent ba84963f96
commit 4cf84d7f9d
+3 -1
View File
@@ -44,8 +44,10 @@ blitz::Array<double, 3> readFromFile(json_t* object) {
blitz::Array<double, 3> readComponentFromFile(json_t* object, int component) {
std::string absolute_filename =
readAbsoluteFilename(json_object_by_path(object, {"PathToH5"}));
DEBUG_LEVEL_3("path to h5: " + absolute_filename);
std::string key = json_string(
json_array_get(json_object_by_path(object, {"PathToH5"}), component));
json_array_get(json_object_by_path(object, {"Keys"}), component));
DEBUG_LEVEL_3("key: " + key);
Hdf5Reader reader(absolute_filename);
return reader.readD3Double(key);