FiberVISH 0.2
Fish - The Fiber Bundle API for the Vish Visualization Shell
PrecisionTransformation.hpp
1#ifndef __FIBER_FIBERIO_HDF5_PRECISIONTRANSFORMATION_HPP
2#define __FIBER_FIBERIO_HDF5_PRECISIONTRANSFORMATION_HPP
3
4#include <fiber/field/FiberType.hpp>
5
6#include "F5Fragment.hpp"
7#include "FileNameInterface.hpp"
8#include "HDF5Attributes.hpp"
9
10namespace Fiber
11{
12namespace FiberIO
13{
14namespace HDF5
15{
16
17using namespace Fiber;
18using namespace MemCore;
19
25{
26static constexpr const char NumericalShiftAttributeName[] = FIBER_FRAGMENT_NUMERICALSHIFT_ATTRIBUTE;
27
30
31 FragmentFiberType,
32
35
37
38 bool doTransformPrecision() const;
39
41
47 const string&fragmentname, const string&FieldSource) const;
48
53
60static bool possiblyShiftData(RefPtr<MemBase>&NewData, CreativeArrayBase&theCreator);
61
69 const Fiber::Field&theField,
70 F5Path *myPath);
71
79 AttributeSet_t&DontSaveAttributeSet,
83 );
84
85static void adjustAttributeWriteInformation(
89 );
90
92 reduce_to_single_precision(
93 const FixedArray<double,3>&Shift,
94 const Chunk<Eagle::point3>&Input);
95
97 expand_to_double_precision(
98 const FixedArray<double,3>&Shift,
99 const Chunk<Eagle::point3f>&Input);
100
101};
102
103
104}
105}
106}
107
108#endif // __FIBER_FIBERIO_HDF5_FRAGMENTLOADER
Definition F5Fragment.hpp:12
Base class for multidimensional arrays that employ deferred storage, i.e.
Definition CreativeArrayBase.hpp:75
An iterator with an optional DataCreator, which is just a class to intercept creation of data along a...
Definition CreativeIterator.hpp:34
A class describing an n-dimensional space at runtime.
Definition field/DynamicSize.hpp:29
A Field is a collection of CreativeArrayBase reference pointers which are accessed via FragmentID obj...
Definition Field.hpp:245
Given a fragmented field of curvilinear coordinates, (3D array of coordinates), build a uniform Grid ...
Definition FAQ.dox:2
Definition fs/init.hpp:20
Helper class.
Definition PrecisionTransformation.hpp:25
void shiftAttributes(Attributes &A)
Modify attributes such as the range if the precision is changed during I/O.
Definition PrecisionTransformation.cpp:411
RefPtr< FiberTypeBase > NativeFiberType
The type how it is in the file, if its different.
Definition PrecisionTransformation.hpp:34
RefPtr< FiberTypeBase > FieldFiberType
The type how it shall appear in the fiber bundle field.
Definition PrecisionTransformation.hpp:29
void setFragmentFiberType(const RefPtr< FiberTypeBase > &TheFiberType)
Definition PrecisionTransformation.cpp:27
static bool readPossiblyConvertedData(RefPtr< MemBase > &NewData, CreativeArrayBase &theCreator)
Function is similar to CreativeArrayBase::create() but more efficient than raw HDF5 in case data need...
Definition PrecisionTransformation.cpp:274
static void adjustFileWriteInformation(const StorageTransformations::FilterSettings &FS, CreativeArrayBase &FieldFragmentAttributes, Attributes &OverrideStorageAttributes, AttributeSet_t &DontSaveAttributeSet, RefPtr< ChunkBase > &Mb, bool WriteDoubleTypeInSinglePrecision, bool Write_Shifted_Single_Precision_Range)
Modify the information that will be written to the file.
Definition PrecisionTransformation.cpp:489
static std::pair< bool, hid_t > getFileType(const StorageTransformations::FilterSettings &FS, hid_t Mem_type_hid, const Fiber::Field &theField, F5Path *myPath)
Determine whether that specific field thing shall be written in single precision.
Definition PrecisionTransformation.cpp:127
Definition HDF5Saver.hpp:34
Definition StorageTransformations.hpp:196