Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

NXcomponent as a parent base class #1525

Open
wants to merge 15 commits into
base: main
Choose a base branch
from
30 changes: 1 addition & 29 deletions base_classes/NXaperture.nxdl.xml
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@
#
# For further information, see http://www.nexusformat.org
-->
<definition xmlns="http://definition.nexusformat.org/nxdl/3.1" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" category="base" type="group" name="NXaperture" extends="NXobject" xsi:schemaLocation="http://definition.nexusformat.org/nxdl/3.1 ../nxdl.xsd">
<definition xmlns="http://definition.nexusformat.org/nxdl/3.1" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" category="base" type="group" name="NXaperture" extends="NXcomponent" xsi:schemaLocation="http://definition.nexusformat.org/nxdl/3.1 ../nxdl.xsd">
<doc>
A beamline aperture.

Expand All @@ -32,13 +32,6 @@
<!--TODO compare with "screens" in SHADOW-->
<field name="depends_on" type="NX_CHAR">
<doc>
NeXus positions components by applying a set of translations and rotations
to apply to the component starting from 0, 0, 0. The order of these operations
is critical and forms what NeXus calls a dependency chain. The depends_on
field defines the path to the top most operation of the dependency chain or the
string "." if located in the origin. Usually these operations are stored in a
NXtransformations group. But NeXus allows them to be stored anywhere.

The reference point of the aperture is its center in the x and y axis. The reference point on the z axis is the
surface of the aperture pointing towards the source.

Expand All @@ -48,14 +41,6 @@
:width: 40%
</doc>
</field>
<group type="NXtransformations">
<doc>
This is the group recommended for holding the chain of translation
and rotation operations necessary to position the component within
the instrument. The dependency chain may however traverse similar groups in
other component groups.
</doc>
</group>
<group type="NXoff_geometry">
<doc>
Use this group to describe the shape of the aperture.
Expand Down Expand Up @@ -117,17 +102,4 @@
Describe any additional information in a note.
</doc>
</group>
<attribute name="default">
<doc>
.. index:: plotting

Declares which child group contains a path leading
to a :ref:`NXdata` group.

It is recommended (as of NIAC2014) to use this attribute
to help define the path to the default dataset to be plotted.
See https://www.nexusformat.org/2014_How_to_find_default_data.html
for a summary of the discussion.
</doc>
</attribute>
</definition>
31 changes: 1 addition & 30 deletions base_classes/NXattenuator.nxdl.xml
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@
<definition
name="NXattenuator"
type="group"
extends="NXobject"
extends="NXcomponent"
category="base"
xmlns="http://definition.nexusformat.org/nxdl/3.1"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
Expand Down Expand Up @@ -75,46 +75,17 @@
<item value="moving" />
</enumeration>
</field>
<attribute name="default">
<doc>
.. index:: plotting

Declares which child group contains a path leading
to a :ref:`NXdata` group.

It is recommended (as of NIAC2014) to use this attribute
to help define the path to the default dataset to be plotted.
See https://www.nexusformat.org/2014_How_to_find_default_data.html
for a summary of the discussion.
</doc>
</attribute>
<field name="depends_on" type="NX_CHAR">
<doc>
NeXus positions components by applying a set of translations and rotations
to apply to the component starting from 0, 0, 0. The order of these operations
is critical and forms what NeXus calls a dependency chain. The depends_on
field defines the path to the top most operation of the dependency chain or the
string "." if located in the origin. Usually these operations are stored in a
NXtransformations group. But NeXus allows them to be stored anywhere.

The reference point of the attenuator is its center in the x and y axis. The reference point on the z axis is the
surface of the attenuator pointing towards the source.

In complex (asymmetic) geometries an NXoff_geometry group can be used to provide an unambiguous reference.

.. image:: attenuator/attenuator.png
:width: 40%

</doc>
</field>
<group type="NXtransformations">
<doc>
This is the group recommended for holding the chain of translation
and rotation operations necessary to position the component within
the instrument. The dependency chain may however traverse similar groups in
other component groups.
</doc>
</group>
<group name="shape" type="NXoff_geometry">
<doc>
Shape of this component. Particulary useful to define the origin for position and orientation in non-standard cases.
Expand Down
15 changes: 0 additions & 15 deletions base_classes/NXbeam.nxdl.xml
Original file line number Diff line number Diff line change
Expand Up @@ -251,20 +251,6 @@
useful for simulations which need to store plottable information at each beamline
component.</doc>
</group>
<attribute name="default">
<doc>
.. index:: plotting

Declares which child group contains a path leading
to a :ref:`NXdata` group.

It is recommended (as of NIAC2014) to use this attribute
to help define the path to the default dataset to be plotted.
See https://www.nexusformat.org/2014_How_to_find_default_data.html
for a summary of the discussion.
</doc>
</attribute>

<field name="depends_on" minOccurs="0" type="NX_CHAR">
<doc>
The NeXus coordinate system defines the Z axis to be along the nominal beam
Expand All @@ -275,7 +261,6 @@
or a refined beam direction.
</doc>
</field>

<group type="NXtransformations" minOccurs="0">
<doc>
Direction (and location) for the beam. The location of the beam can be given by
Expand Down
31 changes: 1 addition & 30 deletions base_classes/NXbeam_stop.nxdl.xml
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://definition.nexusformat.org/nxdl/3.1 ../nxdl.xsd"
name="NXbeam_stop"
type="group" extends="NXobject">
type="group" extends="NXcomponent">

<doc>
A device that blocks the beam completely, usually to protect a detector.
Expand Down Expand Up @@ -84,42 +84,13 @@
<item value="out"/>
</enumeration>
</field>
<attribute name="default">
<doc>
.. index:: plotting

Declares which child group contains a path leading
to a :ref:`NXdata` group.

It is recommended (as of NIAC2014) to use this attribute
to help define the path to the default dataset to be plotted.
See https://www.nexusformat.org/2014_How_to_find_default_data.html
for a summary of the discussion.
</doc>
</attribute>
<field name="depends_on" type="NX_CHAR">
<doc>
NeXus positions components by applying a set of translations and rotations
to apply to the component starting from 0, 0, 0. The order of these operations
is critical and forms what NeXus calls a dependency chain. The depends_on
field defines the path to the top most operation of the dependency chain or the
string "." if located in the origin. Usually these operations are stored in a
NXtransformations group. But NeXus allows them to be stored anywhere.

The reference point of the beam stop is its center in the x and y axis. The reference point on the z axis is the
surface of the beam stop pointing towards the source.

.. image:: beam_stop/beam_stop.png
:width: 40%

</doc>
</field>
<group type="NXtransformations">
<doc>
This is the group recommended for holding the chain of translation
and rotation operations necessary to position the component within
the instrument. The dependency chain may however traverse similar groups in
other component groups.
</doc>
</group>
</definition>
32 changes: 1 addition & 31 deletions base_classes/NXbending_magnet.nxdl.xml
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://definition.nexusformat.org/nxdl/3.1 ../nxdl.xsd"
name="NXbending_magnet"
type="group" extends="NXobject">
type="group" extends="NXcomponent">

<doc>A bending magnet</doc>
<field name="critical_energy" type="NX_FLOAT" units="NX_ENERGY"/>
Expand Down Expand Up @@ -81,40 +81,10 @@
This group describes the shape of the beam line component
</doc>
</group>
<attribute name="default">
<doc>
.. index:: plotting

Declares which child group contains a path leading
to a :ref:`NXdata` group.

It is recommended (as of NIAC2014) to use this attribute
to help define the path to the default dataset to be plotted.
See https://www.nexusformat.org/2014_How_to_find_default_data.html
for a summary of the discussion.
</doc>
</attribute>
<field name="depends_on" type="NX_CHAR">
<doc>
NeXus positions components by applying a set of translations and rotations
to apply to the component starting from 0, 0, 0. The order of these operations
is critical and forms what NeXus calls a dependency chain. The depends_on
field defines the path to the top most operation of the dependency chain or the
string "." if located in the origin. Usually these operations are stored in a
NXtransformations group. But NeXus allows them to be stored anywhere.

.. todo::
Add a definition for the reference point of a bending magnet.

</doc>
</field>
<group type="NXtransformations">
<doc>
This is the group recommended for holding the chain of translation
and rotation operations necessary to position the component within
the instrument. The dependency chain may however traverse similar groups in
other component groups.
</doc>
</group>

</definition>
31 changes: 1 addition & 30 deletions base_classes/NXcapillary.nxdl.xml
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://definition.nexusformat.org/nxdl/3.1 ../nxdl.xsd"
name="NXcapillary"
type="group" extends="NXobject">
type="group" extends="NXcomponent">

<doc>
A capillary lens to focus the X-ray beam.
Expand Down Expand Up @@ -64,39 +64,10 @@
The focal size in FWHM
</doc>
</field>
<attribute name="default">
<doc>
.. index:: plotting

Declares which child group contains a path leading
to a :ref:`NXdata` group.

It is recommended (as of NIAC2014) to use this attribute
to help define the path to the default dataset to be plotted.
See https://www.nexusformat.org/2014_How_to_find_default_data.html
for a summary of the discussion.
</doc>
</attribute>
<field name="depends_on" type="NX_CHAR">
<doc>
NeXus positions components by applying a set of translations and rotations
to apply to the component starting from 0, 0, 0. The order of these operations
is critical and forms what NeXus calls a dependency chain. The depends_on
field defines the path to the top most operation of the dependency chain or the
string "." if located in the origin. Usually these operations are stored in a
NXtransformations group. But NeXus allows them to be stored anywhere.

.. todo::
Add a definition for the reference point of a capillary lens.

</doc>
</field>
<group type="NXtransformations">
<doc>
This is the group recommended for holding the chain of translation
and rotation operations necessary to position the component within
the instrument. The dependency chain may however traverse similar groups in
other component groups.
</doc>
</group>
</definition>
13 changes: 0 additions & 13 deletions base_classes/NXcite.nxdl.xml
Original file line number Diff line number Diff line change
Expand Up @@ -54,17 +54,4 @@
<field name="bibtex" type="NX_CHAR">
<doc>Bibliographic reference data in BibTeX format.</doc>
</field>
<attribute name="default">
<doc>
.. index:: plotting

Declares which child group contains a path leading
to a :ref:`NXdata` group.

It is recommended (as of NIAC2014) to use this attribute
to help define the path to the default dataset to be plotted.
See https://www.nexusformat.org/2014_How_to_find_default_data.html
for a summary of the discussion.
</doc>
</attribute>
</definition>
30 changes: 1 addition & 29 deletions base_classes/NXcollimator.nxdl.xml
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://definition.nexusformat.org/nxdl/3.1 ../nxdl.xsd"
name="NXcollimator"
type="group" extends="NXobject">
type="group" extends="NXcomponent">

<doc>A beamline collimator.</doc>
<group type="NXgeometry" deprecated="Use the field `depends_on` and :ref:`NXtransformations` to position the collimator and NXoff_geometry to describe its shape instead">
Expand Down Expand Up @@ -71,28 +71,8 @@
This group describes the shape of the beam line component
</doc>
</group>
<attribute name="default">
<doc>
.. index:: plotting

Declares which child group contains a path leading
to a :ref:`NXdata` group.

It is recommended (as of NIAC2014) to use this attribute
to help define the path to the default dataset to be plotted.
See https://www.nexusformat.org/2014_How_to_find_default_data.html
for a summary of the discussion.
</doc>
</attribute>
<field name="depends_on" type="NX_CHAR">
<doc>
NeXus positions components by applying a set of translations and rotations
to apply to the component starting from 0, 0, 0. The order of these operations
is critical and forms what NeXus calls a dependency chain. The depends_on
field defines the path to the top most operation of the dependency chain or the
string "." if located in the origin. Usually these operations are stored in a
NXtransformations group. But NeXus allows them to be stored anywhere.

Assuming a collimator with a "flat" entry surface, the reference plane is the plane which contains this surface. The reference
point of the collimator in the x and y axis is the centre of the collimator entry surface on that plane. The reference plane is orthogonal
to the z axis and the location of this plane is the reference point on the z axis. The collimator faces negative z values.
Expand All @@ -101,12 +81,4 @@
:width: 40%
</doc>
</field>
<group type="NXtransformations">
<doc>
This is the group recommended for holding the chain of translation
and rotation operations necessary to position the component within
the instrument. The dependency chain may however traverse similar groups in
other component groups.
</doc>
</group>
</definition>
Loading
Loading