ASCOT5
|
Module for reading plasma input from HDF5 file. More...
#include <stdio.h>
#include <stdlib.h>
#include <hdf5.h>
#include <hdf5_hl.h>
#include "../ascot5.h"
#include "../plasma.h"
#include "../plasma/plasma_1D.h"
#include "../plasma/plasma_1Dt.h"
#include "../plasma/plasma_1DS.h"
#include "../consts.h"
#include "hdf5_helpers.h"
#include "hdf5_plasma.h"
Go to the source code of this file.
Macros | |
#define | PLSPATH |
#define | PLSPATH "/plasma/plasma_1D_XXXXXXXXXX/" |
#define | PLSPATH "/plasma/plasma_1Dt_XXXXXXXXXX/" |
#define | PLSPATH "/plasma/plasma_1DS_XXXXXXXXXX/" |
Functions | |
int | hdf5_plasma_read_1D (hid_t f, plasma_1D_offload_data *offload_data, real **offload_array, char *qid) |
Read 1D plasma data from HDF5 file. | |
int | hdf5_plasma_read_1Dt (hid_t f, plasma_1Dt_offload_data *offload_data, real **offload_array, char *qid) |
Read 1Dt plasma data from HDF5 file. | |
int | hdf5_plasma_read_1DS (hid_t f, plasma_1DS_offload_data *offload_data, real **offload_array, char *qid) |
Load plasma data from HDF5 file and prepare parameters. | |
int | hdf5_plasma_init_offload (hid_t f, plasma_offload_data *offload_data, real **offload_array, char *qid) |
Read plasma data from HDF5 file. | |
Module for reading plasma input from HDF5 file.
Plasma data must be read by calling hdf5_plasma_init_offload() contained in this module. This module contains reading routines for all plasma data types.
Definition in file hdf5_plasma.c.
#define PLSPATH |
Macro that is used to store paths to data groups
Definition at line 22 of file hdf5_plasma.c.
#define PLSPATH "/plasma/plasma_1D_XXXXXXXXXX/" |
Macro that is used to store paths to data groups
Definition at line 22 of file hdf5_plasma.c.
#define PLSPATH "/plasma/plasma_1Dt_XXXXXXXXXX/" |
Macro that is used to store paths to data groups
Definition at line 22 of file hdf5_plasma.c.
#define PLSPATH "/plasma/plasma_1DS_XXXXXXXXXX/" |
Macro that is used to store paths to data groups
Definition at line 22 of file hdf5_plasma.c.
int hdf5_plasma_read_1D | ( | hid_t | f, |
plasma_1D_offload_data * | offload_data, | ||
real ** | offload_array, | ||
char * | qid ) |
Read 1D plasma data from HDF5 file.
f | HDF5 file from which data is read |
offload_data | pointer to offload data |
offload_array | pointer to offload array |
qid | QID of the data |
Definition at line 91 of file hdf5_plasma.c.
int hdf5_plasma_read_1Dt | ( | hid_t | f, |
plasma_1Dt_offload_data * | offload_data, | ||
real ** | offload_array, | ||
char * | qid ) |
Read 1Dt plasma data from HDF5 file.
f | HDF5 file from which data is read |
offload_data | pointer to offload data |
offload_array | pointer to offload array |
qid | QID of the data |
Definition at line 175 of file hdf5_plasma.c.
int hdf5_plasma_read_1DS | ( | hid_t | f, |
plasma_1DS_offload_data * | offload_data, | ||
real ** | offload_array, | ||
char * | qid ) |
Load plasma data from HDF5 file and prepare parameters.
This function reads the 1D plasma data from file f, fills the offload struct with parameters and allocates and fills the offload array.
f | hdf5 file identifier |
offload_data | pointer to offload data struct |
offload_array | pointer to pointer to offload array |
qid | QID of the data |
Definition at line 309 of file hdf5_plasma.c.
int hdf5_plasma_init_offload | ( | hid_t | f, |
plasma_offload_data * | offload_data, | ||
real ** | offload_array, | ||
char * | qid ) |
Read plasma data from HDF5 file.
This function reads plasma data with given qid while also initializing offload data and allocating and filling offload array. The file is opened and closed outside this function.
f | HDF5 file from which data is read |
offload_data | pointer to offload data |
offload_array | pointer to offload array |
qid | QID of the data |
Definition at line 44 of file hdf5_plasma.c.