mirror of
https://github.com/openmc-dev/openmc.git
synced 2026-07-27 13:45:36 -04:00
Move write_tally_results_nr to C++
This commit is contained in:
parent
1fd4135f8f
commit
2ccb7e3b58
4 changed files with 131 additions and 130 deletions
|
|
@ -368,6 +368,15 @@ write_dataset(hid_t obj_id, const char* name, const xt::xarray<T>& arr)
|
|||
arr.data(), false);
|
||||
}
|
||||
|
||||
template<typename T, std::size_t N> inline void
|
||||
write_dataset(hid_t obj_id, const char* name, const xt::xtensor<T, N>& arr)
|
||||
{
|
||||
auto s = arr.shape();
|
||||
std::vector<hsize_t> dims {s.cbegin(), s.cend()};
|
||||
write_dataset(obj_id, dims.size(), dims.data(), name, H5TypeMap<T>::type_id,
|
||||
arr.data(), false);
|
||||
}
|
||||
|
||||
inline void
|
||||
write_dataset(hid_t obj_id, const char* name, Position r)
|
||||
{
|
||||
|
|
|
|||
|
|
@ -14,5 +14,7 @@ extern "C" void write_source_bank(hid_t group_id, int64_t* work_index,
|
|||
extern "C" void read_source_bank(hid_t group_id, int64_t* work_index,
|
||||
Bank* source_bank);
|
||||
|
||||
extern "C" void write_tally_results_nr(hid_t file_id);
|
||||
|
||||
} // namespace openmc
|
||||
#endif // OPENMC_STATE_POINT_H
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue