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

Fairmat 2024: additional fields in NXdetector #1411

Merged
merged 11 commits into from
Oct 22, 2024
30 changes: 27 additions & 3 deletions base_classes/NXdetector.nxdl.xml
Original file line number Diff line number Diff line change
Expand Up @@ -44,6 +44,7 @@
<symbol name="nP"><doc>number of scan points (only present in scanning measurements)</doc></symbol>
<symbol name="i"><doc>number of detector pixels in the first (slowest) direction</doc></symbol>
<symbol name="j"><doc>number of detector pixels in the second (faster) direction</doc></symbol>
<symbol name="k"><doc>number of detector pixels in the third (if necessary, fastest) direction</doc></symbol>
<symbol name="tof"><doc>number of bins in the time-of-flight histogram</doc></symbol>
lukaspie marked this conversation as resolved.
Show resolved Hide resolved
</symbols>

Expand Down Expand Up @@ -460,9 +461,10 @@
<field name="efficiency" type="NX_FLOAT" units="NX_DIMENSIONLESS">
<doc>efficiency of the detector</doc>

<dimensions rank="2">
<dimensions rank="3">
<dim index="1" value="i" />
<dim index="2" value="j" />
<dim index="3" value="k" />
</dimensions>
</field>

Expand All @@ -480,10 +482,10 @@
In this use case, the efficiency and wavelength arrays must
have the same dimensionality.
</doc>

<dimensions rank="2">
<dimensions rank="3">
<dim index="1" value="i" />
<dim index="2" value="j" />
<dim index="3" value="k" />
</dimensions>
</field>
</group>
Expand Down Expand Up @@ -612,6 +614,7 @@
<item value="event"/>
<item value="histogrammed"/>
<item value="decimated"/>
<item value="pulse counting"/>
</enumeration>
</field>
<field name="angular_calibration_applied" type="NX_BOOLEAN" >
Expand Down Expand Up @@ -889,6 +892,26 @@
This is the thickness of this converter material.
</doc>
</field>
<field name="sensor_size" type="NX_FLOAT" units="NX_LENGTH">
PeterC-DLS marked this conversation as resolved.
Show resolved Hide resolved
<doc>
Size of each imaging sensor chip on the detector.
</doc>
</field>
<field name="sensor_count" type="NX_POSINT" units="NX_UNITLESS">
PeterC-DLS marked this conversation as resolved.
Show resolved Hide resolved
<doc>
Number of imaging sensor chips on the detector.
</doc>
</field>
<field name="sensor_pixel_size" type="NX_FLOAT" units="NX_LENGTH">
<doc>
Physical size of the pixels of the imaging chip on the detector.
</doc>
</field>
<field name="sensor_pixels" type="NX_POSINT" units="NX_UNITLESS">
<doc>
Number of raw active elements in each dimension. Important for swept scans.
</doc>
</field>
<field name="threshold_energy" type="NX_FLOAT" units="NX_ENERGY">
<doc>
Single photon counter detectors can be adjusted
Expand Down Expand Up @@ -930,6 +953,7 @@
</doc>
</group>
</choice>
<group type="NXfabrication"/>
<attribute name="default">
<doc>
.. index:: plotting
Expand Down
60 changes: 60 additions & 0 deletions base_classes/NXelectron_detector.nxdl.xml
Original file line number Diff line number Diff line change
@@ -0,0 +1,60 @@
<?xml version="1.0" encoding="UTF-8"?>
<?xml-stylesheet type="text/xsl" href="nxdlformat.xsl" ?>
<!--
# NeXus - Neutron and X-ray Common Data Format
#
# Copyright (C) 2008-2024 NeXus International Advisory Committee (NIAC)
#
# This library is free software; you can redistribute it and/or
# modify it under the terms of the GNU Lesser General Public
# License as published by the Free Software Foundation; either
# version 3 of the License, or (at your option) any later version.
#
# This library is distributed in the hope that it will be useful,
# but WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
# Lesser General Public License for more details.
#
# You should have received a copy of the GNU Lesser General Public
# License along with this library; if not, write to the Free Software
# Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
#
# For further information, see http://www.nexusformat.org
-->
<definition category="base" extends="NXdetector" name="NXelectron_detector"
type="group"
xsi:schemaLocation="http://definition.nexusformat.org/nxdl/3.1 ../nxdl.xsd"
xmlns="http://definition.nexusformat.org/nxdl/3.1"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xmlns:xs="http://www.w3.org/2001/XMLSchema"
xmlns:ns="http://definition.nexusformat.org/nxdl/@NXDL_RELEASE@"
>
<doc>
A subclass of NXdetector for detectors that detect electrons.
</doc>
<field name="amplifier_type" type="NX_CHAR">
<doc>
Type of electron amplifier, MCP, channeltron, etc.
</doc>
</field>
<field name="detector_type" type="NX_CHAR">
<doc>
Description of the electron detector type, DLD, Phosphor+CCD, CMOS.
</doc>
</field>
<field name="detector_voltage" type="NX_FLOAT" units="NX_VOLTAGE">
<doc>
Voltage applied to the electron detector.
</doc>
</field>
<field name="amplifier_voltage" type="NX_FLOAT" units="NX_VOLTAGE">
<doc>
Voltage applied to the amplifier.
</doc>
</field>
<field name="amplifier_bias" type="NX_FLOAT" units="NX_VOLTAGE">
<doc>
The low voltage of the amplifier might not be the ground.
</doc>
</field>
</definition>
Loading