27 hid_t group = H5Gcreate2(f, path, H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT);
33 int arrlen = data->
Nmrk;
36 for(
integer i=0; i < arrlen; i++) {
37 mask[i] = data->
id[i] > 0;
46 for(
integer i = 0; i < arrlen; i++) {
48 idarr[j] = data->
id[i];
58 for(
integer i = 0; i < arrlen; i++) {
60 dataarr[j] = data->
Kcoef[i];
67 for(
integer i = 0; i < arrlen; i++) {
69 dataarr[j] = data->
Dcoef[i];
78 H5LTset_attribute_string(group,
"ids",
"unit",
"1");
80 H5LTset_attribute_string(group,
"k",
"unit",
"1/s");
81 H5LTset_attribute_string(group,
"d",
"unit",
"1/s");
84 H5LTset_attribute_string(group,
"k",
"unit",
"m/s");
85 H5LTset_attribute_string(group,
"d",
"unit",
"m^2/s");
Main header file for ASCOT5.
Header file for diag_transcoef.c.
herr_t hdf5_write_extendible_dataset_long(hid_t group, const char *datasetname, int length, long *data)
Create and write to an extendible dataset for long data.
herr_t hdf5_write_extendible_dataset_double(hid_t group, const char *datasetname, int length, double *data)
Create and write to an extendible dataset for double data.
Header file for hdf5_helpers.h.
int hdf5_transcoef_write(hid_t f, char *path, diag_transcoef_data *data)
Write transport coefficients to a HDF5 file.
Header file for hdf5_transcoef.c.
Transport coefficient diagnostics offload data struct.