generated.docs.javadoc.org.eclipse.dawnsci.nexus.NXtransformations.html Maven / Gradle / Ivy
NXtransformations (h5jan API)
org.eclipse.dawnsci.nexus
Interface NXtransformations
-
- All Known Implementing Classes:
- NXtransformationsImpl
public interface NXtransformations
extends NXobject
Collection of axis-based translations and rotations to describe a geometry.
May also contain axes that do not move and therefore do not have a transformation
type specified, but are useful in understanding coordinate frames within which
transformations are done, or in documenting important directions, such as the
direction of gravity.
A nested sequence of transformations lists the offset and rotation steps
needed to describe the position and orientation of any movable or fixed device.
There will be one or more transformations (axes) defined by one or more fields
for each transformation. The all-caps name ``AXISNAME`` designates the
particular axis generating a transformation (e.g. a rotation axis or a translation
axis or a general axis). The attribute ``units="NX_TRANSFORMATION"`` designates the
units will be appropriate to the ``transformation_type`` attribute:
* ``NX_LENGTH`` for ``translation``
* ``NX_ANGLE`` for ``rotation``
* ``NX_UNITLESS`` for axes for which no transformation type is specified
This class will usually contain all axes of a sample stage or goniometer or
a detector. The NeXus default McSTAS coordinate frame is assumed, but additional
useful coordinate axes may be defined by using axes for which no transformation
type has been specified.
The entry point (``depends_on``) will be outside of this class and point to a
field in here. Following the chain may also require following ``depends_on``
links to transformations outside, for example to a common base table. If
a relative path is given, it is relative to the group enclosing the ``depends_on``
specification.
For a chain of three transformations, where :math:`T_1` depends on :math:`T_2`
and that in turn depends on :math:`T_3`, the final transformation :math:`T_f` is
.. math:: T_f = T_3 T_2 T_1
In explicit terms, the transformations are a subset of affine transformations
expressed as 4x4 matrices that act on homogeneous coordinates, :math:`w=(x,y,z,1)^T`.
For rotation and translation,
.. math:: T_r &= \begin{pmatrix} R & o \\ 0_3 & 1 \end{pmatrix} \\ T_t &= \begin{pmatrix} I_3 & t + o \\ 0_3 & 1 \end{pmatrix}
where :math:`R` is the usual 3x3 rotation matrix, :math:`o` is an offset vector,
:math:`0_3` is a row of 3 zeros, :math:`I_3` is the 3x3 identity matrix and
:math:`t` is the translation vector.
:math:`o` is given the ``offset`` attribute, :math:`t` is given by the ``vector``
attribute multiplied by the field value, and :math:`R` is defined as a rotation
about an axis in the direction of ``vector``, of angle of the field value.
-
-
Field Summary
Fields
Modifier and Type
Field and Description
static java.lang.String
NX_AXISNAME
static java.lang.String
NX_AXISNAME_ATTRIBUTE_DEPENDS_ON
static java.lang.String
NX_AXISNAME_ATTRIBUTE_OFFSET
static java.lang.String
NX_AXISNAME_ATTRIBUTE_OFFSET_UNITS
static java.lang.String
NX_AXISNAME_ATTRIBUTE_TRANSFORMATION_TYPE
static java.lang.String
NX_AXISNAME_ATTRIBUTE_VECTOR
static java.lang.String
NX_AXISNAME_END
static java.lang.String
NX_AXISNAME_INCREMENT_SET
-
Method Summary
All Methods Instance Methods Abstract Methods
Modifier and Type
Method and Description
java.util.Map<java.lang.String,? extends IDataset>
getAllAXISNAME_end()
Get all AXISNAME_end fields:
``AXISNAME_end`` is a placeholder for a name constructed from the actual
name of an axis to which ``_end`` has been appended.
java.util.Map<java.lang.String,? extends IDataset>
getAllAXISNAME_increment_set()
Get all AXISNAME_increment_set fields:
``AXISNAME_increment_set`` is a placeholder for a name constructed from the actual
name of an axis to which ``_increment_set`` has been appended.
java.util.Map<java.lang.String,? extends IDataset>
getAllAXISNAME()
Get all AXISNAME fields:
Units need to be appropriate for translation or rotation
The name of this field is not forced.
IDataset
getAXISNAME_end()
``AXISNAME_end`` is a placeholder for a name constructed from the actual
name of an axis to which ``_end`` has been appended.
java.lang.Number
getAXISNAME_endScalar()
``AXISNAME_end`` is a placeholder for a name constructed from the actual
name of an axis to which ``_end`` has been appended.
IDataset
getAXISNAME_increment_set()
``AXISNAME_increment_set`` is a placeholder for a name constructed from the actual
name of an axis to which ``_increment_set`` has been appended.
java.lang.Number
getAXISNAME_increment_setScalar()
``AXISNAME_increment_set`` is a placeholder for a name constructed from the actual
name of an axis to which ``_increment_set`` has been appended.
IDataset
getAXISNAME()
Units need to be appropriate for translation or rotation
The name of this field is not forced.
java.lang.String
getAXISNAMEAttributeDepends_on()
Points to the path to a field defining the axis on which this
depends or the string ".".
java.lang.String
getAXISNAMEAttributeOffset_units()
Units of the offset.
java.lang.Number
getAXISNAMEAttributeOffset()
A fixed offset applied before the transformation (three vector components).
java.lang.String
getAXISNAMEAttributeTransformation_type()
The transformation_type may be ``translation``, in which case the
values are linear displacements along the axis, ``rotation``,
in which case the values are angular rotations around the axis.
java.lang.Number
getAXISNAMEAttributeVector()
Three values that define the axis for this transformation.
java.lang.Number
getAXISNAMEScalar()
Units need to be appropriate for translation or rotation
The name of this field is not forced.
DataNode
setAXISNAME_end(IDataset AXISNAME_end)
``AXISNAME_end`` is a placeholder for a name constructed from the actual
name of an axis to which ``_end`` has been appended.
DataNode
setAXISNAME_endScalar(java.lang.Number AXISNAME_end)
``AXISNAME_end`` is a placeholder for a name constructed from the actual
name of an axis to which ``_end`` has been appended.
DataNode
setAXISNAME_increment_set(IDataset AXISNAME_increment_set)
``AXISNAME_increment_set`` is a placeholder for a name constructed from the actual
name of an axis to which ``_increment_set`` has been appended.
DataNode
setAXISNAME_increment_setScalar(java.lang.Number AXISNAME_increment_set)
``AXISNAME_increment_set`` is a placeholder for a name constructed from the actual
name of an axis to which ``_increment_set`` has been appended.
DataNode
setAXISNAME(IDataset AXISNAME)
Units need to be appropriate for translation or rotation
The name of this field is not forced.
void
setAXISNAMEAttributeDepends_on(java.lang.String depends_on)
Points to the path to a field defining the axis on which this
depends or the string ".".
void
setAXISNAMEAttributeOffset_units(java.lang.String offset_units)
Units of the offset.
void
setAXISNAMEAttributeOffset(java.lang.Number offset)
A fixed offset applied before the transformation (three vector components).
void
setAXISNAMEAttributeTransformation_type(java.lang.String transformation_type)
The transformation_type may be ``translation``, in which case the
values are linear displacements along the axis, ``rotation``,
in which case the values are angular rotations around the axis.
void
setAXISNAMEAttributeVector(java.lang.Number vector)
Three values that define the axis for this transformation.
DataNode
setAXISNAMEScalar(java.lang.Number AXISNAME)
Units need to be appropriate for translation or rotation
The name of this field is not forced.
-
Methods inherited from interface org.eclipse.dawnsci.nexus.NXobject
addExternalLink, canAddChild, createDataNode, getAllDatasets, getAttr, getAttrBoolean, getAttrDate, getAttrDouble, getAttrLong, getAttrNumber, getAttrString, getBoolean, getChild, getChildren, getChildren, getDataset, getDate, getDouble, getLazyWritableDataset, getLong, getNexusBaseClass, getNumber, getNXclass, getPermittedChildGroupClasses, getString, initializeFixedSizeLazyDataset, initializeLazyDataset, initializeLazyDataset, putChild, setAttribute, setChildren, setDataset, setField
-
Methods inherited from interface org.eclipse.dawnsci.analysis.api.tree.GroupNode
addDataNode, addGroupNode, addNode, addNodeLink, addSymbolicNode, containsDataNode, containsGroupNode, containsNode, containsSymbolicNode, findLinkedNodeName, findNodeLink, getDataNode, getDataNodeMap, getDataNodes, getDatasets, getGlobalPool, getGroupNode, getGroupNodeMap, getGroupNodes, getNames, getNode, getNodeLink, getNodeNameIterator, getNumberOfDataNodes, getNumberOfGroupNodes, getNumberOfNodelinks, getSymbolicNode, isPopulated, iterator, removeDataNode, removeDataNode, removeGroupNode, removeGroupNode, removeSymbolicNode, removeSymbolicNode, setGlobalPool
-
Methods inherited from interface org.eclipse.dawnsci.analysis.api.tree.Node
addAttribute, containsAttribute, getAttribute, getAttributeIterator, getAttributeNameIterator, getID, getNumberOfAttributes, isDataNode, isGroupNode, isSymbolicNode
-
-
Field Detail
-
NX_AXISNAME
static final java.lang.String NX_AXISNAME
- See Also:
- Constant Field Values
-
NX_AXISNAME_ATTRIBUTE_TRANSFORMATION_TYPE
static final java.lang.String NX_AXISNAME_ATTRIBUTE_TRANSFORMATION_TYPE
- See Also:
- Constant Field Values
-
NX_AXISNAME_ATTRIBUTE_VECTOR
static final java.lang.String NX_AXISNAME_ATTRIBUTE_VECTOR
- See Also:
- Constant Field Values
-
NX_AXISNAME_ATTRIBUTE_OFFSET
static final java.lang.String NX_AXISNAME_ATTRIBUTE_OFFSET
- See Also:
- Constant Field Values
-
NX_AXISNAME_ATTRIBUTE_OFFSET_UNITS
static final java.lang.String NX_AXISNAME_ATTRIBUTE_OFFSET_UNITS
- See Also:
- Constant Field Values
-
NX_AXISNAME_ATTRIBUTE_DEPENDS_ON
static final java.lang.String NX_AXISNAME_ATTRIBUTE_DEPENDS_ON
- See Also:
- Constant Field Values
-
NX_AXISNAME_END
static final java.lang.String NX_AXISNAME_END
- See Also:
- Constant Field Values
-
NX_AXISNAME_INCREMENT_SET
static final java.lang.String NX_AXISNAME_INCREMENT_SET
- See Also:
- Constant Field Values
-
Method Detail
-
getAXISNAME
IDataset getAXISNAME()
Units need to be appropriate for translation or rotation
The name of this field is not forced. The user is free to use any name
that does not cause confusion. When using more than one ``AXISNAME`` field,
make sure that each field name is unique in the same group, as required
by HDF5.
The values given should be the start points of exposures for the corresponding
frames. The end points should be given in ``AXISNAME_end``.
Units: NX_TRANSFORMATION
Type: NX_NUMBER
- Returns:
- the value.
-
setAXISNAME
DataNode setAXISNAME(IDataset AXISNAME)
Units need to be appropriate for translation or rotation
The name of this field is not forced. The user is free to use any name
that does not cause confusion. When using more than one ``AXISNAME`` field,
make sure that each field name is unique in the same group, as required
by HDF5.
The values given should be the start points of exposures for the corresponding
frames. The end points should be given in ``AXISNAME_end``.
Units: NX_TRANSFORMATION
Type: NX_NUMBER
- Parameters:
AXISNAME
- the AXISNAME
-
getAXISNAMEScalar
java.lang.Number getAXISNAMEScalar()
Units need to be appropriate for translation or rotation
The name of this field is not forced. The user is free to use any name
that does not cause confusion. When using more than one ``AXISNAME`` field,
make sure that each field name is unique in the same group, as required
by HDF5.
The values given should be the start points of exposures for the corresponding
frames. The end points should be given in ``AXISNAME_end``.
Units: NX_TRANSFORMATION
Type: NX_NUMBER
- Returns:
- the value.
-
setAXISNAMEScalar
DataNode setAXISNAMEScalar(java.lang.Number AXISNAME)
Units need to be appropriate for translation or rotation
The name of this field is not forced. The user is free to use any name
that does not cause confusion. When using more than one ``AXISNAME`` field,
make sure that each field name is unique in the same group, as required
by HDF5.
The values given should be the start points of exposures for the corresponding
frames. The end points should be given in ``AXISNAME_end``.
Units: NX_TRANSFORMATION
Type: NX_NUMBER
- Parameters:
AXISNAME
- the AXISNAME
-
getAllAXISNAME
java.util.Map<java.lang.String,? extends IDataset> getAllAXISNAME()
Get all AXISNAME fields:
Units need to be appropriate for translation or rotation
The name of this field is not forced. The user is free to use any name
that does not cause confusion. When using more than one ``AXISNAME`` field,
make sure that each field name is unique in the same group, as required
by HDF5.
The values given should be the start points of exposures for the corresponding
frames. The end points should be given in ``AXISNAME_end``.
Units: NX_TRANSFORMATION
Type: NX_NUMBER
- Returns:
- a map from node names to the ? extends IDataset for that node.
-
getAXISNAMEAttributeTransformation_type
java.lang.String getAXISNAMEAttributeTransformation_type()
The transformation_type may be ``translation``, in which case the
values are linear displacements along the axis, ``rotation``,
in which case the values are angular rotations around the axis.
If this attribute is omitted, this is an axis for which there
is no motion to be specifies, such as the direction of gravity,
or the direction to the source, or a basis vector of a
coordinate frame.
Enumeration:
- translation
- rotation
- Returns:
- the value.
-
setAXISNAMEAttributeTransformation_type
void setAXISNAMEAttributeTransformation_type(java.lang.String transformation_type)
The transformation_type may be ``translation``, in which case the
values are linear displacements along the axis, ``rotation``,
in which case the values are angular rotations around the axis.
If this attribute is omitted, this is an axis for which there
is no motion to be specifies, such as the direction of gravity,
or the direction to the source, or a basis vector of a
coordinate frame.
Enumeration:
- translation
- rotation
- Parameters:
transformation_type
- the transformation_type
-
getAXISNAMEAttributeVector
java.lang.Number getAXISNAMEAttributeVector()
Three values that define the axis for this transformation.
The axis should be normalized to unit length, making it
dimensionless. For ``rotation`` axes, the direction should be
chosen for a right-handed rotation with increasing angle.
For ``translation`` axes the direction should be chosen for
increasing displacement.
1: 3;
- Returns:
- the value.
-
setAXISNAMEAttributeVector
void setAXISNAMEAttributeVector(java.lang.Number vector)
Three values that define the axis for this transformation.
The axis should be normalized to unit length, making it
dimensionless. For ``rotation`` axes, the direction should be
chosen for a right-handed rotation with increasing angle.
For ``translation`` axes the direction should be chosen for
increasing displacement.
1: 3;
- Parameters:
vector
- the vector
-
getAXISNAMEAttributeOffset
java.lang.Number getAXISNAMEAttributeOffset()
A fixed offset applied before the transformation (three vector components).
1: 3;
- Returns:
- the value.
-
setAXISNAMEAttributeOffset
void setAXISNAMEAttributeOffset(java.lang.Number offset)
A fixed offset applied before the transformation (three vector components).
1: 3;
- Parameters:
offset
- the offset
-
getAXISNAMEAttributeOffset_units
java.lang.String getAXISNAMEAttributeOffset_units()
Units of the offset. Values should be consistent with NX_LENGTH.
- Returns:
- the value.
-
setAXISNAMEAttributeOffset_units
void setAXISNAMEAttributeOffset_units(java.lang.String offset_units)
Units of the offset. Values should be consistent with NX_LENGTH.
- Parameters:
offset_units
- the offset_units
-
getAXISNAMEAttributeDepends_on
java.lang.String getAXISNAMEAttributeDepends_on()
Points to the path to a field defining the axis on which this
depends or the string ".".
- Returns:
- the value.
-
setAXISNAMEAttributeDepends_on
void setAXISNAMEAttributeDepends_on(java.lang.String depends_on)
Points to the path to a field defining the axis on which this
depends or the string ".".
- Parameters:
depends_on
- the depends_on
-
getAXISNAME_end
IDataset getAXISNAME_end()
``AXISNAME_end`` is a placeholder for a name constructed from the actual
name of an axis to which ``_end`` has been appended.
The values in this field are the end points of the motions that start
at the corresponding positions given in the ``AXISNAME`` field.
Units: NX_TRANSFORMATION
Type: NX_NUMBER
- Returns:
- the value.
-
setAXISNAME_end
DataNode setAXISNAME_end(IDataset AXISNAME_end)
``AXISNAME_end`` is a placeholder for a name constructed from the actual
name of an axis to which ``_end`` has been appended.
The values in this field are the end points of the motions that start
at the corresponding positions given in the ``AXISNAME`` field.
Units: NX_TRANSFORMATION
Type: NX_NUMBER
- Parameters:
AXISNAME_end
- the AXISNAME_end
-
getAXISNAME_endScalar
java.lang.Number getAXISNAME_endScalar()
``AXISNAME_end`` is a placeholder for a name constructed from the actual
name of an axis to which ``_end`` has been appended.
The values in this field are the end points of the motions that start
at the corresponding positions given in the ``AXISNAME`` field.
Units: NX_TRANSFORMATION
Type: NX_NUMBER
- Returns:
- the value.
-
setAXISNAME_endScalar
DataNode setAXISNAME_endScalar(java.lang.Number AXISNAME_end)
``AXISNAME_end`` is a placeholder for a name constructed from the actual
name of an axis to which ``_end`` has been appended.
The values in this field are the end points of the motions that start
at the corresponding positions given in the ``AXISNAME`` field.
Units: NX_TRANSFORMATION
Type: NX_NUMBER
- Parameters:
AXISNAME_end
- the AXISNAME_end
-
getAllAXISNAME_end
java.util.Map<java.lang.String,? extends IDataset> getAllAXISNAME_end()
Get all AXISNAME_end fields:
``AXISNAME_end`` is a placeholder for a name constructed from the actual
name of an axis to which ``_end`` has been appended.
The values in this field are the end points of the motions that start
at the corresponding positions given in the ``AXISNAME`` field.
Units: NX_TRANSFORMATION
Type: NX_NUMBER
- Returns:
- a map from node names to the ? extends IDataset for that node.
-
getAXISNAME_increment_set
IDataset getAXISNAME_increment_set()
``AXISNAME_increment_set`` is a placeholder for a name constructed from the actual
name of an axis to which ``_increment_set`` has been appended.
The value of this optional field is the intended average range through which
the corresponding axis moves during the exposure of a frame. Ideally, the
value of this field added to each value of ``AXISNAME`` would agree with the
corresponding values of ``AXISNAME_end``, but there is a possibility of significant
differences. Use of ``AXISNAME_end`` is recommended.
Units: NX_TRANSFORMATION
Type: NX_NUMBER
- Returns:
- the value.
-
setAXISNAME_increment_set
DataNode setAXISNAME_increment_set(IDataset AXISNAME_increment_set)
``AXISNAME_increment_set`` is a placeholder for a name constructed from the actual
name of an axis to which ``_increment_set`` has been appended.
The value of this optional field is the intended average range through which
the corresponding axis moves during the exposure of a frame. Ideally, the
value of this field added to each value of ``AXISNAME`` would agree with the
corresponding values of ``AXISNAME_end``, but there is a possibility of significant
differences. Use of ``AXISNAME_end`` is recommended.
Units: NX_TRANSFORMATION
Type: NX_NUMBER
- Parameters:
AXISNAME_increment_set
- the AXISNAME_increment_set
-
getAXISNAME_increment_setScalar
java.lang.Number getAXISNAME_increment_setScalar()
``AXISNAME_increment_set`` is a placeholder for a name constructed from the actual
name of an axis to which ``_increment_set`` has been appended.
The value of this optional field is the intended average range through which
the corresponding axis moves during the exposure of a frame. Ideally, the
value of this field added to each value of ``AXISNAME`` would agree with the
corresponding values of ``AXISNAME_end``, but there is a possibility of significant
differences. Use of ``AXISNAME_end`` is recommended.
Units: NX_TRANSFORMATION
Type: NX_NUMBER
- Returns:
- the value.
-
setAXISNAME_increment_setScalar
DataNode setAXISNAME_increment_setScalar(java.lang.Number AXISNAME_increment_set)
``AXISNAME_increment_set`` is a placeholder for a name constructed from the actual
name of an axis to which ``_increment_set`` has been appended.
The value of this optional field is the intended average range through which
the corresponding axis moves during the exposure of a frame. Ideally, the
value of this field added to each value of ``AXISNAME`` would agree with the
corresponding values of ``AXISNAME_end``, but there is a possibility of significant
differences. Use of ``AXISNAME_end`` is recommended.
Units: NX_TRANSFORMATION
Type: NX_NUMBER
- Parameters:
AXISNAME_increment_set
- the AXISNAME_increment_set
-
getAllAXISNAME_increment_set
java.util.Map<java.lang.String,? extends IDataset> getAllAXISNAME_increment_set()
Get all AXISNAME_increment_set fields:
``AXISNAME_increment_set`` is a placeholder for a name constructed from the actual
name of an axis to which ``_increment_set`` has been appended.
The value of this optional field is the intended average range through which
the corresponding axis moves during the exposure of a frame. Ideally, the
value of this field added to each value of ``AXISNAME`` would agree with the
corresponding values of ``AXISNAME_end``, but there is a possibility of significant
differences. Use of ``AXISNAME_end`` is recommended.
Units: NX_TRANSFORMATION
Type: NX_NUMBER
- Returns:
- a map from node names to the ? extends IDataset for that node.