From 53f21ac6863d4075f45edac6277912879c9d3639 Mon Sep 17 00:00:00 2001
From: Lukas Pielsticker <50139597+lukaspie@users.noreply.github.com>
Date: Tue, 25 Apr 2023 08:44:52 +0200
Subject: [PATCH 01/67] Initial draft of NXmpes_xps sub app-def
---
contributed_definitions/nyaml/NXmpes_xps.yaml | 359 ++++++++++++++++++
1 file changed, 359 insertions(+)
create mode 100644 contributed_definitions/nyaml/NXmpes_xps.yaml
diff --git a/contributed_definitions/nyaml/NXmpes_xps.yaml b/contributed_definitions/nyaml/NXmpes_xps.yaml
new file mode 100644
index 0000000000..1679ffbfdb
--- /dev/null
+++ b/contributed_definitions/nyaml/NXmpes_xps.yaml
@@ -0,0 +1,359 @@
+#lukas.pielsticker at cec.mpg.de, 04/2023
+#Draft version of a NeXus application definition for XPS.
+
+doc: This is the application definition for X-ray photoelectron spectroscopy.
+category: application
+NXmpes:
+ (NXentry):
+ title:
+ start_time(NX_DATE_TIME):
+ doc: "ISO8601 formatted Datetime of the start of the measurement."
+ end_time(NX_DATE_TIME):
+ doc: "ISO8601 formatted Datetime of the end of the measurement."
+ definition:
+ \@version:
+ enumeration: ["NXmpes_xps"]
+ (NXuser):
+ doc: "Contact information of at least the user of the instrument or the
+ investigator who performed this experiment.
+ Adding multiple users if relevant is recommended."
+ name(NX_CHAR):
+ exists: recommended
+ doc: "Name of the user."
+ affiliation(NX_CHAR):
+ exists: recommended
+ doc: "Name of the affiliation of the user at the point in time when the
+ experiment was performed."
+ address(NX_CHAR):
+ exists: recommended
+ doc: "Full address (street, street number, ZIP, city, country) of the
+ user's affiliation."
+ email(NX_CHAR):
+ doc: "Email address of the user."
+ orcid(NX_CHAR):
+ exists: recommended
+ doc: "Author ID defined by https://orcid.org/."
+ (NXinstrument):
+ energy_resolution(NX_FLOAT):
+ exists: recommended
+ unit: NX_ENERGY
+ (NXsource):
+ doc: "The source used to generate the primary photons. Properties refer strictly to parameters of the source, not of the output beam. For example, the energy of the source is not the optical power of the beam, but the energy of the electron beam in a synchrotron and so on."
+ type(NX_CHAR):
+ enumeration: [
+ "Synchrotron X-ray Source",
+ "Rotating Anode X-ray",
+ "Fixed Tube X-ray",
+ "UV Laser",
+ "Free-Electron Laser",
+ "Optical Laser",
+ "UV Plasma Source",
+ "Metal Jet X-ray",
+ "HHG laser"
+ ]
+ name(NX_CHAR):
+ doc: "Free text description of the analyzer name used in the laboratory."
+ probe(NX_CHAR):
+ doc: "Type of probe. In XPS it's always X-ray photons, so the full NIAC list is restricted."
+ enumeration: ["x-ray","ultraviolet"]
+ beam_probe(NXbeam):
+ distance(NX_NUMBER):
+ doc: "Distance of the point of evaluation of the beam from the sample surface."
+ exists: recommended
+ unit: NX_LENGTH
+ incident_energy(NX_FLOAT):
+ unit: NX_ENERGY
+ doc: "In the case of a monchromatic beam this is the scalar energy. Several other use cases are permitted, depending on the presence of other incident_energy_X fields. In the case of a polychromatic beam this is an array of length m of energies, with the relative weights in incident_energy_weights. In the case of a monochromatic beam that varies shot-to-shot, this is an array of energies, one for each recorded shot. Here, incident_energy_weights and incident_energy_spread are not set. In the case of a polychromatic beam that varies shot-to-shot, this is an array of length m with the relative weights in incident_energy_weights as a 2D array. In the case of a polychromatic beam that varies shot-to-shot and where the channels also vary, this is a 2D array of dimensions nP by m (slow to fast) with the relative weights in incident_energy_weights as a 2D array. Note, variants are a good way to represent several of these use cases in a single dataset, e.g. if a calibrated, single-value energy value is available along with the original spectrum from which it was calibrated."
+ incident_energy_spread(NX_NUMBER):
+ exists: recommended
+ unit: NX_ENERGY
+ doc: "The energy spread FWHM for the corresponding energy(ies) in incident_energy. In the case of shot-to-shot variation in the energy spread, this is a 2D array of dimension nP by m (slow to fast) of the spreads of the corresponding energy in incident_energy."
+ incident_polarization(NX_NUMBER):
+ exists: recommended
+ doc: "Incident polarization specified as a Stokes vector."
+ \@units(NX_CHAR):
+ doc: "The units for this observable are not included in the NIAC list. Responsibility on correct formatting and parsing is handed to the user by using ‘NX_ANY’. Correct parsing can still be implemented by using this attribute. Fill with: The unit unidata symbol if the unit has one (Example: ‘T’ for the unit of magnetic flux density tesla). The unit unidata name if the unit has a name (Example: ‘farad’ for capacitance). A string describing the units according to unidata unit operation notation, if the unit is a complex combination of named units and does not have a name. Example: for lightsource brilliance (SI) ‘1/(s.mm2.mrad2)’. Here: SI units are ‘V2/m2’."
+ (NXelectronanalyser):
+ description(NX_CHAR):
+ doc: "Free text description of the type of detector."
+ energy_resolution(NX_FLOAT):
+ exists: recommended
+ doc: "Energy resolution of the analyser with the current setting. May be linked from a NXcalibration."
+ unit: NX_ENERGY
+ fast_axes(NX_CHAR):
+ exists: optional
+ doc: "List of the axes that are acquired symultaneously by the detector. These refer only to the experimental variables recorded by the electron analyser. Other variables such as temperature, manipulator angles etc. are labeled as fast or slow in the data. Examples: Hemispherical in XPS mode: fast_axes: [energy] Hemispherical with channeltron, sweeping energy mode: slow_axes: [energy] axes can be less abstract than this, i.e. [detector_x, detector_y]."
+ slow_axes(NX_CHAR):
+ exists: optional
+ doc: "List of the axes that are acquired by scanning a physical parameter, listed in order of decreasing speed. See fast_axes for examples."
+ COLLECTIONCOLUMN(NXcollectioncolumn):
+ scheme(NX_CHAR):
+ doc: "Scheme of the electron collection column."
+ enumeration: [
+ "Standard",
+ "Angular dispersive",
+ "Selective area",
+ "Deflector",
+ ]
+ mode(NX_CHAR):
+ exists: recommended
+ doc: "Labelling of the lens setting in use. Names are typically presets provided by the instrument vendor."
+ tranmission_function(NX_FLOAT):
+ doc: "Transmission function in dependance of the electron kinetic energy. To be used in intensity calibration."
+ (NXenergydispersion):
+ scheme(NX_CHAR):
+ enumeration:
+ [
+ "hemispherical",
+ "double hemispherical",
+ "cylindrical mirror",
+ "display mirror",
+ "retarding grid",
+ ]
+ pass_energy(NX_FLOAT):
+ doc: "Pass energy of energy dispersive element. Determines measurement resolution."
+ unit: NX_ENERGY
+ energy_scan_mode(NX_CHAR):
+ doc: "Way of scanning the energy axis."
+ enumeration: [
+ "fixed analyzer transmission",
+ "fixed retarding ratio",
+ "fixed energies",
+ "snapshot",
+ "detector voltage scan",
+ "constant final state",
+ "constant initial state",
+ ]
+ entrance_slit(NXaperture):
+ exists: optional
+ doc: "Size, position, and shape of the entrance slit in dispersive analyzers (aperture generating the energy filtering)."
+ description(NX_CHAR):
+ doc: "Type of aperture inserted in the beam."
+ enumeration: ["slit", "pinhole", "iris"]
+ shape(NX_CHAR):
+ doc: "Description of the shape of the active part of the aperture, curved or straight for horizontal slits, square or round for pinhole etc."
+ enumeration:
+ [
+ "curved",
+ "straight",
+ "circle",
+ "square",
+ "hexagon",
+ "octagon",
+ "bladed",
+ ]
+ exit_slit(NXaperture):
+ exists: optional
+ doc: "Size, position and shape of the exit slit in dispersive analyzers."
+ description(NX_CHAR):
+ doc: "Type of aperture inserted in the beam."
+ enumeration: ["slit", "pinhole", "iris"]
+ shape(NX_CHAR):
+ doc: "Description of the shape of the active part of the aperture, curved or straight for horizontal slits, square or round for pinhole etc."
+ enumeration:
+ [
+ "curved",
+ "straight",
+ "circle",
+ "square",
+ "hexagon",
+ "octagon",
+ "bladed",
+ ]
+ iris(NXaperture):
+ exists: optional
+ doc: "Size, position, and shape of the iris in dispersive analyzers."
+ description(NX_CHAR):
+ doc: "Type of aperture inserted in the beam."
+ shape(NX_CHAR):
+ doc: "Description of the shape of the active part of the aperture, curved or straight for horizontal slits, square or round for pinhole etc."
+ enumeration:
+ [
+ "curved",
+ "straight",
+ "circle",
+ "square",
+ "hexagon",
+ "octagon",
+ "bladed",
+ ]
+
+ electron_detector(NXdetector):
+ amplifier_type(NX_CHAR):
+ exists: recommended
+ doc: "Type of electron amplifier in the first amplification step."
+ enumeration: ["MCP", "channeltron"]
+ # ToDo: Representation of count rate calibration
+ detector_type(NX_CHAR):
+ exists: recommended
+ doc: "Description of the detector type."
+ enumeration:
+ [
+ "DLD",
+ "Phosphor+CCD",
+ "Phosphor+CMOS",
+ "ECMOS",
+ "Anode",
+ "Multi-anode"]
+ (NXdata): # Raw signal without calibrated axes.
+ exists: recommended
+ \@signal:
+ enumeration: ['raw']
+ raw(NX_NUMBER): # There is a block of numbers named raw.
+ doc: "Raw data before calibration."
+ GEOMETRY(NXtransformations):
+ exists: optional
+ doc: "Transformations describing the transformation chain of all relevant vectors in the experiment."
+ gravity_axis(NX_NUMBER):
+ doc: "Direction of gravity."
+ \@vector(NX_NUMBER):
+ doc: "The vector in the direction of gravity."
+ \@depends_on(NX_CHAR):
+ doc: "Set to '.' to specify the normal vector to which all other vectors are related."
+ beam_axis(NX_NUMBER):
+ doc: "Direction of the photon beam."
+ \@vector(NX_NUMBER):
+ doc: "The vector of the photon-beam direction into the chamber after the last optical element (or directly from the source if there are no optical elements)."
+ \@depends_on(NX_CHAR):
+ doc: "This should be a link to /entry/instrument/geometry/gravity_axis."
+ analyzer_lens_axis(NX_NUMBER):
+ doc: "Direction of lens axis of analyzer."
+ \@vector(NX_NUMBER):
+ doc: "The vector pointing along the central axis of the analyzer lens system in from the sample."
+ \@depends_on(NX_CHAR):
+ doc: "This should be a link to /entry/instrument/geometry/beam_axis."
+ hemisphere_orientation(NX_NUMBER):
+ exists: optional
+ doc: "Orientation of the hemisphere with respect to the lens system in case of a hemispherical electron analyzer."
+ \@vector(NX_NUMBER):
+ doc: "The vector pointing towards the detector from the entrance slit of the hemisphere, and should be perpendicular to the analyzer lens system."
+ \@depends_on(NX_CHAR):
+ doc: "This should be a link to /entry/instrument/geometry/analyzer_lens_axis."
+ (NXmanipulator):
+ exists: optional
+ doc: "Manipulator for positioning of the sample."
+ sample_temperature(NX_FLOAT):
+ exists: recommended
+ doc: "Sample temperature during the experiment. Can be a single float or an array for temperature-programmed XPS."
+ unit: NX_TEMPERATURE
+ sample_heater(NX_CHAR):
+ exists: optional
+ doc: "Method of heating the sample. Can be e.g. electron beam heating, laser, halogen lamp"
+ drain_current(NX_FLOAT):
+ exists: recommended
+ doc: "Measured drain current of the sample."
+ unit: NX_CURRENT
+ sample_bias(NX_FLOAT):
+ exists: recommended
+ doc: "External sample bias."
+ unit: NX_CURRENT
+ calibration(NXprocess):
+ doc: "Document an event of data processing, reconstruction, or analysis for this data.
+ Describe the appropriate axis calibrations for your experiment using
+ one or more of the following NXcalibrations"
+ energy_calibration(NXcalibration):
+ exists: recommended
+ applied(NX_BOOLEAN):
+ doc: "Has an energy calibration been applied?"
+ calibration_file(NX_CHAR):
+ exists: recommended
+ doc: "Name of the calibration file containing the calibration data."
+ calibrated_axis(NX_FLOAT):
+ exists: recommended
+ doc: "This is the calibrated energy axis to be used for data plotting."
+ intensity_calibration(NXcalibration):
+ exists: recommended
+ applied(NX_BOOLEAN):
+ doc: "Has an intensity calibration been applied? I.e., has the transmission function of the analyzer been taken into account?"
+ transmission_function(NX_FLOAT):
+ exists: recommended
+ doc: "Transmission function of the electron collection column. This should be a link to /entry/instrument/collectioncolumn/tranmission_function."
+ calibrated_axis(NX_FLOAT):
+ exists: recommended
+ doc: "This is the calibrated intensity axis to be used for data plotting."
+ spatial_calibration(NXcalibration):
+ exists: optional
+ applied(NX_BOOLEAN):
+ doc: "Has an spatial calibration been applied?"
+ calibrated_axis(NX_FLOAT):
+ exists: recommended
+ doc: "This is the calibrated spatial axis to be used for data plotting."
+ (NXsample):
+ name:
+ doc: "The user-assigned name of the sample."
+ chemical_formula:
+ exists: recommended
+ doc: "The chemical formula of the sample. For mixtures use the NXsample_component group in NXsample instead."
+ sample_history(NXnote):
+ exists: recommended
+ doc: "A descriptor to keep track of the treatment of the sample before entering the photoemission experiment. Ideally, a full report of the previous operations, in any format (NXnote allows to add pictures, audio, movies). Alternatively, a reference to the location or a unique identifier or other metadata file. In the case these are not available, free-text description."
+ atom_types:
+ exists: recommended
+ doc: "List of comma-separated elements from the periodic table that are contained in the sample.
+ If the sample substance has multiple components, all elements from each component must be included in `atom_types`."
+ preparation_date(NX_DATE_TIME):
+ exists: recommended
+ doc: "Date of preparation of the sample for the XPS experiment (i.e. cleaving, last annealing)."
+ preparation_description(NXnote):
+ doc: "Description of the surface preparation technique for the XPS experiment, i.e. UHV cleaving, in-situ growth, sputtering/annealing etc. Ideally, a full report of the previous operations, in any format(NXnote allows to add pictures, audio, movies). Alternatively, a reference to the location or a unique identifier or other metadata file. In the case these are not available, free-text description."
+ temperature(NX_FLOAT):
+ doc: "In the case of a fixed temperature measurement this is the scalar temperature of the sample. In the case of an experiment in which the temperature is changed and recoded, this is an array of length m of temperatures. This should be a link to /entry/instrument/manipulator/sample_temperature."
+ unit: NX_TEMPERATURE
+ situation(NX_CHAR):
+ enumeration:
+ [
+ "vacuum",
+ "inert atmosphere",
+ "oxidising atmosphere",
+ "reducing atmosphere"]
+ # Can be a single number or a log.
+ gas_pressure(NX_FLOAT):
+ unit: NX_PRESSURE
+ doc: "In the case of a fixed pressure measurement this is the scalar pressure. In the case of an experiment in which pressure changes, or anyway it is recorded, this is an array of length m of pressures."
+ gas_phase(NX_CHAR):
+ unit: NX_PRESSURE
+ doc: "In the case of a fixed pressure measurement this is the scalar pressure. In the case of an experiment in which pressure changes, or anyway it is recorded, this is an array of length m of pressures."
+ electric_field(NX_FLOAT):
+ exists: recommended
+ unit: NX_VOLTAGE
+ doc: "Electric field applied to the sample with respect to ground / the system, e.g., via biasing."
+ type(NX_CHAR):
+ exists: optional
+ enumeration:
+ [
+ "foil",
+ "single crystal",
+ "pellet",
+ "powder",
+ "calibration sample",
+ ]
+ (NXdata):
+ doc: "There is an object named data that contains the signal."
+ \@signal:
+ enumeration: ["data"]
+ \@axes(NX_CHAR):
+ doc: "The energy axis. Can be either scanned or derived from scanning of other energy axis."
+ energy(NX_NUMBER):
+ \@units(NX_CHAR):
+ exists: recommended
+ \@long_name(NX_CHAR):
+ exists: optional
+ type(NX_CHAR):
+ exists: recommended
+ doc: "The energy axis can be either in binding or kinetic energy."
+ enumeration:
+ [
+ "kinetic",
+ "energy"
+ ]
+ step_size(NX_CHAR):
+ exists: recommended
+ doc: "The step size between two consecutive energy values."
+ data(NX_NUMBER): # There is a block of numbers named data.
+ doc: "Processed plottable data. Represents a measure of one- or more-dimensional photoemission counts, where
+ the varied axis may be for example energy, spatial coordinate, pump-probe delay, temperature, etc.
+ The axes traces should be linked to the actual encoder position in NXinstrument or calibrated axes in NXprocess."
+ \@units(NX_ANY):
+ exists: recommended
+ \@long_name(NX_CHAR):
+ exists: optional
\ No newline at end of file
From 16e94a4b16dc3a093e41963397305969aa760f2f Mon Sep 17 00:00:00 2001
From: Lukas Pielsticker <50139597+lukaspie@users.noreply.github.com>
Date: Thu, 4 May 2023 13:50:23 +0200
Subject: [PATCH 02/67] Prepare NXmpes_xps for extending NXmpes
---
contributed_definitions/nyaml/NXmpes_xps.yaml | 496 ++++++++++--------
1 file changed, 286 insertions(+), 210 deletions(-)
diff --git a/contributed_definitions/nyaml/NXmpes_xps.yaml b/contributed_definitions/nyaml/NXmpes_xps.yaml
index 1679ffbfdb..e0d17ff779 100644
--- a/contributed_definitions/nyaml/NXmpes_xps.yaml
+++ b/contributed_definitions/nyaml/NXmpes_xps.yaml
@@ -3,63 +3,89 @@
doc: This is the application definition for X-ray photoelectron spectroscopy.
category: application
-NXmpes:
+NXmpes_xps(NXmpes):
(NXentry):
- title:
- start_time(NX_DATE_TIME):
- doc: "ISO8601 formatted Datetime of the start of the measurement."
end_time(NX_DATE_TIME):
- doc: "ISO8601 formatted Datetime of the end of the measurement."
- definition:
- \@version:
+ exists: recommended
+ doc: "Datetime of the end of the measurement."
+ definition(NX_CHAR):
+ \@version(NX_CHAR):
enumeration: ["NXmpes_xps"]
- (NXuser):
- doc: "Contact information of at least the user of the instrument or the
- investigator who performed this experiment.
- Adding multiple users if relevant is recommended."
- name(NX_CHAR):
- exists: recommended
- doc: "Name of the user."
- affiliation(NX_CHAR):
- exists: recommended
- doc: "Name of the affiliation of the user at the point in time when the
- experiment was performed."
- address(NX_CHAR):
- exists: recommended
- doc: "Full address (street, street number, ZIP, city, country) of the
- user's affiliation."
- email(NX_CHAR):
- doc: "Email address of the user."
- orcid(NX_CHAR):
- exists: recommended
- doc: "Author ID defined by https://orcid.org/."
+ # (NXuser): #### nothing changed, can be removed from here?
+ # doc: "Contact information of at least the user of the instrument or the
+ # investigator who performed this experiment.
+ # Adding multiple users if relevant is recommended."
+ # name(NX_CHAR):
+ # exists: recommended
+ # doc: "Name of the user."
+ # affiliation(NX_CHAR):
+ # exists: recommended
+ # doc: "Name of the affiliation of the user at the point in time when the
+ # experiment was performed."
+ # address(NX_CHAR):
+ # exists: recommended
+ # doc: "Full address (street, street number, ZIP, city, country) of the
+ # user's affiliation."
+ # email(NX_CHAR):
+ # doc: "Email address of the user."
+ # orcid(NX_CHAR):
+ # exists: recommended
+ # doc: "Author ID defined by https://orcid.org/."
(NXinstrument):
energy_resolution(NX_FLOAT):
- exists: recommended
+ exists: recommended ###### cannot be required. measured value (typically from Ag 3d5/2 FWHM of sputter-cleaned Ag foil), not known every time and cann update over time (detector degradation).
unit: NX_ENERGY
+ manufacturer(NX_CHAR):
+ exists: recommended
+ doc: "The name of the company that manufactured the spectrometer."
+ enumeration: [
+ "SPECS GmbH",
+ "Kratos",
+ "Physical Electronics",
+ "Scienta",
+ "Thermo Fischer Scientific",
+ ]
(NXsource):
- doc: "The source used to generate the primary photons. Properties refer strictly to parameters of the source, not of the output beam. For example, the energy of the source is not the optical power of the beam, but the energy of the electron beam in a synchrotron and so on."
type(NX_CHAR):
- enumeration: [
+ enumeration: [ ### removed some options from NXmpes
"Synchrotron X-ray Source",
"Rotating Anode X-ray",
"Fixed Tube X-ray",
"UV Laser",
"Free-Electron Laser",
- "Optical Laser",
"UV Plasma Source",
"Metal Jet X-ray",
- "HHG laser"
]
- name(NX_CHAR):
- doc: "Free text description of the analyzer name used in the laboratory."
probe(NX_CHAR):
- doc: "Type of probe. In XPS it's always X-ray photons, so the full NIAC list is restricted."
- enumeration: ["x-ray","ultraviolet"]
- beam_probe(NXbeam):
+ doc: "Type of probe. In XPS it's always X-ray photons (or UV light in UPS), so the full NIAC list is restricted."
+ enumeration: ["x-ray", "ultraviolet"]
+ (NXmonochromator):
+ exists: optional
+ applied(NX_BOOLEAN):
+ doc: "Has the incident beam been monochromatized? "
+ type(NX_CHAR):
+ enumeration: [
+ "Crystal",
+ "Grating",
+ ]
+ crystal(NXcrystal):
+ exists: optional
+ doc: "For crystal based monochromators. Use as many crystals as necessary."
+ grating(NXgrating):
+ exists: optional
+ doc: "For diffraction grating based monochromators. Use as many crystals as necessary."
+ energy(NX_FLOAT):
+ doc: "The scalar energy of the monchromatic beam. This should link to /entry/instrument/beam/incident_energy." ######how to do links?
+ unit: NX_ENERGY
+ energy_error(NX_FLOAT):
+ doc: "The energy spread FWHM for the corresponding energy in energy. This should link to /entry/instrument/beam/incident_energy_spread."
+ unit: NX_ENERGY
+ transformations(NXtransformations) ###### should we describe the beam rotation by the mono?
+ exists: optional
+ (NXbeam):
distance(NX_NUMBER):
- doc: "Distance of the point of evaluation of the beam from the sample surface."
- exists: recommended
+ exists: recommended ### cannot be required, hard to know???
+ doc: "Distance of the point of evaluation of the beam from the sample surface."
unit: NX_LENGTH
incident_energy(NX_FLOAT):
unit: NX_ENERGY
@@ -68,28 +94,24 @@ NXmpes:
exists: recommended
unit: NX_ENERGY
doc: "The energy spread FWHM for the corresponding energy(ies) in incident_energy. In the case of shot-to-shot variation in the energy spread, this is a 2D array of dimension nP by m (slow to fast) of the spreads of the corresponding energy in incident_energy."
- incident_polarization(NX_NUMBER):
- exists: recommended
- doc: "Incident polarization specified as a Stokes vector."
- \@units(NX_CHAR):
- doc: "The units for this observable are not included in the NIAC list. Responsibility on correct formatting and parsing is handed to the user by using ‘NX_ANY’. Correct parsing can still be implemented by using this attribute. Fill with: The unit unidata symbol if the unit has one (Example: ‘T’ for the unit of magnetic flux density tesla). The unit unidata name if the unit has a name (Example: ‘farad’ for capacitance). A string describing the units according to unidata unit operation notation, if the unit is a complex combination of named units and does not have a name. Example: for lightsource brilliance (SI) ‘1/(s.mm2.mrad2)’. Here: SI units are ‘V2/m2’."
+ #incident_polarization(NX_NUMBER):
+ # exists: recommended
+ # doc: "Incident polarization specified as a Stokes vector."
+ # \@units(NX_CHAR):
+ # doc: "The units for this observable are not included in the NIAC list. Responsibility on correct formatting and parsing is handed to the user by using ‘NX_ANY’. Correct parsing can still be implemented by using this attribute. Fill with: The unit unidata symbol if the unit has one (Example: ‘T’ for the unit of magnetic flux density tesla). The unit unidata name if the unit has a name (Example: ‘farad’ for capacitance). A string describing the units according to unidata unit operation notation, if the unit is a complex combination of named units and does not have a name. Example: for lightsource brilliance (SI) ‘1/(s.mm2.mrad2)’. Here: SI units are ‘V2/m2’."
(NXelectronanalyser):
description(NX_CHAR):
doc: "Free text description of the type of detector."
- energy_resolution(NX_FLOAT):
- exists: recommended
- doc: "Energy resolution of the analyser with the current setting. May be linked from a NXcalibration."
- unit: NX_ENERGY
- fast_axes(NX_CHAR):
- exists: optional
- doc: "List of the axes that are acquired symultaneously by the detector. These refer only to the experimental variables recorded by the electron analyser. Other variables such as temperature, manipulator angles etc. are labeled as fast or slow in the data. Examples: Hemispherical in XPS mode: fast_axes: [energy] Hemispherical with channeltron, sweeping energy mode: slow_axes: [energy] axes can be less abstract than this, i.e. [detector_x, detector_y]."
- slow_axes(NX_CHAR):
- exists: optional
- doc: "List of the axes that are acquired by scanning a physical parameter, listed in order of decreasing speed. See fast_axes for examples."
- COLLECTIONCOLUMN(NXcollectioncolumn):
+ # fast_axes(NX_CHAR): ### how to use these?
+ # exists: optional
+ # doc: "List of the axes that are acquired symultaneously by the detector. These refer only to the experimental variables recorded by the electron analyser. Other variables such as temperature, manipulator angles etc. are labeled as fast or slow in the data. Hemispherical in XPS mode: fast_axes: [energy] Hemispherical with channeltron, sweeping energy mode: slow_axes: [energy] axes can be less abstract than this, i.e. [detector_x, detector_y]."
+ # slow_axes(NX_CHAR):
+ # exists: optional
+ # doc: "List of the axes that are acquired by scanning a physical parameter, listed in order of decreasing speed. See fast_axes for examples."
+ (NXcollectioncolumn):
scheme(NX_CHAR):
doc: "Scheme of the electron collection column."
- enumeration: [
+ enumeration: [ ### removed some options from NXmpes
"Standard",
"Angular dispersive",
"Selective area",
@@ -98,11 +120,14 @@ NXmpes:
mode(NX_CHAR):
exists: recommended
doc: "Labelling of the lens setting in use. Names are typically presets provided by the instrument vendor."
+ # projection(NX_CHAR): #### what does this mean?
+ # exists: recommended
tranmission_function(NX_FLOAT):
- doc: "Transmission function in dependance of the electron kinetic energy. To be used in intensity calibration."
+ exists: recommended
+ doc: "Transmission function in dependance of the electron kinetic energy. To be used in intensity calibration." ### does NX_FLOAT make sense?
(NXenergydispersion):
scheme(NX_CHAR):
- enumeration:
+ enumeration: ### removed some options from NXmpes
[
"hemispherical",
"double hemispherical",
@@ -115,93 +140,122 @@ NXmpes:
unit: NX_ENERGY
energy_scan_mode(NX_CHAR):
doc: "Way of scanning the energy axis."
- enumeration: [
+ enumeration: [ ### could potentially add some more here.
"fixed analyzer transmission",
"fixed retarding ratio",
"fixed energies",
"snapshot",
+ "imaging",
"detector voltage scan",
"constant final state",
"constant initial state",
]
- entrance_slit(NXaperture):
- exists: optional
- doc: "Size, position, and shape of the entrance slit in dispersive analyzers (aperture generating the energy filtering)."
- description(NX_CHAR):
- doc: "Type of aperture inserted in the beam."
- enumeration: ["slit", "pinhole", "iris"]
- shape(NX_CHAR):
- doc: "Description of the shape of the active part of the aperture, curved or straight for horizontal slits, square or round for pinhole etc."
- enumeration:
- [
- "curved",
- "straight",
- "circle",
- "square",
- "hexagon",
- "octagon",
- "bladed",
- ]
- exit_slit(NXaperture):
- exists: optional
- doc: "Size, position and shape of the exit slit in dispersive analyzers."
- description(NX_CHAR):
- doc: "Type of aperture inserted in the beam."
- enumeration: ["slit", "pinhole", "iris"]
- shape(NX_CHAR):
- doc: "Description of the shape of the active part of the aperture, curved or straight for horizontal slits, square or round for pinhole etc."
- enumeration:
- [
- "curved",
- "straight",
- "circle",
- "square",
- "hexagon",
- "octagon",
- "bladed",
- ]
- iris(NXaperture):
+ # entrance_slit(NXaperture): ### is this level of description necessary -> most items exist in NXaperture already
+ # exists: optional
+ # doc: "Size, position, and shape of the entrance slit in dispersive analyzers (aperture generating the energy filtering)."
+ # description(NX_CHAR):
+ # exists: optional
+ # doc: "Type of aperture inserted in the beam."
+ # enumeration: ["slit", "pinhole", "iris"]
+ # shape(NX_CHAR):
+ # exists: optional
+ # doc: "Description of the shape of the active part of the aperture, curved or straight for horizontal slits, square or round for pinhole etc."
+ # enumeration:
+ # [
+ # "straight slit",
+ # "curved slit",
+ # "pinhole",
+ # "circle",
+ # "square",
+ # "hexagon",
+ # "octagon",
+ # "bladed",
+ # "open",
+ # "grid"
+ # ]
+ # size(NX_NUMBER):
+ # exists: optional
+ # doc: "The relevant dimension for the entrance_slit, i.e. slit width, pinhole and iris diameter."
+ # exit_slit(NXaperture):
+ # exists: optional
+ # doc: "Size, position and shape of the exit slit in dispersive analyzers."
+ # description(NX_CHAR):
+ # exists: optional
+ # doc: "Type of aperture inserted in the beam."
+ # enumeration: ["slit", "pinhole", "iris"]
+ # shape(NX_CHAR):
+ # exists: optional
+ # doc: "Description of the shape of the active part of the aperture, curved or straight for horizontal slits, square or round for pinhole etc."
+ # enumeration:
+ # [
+ # "straight slit",
+ # "curved slit",
+ # "pinhole",
+ # "circle",
+ # "square",
+ # "hexagon",
+ # "octagon",
+ # "bladed",
+ # "open",
+ # "grid"
+ # ]
+ # size(NX_NUMBER):
+ # exists: optional
+ # doc: "The relevant dimension for the entrance_slit, i.e. slit width, pinhole and iris diameter."
+ # iris(NXaperture):
+ # exists: optional
+ # doc: "Size, position, and shape of the iris in dispersive analyzers."
+ # description(NX_CHAR):
+ # exists: optional
+ # doc: "Type of aperture inserted in the beam."
+ # enumeration: ["slit", "pinhole", "iris"]
+ # shape(NX_CHAR):
+ # exists: optional
+ # doc: "Description of the shape of the active part of the aperture, curved or straight for horizontal slits, square or round for pinhole etc."
+ # enumeration:
+ # [
+ # "straight slit",
+ # "curved slit",
+ # "pinhole",
+ # "circle",
+ # "square",
+ # "hexagon",
+ # "octagon",
+ # "bladed",
+ # "open",
+ # "grid"
+ # ]
+ # size(NX_NUMBER):
+ # exists: optional
+ # doc: "The relevant dimension for the entrance_slit, i.e. slit width, pinhole and iris diameter."
+ analyzer_radius(NX_FLOAT):
exists: optional
- doc: "Size, position, and shape of the iris in dispersive analyzers."
- description(NX_CHAR):
- doc: "Type of aperture inserted in the beam."
- shape(NX_CHAR):
- doc: "Description of the shape of the active part of the aperture, curved or straight for horizontal slits, square or round for pinhole etc."
- enumeration:
- [
- "curved",
- "straight",
- "circle",
- "square",
- "hexagon",
- "octagon",
- "bladed",
- ]
-
- electron_detector(NXdetector):
- amplifier_type(NX_CHAR):
- exists: recommended
- doc: "Type of electron amplifier in the first amplification step."
- enumeration: ["MCP", "channeltron"]
- # ToDo: Representation of count rate calibration
- detector_type(NX_CHAR):
- exists: recommended
- doc: "Description of the detector type."
- enumeration:
- [
- "DLD",
- "Phosphor+CCD",
- "Phosphor+CMOS",
- "ECMOS",
- "Anode",
- "Multi-anode"]
- (NXdata): # Raw signal without calibrated axes.
- exists: recommended
- \@signal:
- enumeration: ['raw']
- raw(NX_NUMBER): # There is a block of numbers named raw.
- doc: "Raw data before calibration."
- GEOMETRY(NXtransformations):
+ description: The radius of the hemispherical analyzer in mm (only if hemispherical analyzer is used.)
+ (NXdetector):
+ # amplifier:type(NX_CHAR):
+ # exists: recommended
+ # doc: "Description of the detector type."
+ # enumeration:
+ # ["MCP", "channeltron"]
+ # detector_type(NX_CHAR):
+ # exists: recommended
+ # doc: "Description of the detector type."
+ # enumeration:
+ # [
+ # "DLD",
+ # "Phosphor+CCD",
+ # "Phosphor+CMOS",
+ # "ECMOS",
+ # "Anode",
+ # "Multi-anode"
+ # ]
+ # (NXdata): # Raw signal without calibrated axes.
+ # exists: recommended
+ # \@signal:
+ # enumeration: ['raw']
+ # raw(NX_NUMBER): # There is a block of numbers named raw.
+ # doc: "Raw data before calibration."
+ GEOMETRY(NXtransformations): ### took this from NXmpes_liqudidjet, how to describe geometry? on indicidual classes? would like to describe angles between different instrument parts here?
exists: optional
doc: "Transformations describing the transformation chain of all relevant vectors in the experiment."
gravity_axis(NX_NUMBER):
@@ -230,110 +284,132 @@ NXmpes:
\@depends_on(NX_CHAR):
doc: "This should be a link to /entry/instrument/geometry/analyzer_lens_axis."
(NXmanipulator):
- exists: optional
- doc: "Manipulator for positioning of the sample."
- sample_temperature(NX_FLOAT):
- exists: recommended
- doc: "Sample temperature during the experiment. Can be a single float or an array for temperature-programmed XPS."
- unit: NX_TEMPERATURE
+ # exists: optional
+ # doc: "Manipulator for positioning of the sample."
+ # sample_temperature(NX_FLOAT):
+ # exists: recommended
+ # doc: "Sample temperature during the experiment. Can be a single float or an array for temperature-programmed XPS."
+ # unit: NX_TEMPERATURE
sample_heater(NX_CHAR):
exists: optional
doc: "Method of heating the sample. Can be e.g. electron beam heating, laser, halogen lamp"
- drain_current(NX_FLOAT):
- exists: recommended
- doc: "Measured drain current of the sample."
- unit: NX_CURRENT
- sample_bias(NX_FLOAT):
- exists: recommended
- doc: "External sample bias."
- unit: NX_CURRENT
- calibration(NXprocess):
- doc: "Document an event of data processing, reconstruction, or analysis for this data.
- Describe the appropriate axis calibrations for your experiment using
- one or more of the following NXcalibrations"
+ # heater_power(NX_FLOAT):
+ # exists: optional
+ # doc: "Power in the heater for temperature control."
+ # sample_temperature(NX_FLOAT):
+ # exists: optional
+ # doc: "Temperature at the closest point to the sample. This field may also be found in NXsample if present."
+ # drain_current(NX_FLOAT):
+ # exists: recommended
+ # doc: "Measured drain current of the sample. This field may also be found in NXsample if present."
+ # unit: NX_CURRENT
+ # sample_bias(NX_FLOAT):
+ # exists: recommended
+ # doc: "Possible bias of the sample with respect to analyser ground. This field may also be found in NXsample if present."
+ # unit: NX_CURRENT
+ (NXprocess):
+ # doc: "Document an event of data processing, reconstruction, or analysis for this data.
+ # Describe the appropriate axis calibrations for your experiment using
+ # one or more of the following NXcalibrations."
energy_calibration(NXcalibration):
- exists: recommended
- applied(NX_BOOLEAN):
- doc: "Has an energy calibration been applied?"
+ # exists: recommended
+ # applied(NX_BOOLEAN):
+ # doc: "Has an energy calibration been applied?"
calibration_file(NX_CHAR):
exists: recommended
doc: "Name of the calibration file containing the calibration data."
- calibrated_axis(NX_FLOAT):
- exists: recommended
- doc: "This is the calibrated energy axis to be used for data plotting."
+ # calibrated_axis(NX_FLOAT):
+ # exists: recommended
+ # doc: "This is the calibrated energy axis to be used for data plotting."
+ # spatial_calibration(NXcalibration):
+ # exists: optional
+ # applied(NX_BOOLEAN):
+ # doc: "Has a spatial calibration been applied?"
+ # calibrated_axis(NX_FLOAT):
+ # exists: recommended
+ # doc: "This is the calibrated spatial axis to be used for data plotting."
intensity_calibration(NXcalibration):
exists: recommended
applied(NX_BOOLEAN):
- doc: "Has an intensity calibration been applied? I.e., has the transmission function of the analyzer been taken into account?"
+ doc: "Has an intensity calibration been applied? That is, has the transmission function of the analyzer been taken into account?"
transmission_function(NX_FLOAT):
exists: recommended
- doc: "Transmission function of the electron collection column. This should be a link to /entry/instrument/collectioncolumn/tranmission_function."
- calibrated_axis(NX_FLOAT):
- exists: recommended
- doc: "This is the calibrated intensity axis to be used for data plotting."
- spatial_calibration(NXcalibration):
- exists: optional
+ doc: "Transmission function of the electron collection column. This should be a link to /entry/instrument/collectioncolumn/tranmission_function."
+ energy_reference(NXcalibration):
+ exists: recommended
applied(NX_BOOLEAN):
- doc: "Has an spatial calibration been applied?"
+ doc: "Have the energy axes been adjusted (e.g., in cases where samples are not conductive)?"
+ emission_line(NX_CHAR):
+ exists: recommended
+ doc: "Emission line which was used for the calibration."
+ offset(NXfloat):
+ exists: recommended
+ doc: "Offset between measured binding energy and calibrated binding energy of the emission line."
+ binding_energy(NX_float):
+ exists: recommended
+ doc: "The binding energy that the specified emission line appeared at, after adjusting the binding energy scale, in units of eV"
calibrated_axis(NX_FLOAT):
exists: recommended
- doc: "This is the calibrated spatial axis to be used for data plotting."
+ doc: "This is the calibrated energy axis to be used for data plotting. This should be a link to /entry/data/energy." ######????
(NXsample):
- name:
+ name(NX_CHAR):
doc: "The user-assigned name of the sample."
- chemical_formula:
- exists: recommended
- doc: "The chemical formula of the sample. For mixtures use the NXsample_component group in NXsample instead."
- sample_history(NXnote):
- exists: recommended
- doc: "A descriptor to keep track of the treatment of the sample before entering the photoemission experiment. Ideally, a full report of the previous operations, in any format (NXnote allows to add pictures, audio, movies). Alternatively, a reference to the location or a unique identifier or other metadata file. In the case these are not available, free-text description."
- atom_types:
- exists: recommended
- doc: "List of comma-separated elements from the periodic table that are contained in the sample.
- If the sample substance has multiple components, all elements from each component must be included in `atom_types`."
- preparation_date(NX_DATE_TIME):
- exists: recommended
- doc: "Date of preparation of the sample for the XPS experiment (i.e. cleaving, last annealing)."
- preparation_description(NXnote):
- doc: "Description of the surface preparation technique for the XPS experiment, i.e. UHV cleaving, in-situ growth, sputtering/annealing etc. Ideally, a full report of the previous operations, in any format(NXnote allows to add pictures, audio, movies). Alternatively, a reference to the location or a unique identifier or other metadata file. In the case these are not available, free-text description."
- temperature(NX_FLOAT):
- doc: "In the case of a fixed temperature measurement this is the scalar temperature of the sample. In the case of an experiment in which the temperature is changed and recoded, this is an array of length m of temperatures. This should be a link to /entry/instrument/manipulator/sample_temperature."
- unit: NX_TEMPERATURE
- situation(NX_CHAR):
+ description(NX_CHAR):
+ exists: optional
+ doc: "Full description of the sample."
+ # chemical_formula:
+ # exists: recommended
+ # doc: "The chemical formula of the sample. For mixtures use the NXsample_component group in NXsample instead."
+ # atom_types:
+ # exists: recommended
+ # doc: "List of comma-separated elements from the periodic table that are contained in the sample.
+ # If the sample substance has multiple components, all elements from each component must be included in `atom_types`."
+ form(NX_CHAR):
+ exists: optional
+ enumeration:
+ [
+ "foil",
+ "single crystal",
+ "pellet",
+ "powder",
+ "calibration sample",
+ ]
+ # preparation_date(NX_DATE_TIME):
+ # exists: recommended
+ # doc: "Date of preparation of the sample for the XPS experiment (i.e. cleaving, last annealing)."
+ # temperature(NX_FLOAT):
+ # doc: "In the case of a fixed temperature measurement this is the scalar temperature of the sample. In the case of an experiment in which the temperature is changed and recoded, this is an array of length m of temperatures. This should be a link to /entry/instrument/manipulator/sample_temperature."
+ # unit: NX_TEMPERATURE
+ situation(NX_CHAR): ### missing some enumerations here
enumeration:
[
"vacuum",
"inert atmosphere",
"oxidising atmosphere",
- "reducing atmosphere"]
- # Can be a single number or a log.
- gas_pressure(NX_FLOAT):
+ "reducing atmosphere",
+ "other"
+ ]
+ gas_pressure(NX_FLOAT): ######## Can be a single number or a log.
unit: NX_PRESSURE
doc: "In the case of a fixed pressure measurement this is the scalar pressure. In the case of an experiment in which pressure changes, or anyway it is recorded, this is an array of length m of pressures."
+ # sample_history(NXnote):
+ # exists: recommended
+ # doc: "A descriptor to keep track of the treatment of the sample before entering the photoemission experiment. Ideally, a full report of the previous operations, in any format (NXnote allows to add pictures, audio, movies). Alternatively, a reference to the location or a unique identifier or other metadata file. In the case these are not available, free-text description."
+ # preparation_description(NXnote):
+ # doc: "Description of the surface preparation technique for the XPS experiment, i.e. UHV cleaving, in-situ growth, sputtering/annealing etc. Ideally, a full report of the previous operations, in any format(NXnote allows to add pictures, audio, movies). Alternatively, a reference to the location or a unique identifier or other metadata file. In the case these are not available, free-text description."
gas_phase(NX_CHAR):
- unit: NX_PRESSURE
- doc: "In the case of a fixed pressure measurement this is the scalar pressure. In the case of an experiment in which pressure changes, or anyway it is recorded, this is an array of length m of pressures."
+ exists: optional
+ doc: "Description of the constitutent gases of the gas phase."
electric_field(NX_FLOAT):
- exists: recommended
+ exists: optional
unit: NX_VOLTAGE
doc: "Electric field applied to the sample with respect to ground / the system, e.g., via biasing."
- type(NX_CHAR):
- exists: optional
- enumeration:
- [
- "foil",
- "single crystal",
- "pellet",
- "powder",
- "calibration sample",
- ]
(NXdata):
- doc: "There is an object named data that contains the signal."
- \@signal:
- enumeration: ["data"]
+ # \@signal:
+ # enumeration: ["data"]
\@axes(NX_CHAR):
doc: "The energy axis. Can be either scanned or derived from scanning of other energy axis."
- energy(NX_NUMBER):
+ energy(NX_NUMBER): #### how to represent this here?
\@units(NX_CHAR):
exists: recommended
\@long_name(NX_CHAR):
@@ -347,7 +423,7 @@ NXmpes:
"energy"
]
step_size(NX_CHAR):
- exists: recommended
+ exists: optional
doc: "The step size between two consecutive energy values."
data(NX_NUMBER): # There is a block of numbers named data.
doc: "Processed plottable data. Represents a measure of one- or more-dimensional photoemission counts, where
From 65bfb910b0979ff0b08ab099057eecce110cf493 Mon Sep 17 00:00:00 2001
From: Lukas Pielsticker <50139597+lukaspie@users.noreply.github.com>
Date: Thu, 4 May 2023 18:42:57 +0200
Subject: [PATCH 03/67] Removed information already given in base classes
---
contributed_definitions/nyaml/NXmpes_xps.yaml | 358 +++---------------
1 file changed, 43 insertions(+), 315 deletions(-)
diff --git a/contributed_definitions/nyaml/NXmpes_xps.yaml b/contributed_definitions/nyaml/NXmpes_xps.yaml
index e0d17ff779..e256f273f0 100644
--- a/contributed_definitions/nyaml/NXmpes_xps.yaml
+++ b/contributed_definitions/nyaml/NXmpes_xps.yaml
@@ -7,47 +7,32 @@ NXmpes_xps(NXmpes):
(NXentry):
end_time(NX_DATE_TIME):
exists: recommended
- doc: "Datetime of the end of the measurement."
definition(NX_CHAR):
- \@version(NX_CHAR):
enumeration: ["NXmpes_xps"]
- # (NXuser): #### nothing changed, can be removed from here?
- # doc: "Contact information of at least the user of the instrument or the
- # investigator who performed this experiment.
- # Adding multiple users if relevant is recommended."
- # name(NX_CHAR):
- # exists: recommended
- # doc: "Name of the user."
- # affiliation(NX_CHAR):
- # exists: recommended
- # doc: "Name of the affiliation of the user at the point in time when the
- # experiment was performed."
- # address(NX_CHAR):
- # exists: recommended
- # doc: "Full address (street, street number, ZIP, city, country) of the
- # user's affiliation."
- # email(NX_CHAR):
- # doc: "Email address of the user."
- # orcid(NX_CHAR):
- # exists: recommended
- # doc: "Author ID defined by https://orcid.org/."
(NXinstrument):
energy_resolution(NX_FLOAT):
exists: recommended ###### cannot be required. measured value (typically from Ag 3d5/2 FWHM of sputter-cleaned Ag foil), not known every time and cann update over time (detector degradation).
unit: NX_ENERGY
- manufacturer(NX_CHAR):
+ manufacturer(NXfabrication): #### should go to NXmpes at some point.
exists: recommended
- doc: "The name of the company that manufactured the spectrometer."
- enumeration: [
+ vendor:
+ exists: recommended
+ enumeration: [
"SPECS GmbH",
"Kratos",
"Physical Electronics",
"Scienta",
"Thermo Fischer Scientific",
]
+ model:
+ exists: recommended
+ work_function(NX_FLOAT):
+ exists: recommended ###### new
+ doc: "Work function of the spectrometer."
+ unit: NX_ENERGY
(NXsource):
type(NX_CHAR):
- enumeration: [ ### removed some options from NXmpes
+ enumeration: [
"Synchrotron X-ray Source",
"Rotating Anode X-ray",
"Fixed Tube X-ray",
@@ -59,75 +44,21 @@ NXmpes_xps(NXmpes):
probe(NX_CHAR):
doc: "Type of probe. In XPS it's always X-ray photons (or UV light in UPS), so the full NIAC list is restricted."
enumeration: ["x-ray", "ultraviolet"]
- (NXmonochromator):
- exists: optional
- applied(NX_BOOLEAN):
- doc: "Has the incident beam been monochromatized? "
- type(NX_CHAR):
- enumeration: [
- "Crystal",
- "Grating",
- ]
- crystal(NXcrystal):
- exists: optional
- doc: "For crystal based monochromators. Use as many crystals as necessary."
- grating(NXgrating):
- exists: optional
- doc: "For diffraction grating based monochromators. Use as many crystals as necessary."
- energy(NX_FLOAT):
- doc: "The scalar energy of the monchromatic beam. This should link to /entry/instrument/beam/incident_energy." ######how to do links?
- unit: NX_ENERGY
- energy_error(NX_FLOAT):
- doc: "The energy spread FWHM for the corresponding energy in energy. This should link to /entry/instrument/beam/incident_energy_spread."
- unit: NX_ENERGY
- transformations(NXtransformations) ###### should we describe the beam rotation by the mono?
- exists: optional
- (NXbeam):
- distance(NX_NUMBER):
- exists: recommended ### cannot be required, hard to know???
- doc: "Distance of the point of evaluation of the beam from the sample surface."
- unit: NX_LENGTH
- incident_energy(NX_FLOAT):
- unit: NX_ENERGY
- doc: "In the case of a monchromatic beam this is the scalar energy. Several other use cases are permitted, depending on the presence of other incident_energy_X fields. In the case of a polychromatic beam this is an array of length m of energies, with the relative weights in incident_energy_weights. In the case of a monochromatic beam that varies shot-to-shot, this is an array of energies, one for each recorded shot. Here, incident_energy_weights and incident_energy_spread are not set. In the case of a polychromatic beam that varies shot-to-shot, this is an array of length m with the relative weights in incident_energy_weights as a 2D array. In the case of a polychromatic beam that varies shot-to-shot and where the channels also vary, this is a 2D array of dimensions nP by m (slow to fast) with the relative weights in incident_energy_weights as a 2D array. Note, variants are a good way to represent several of these use cases in a single dataset, e.g. if a calibrated, single-value energy value is available along with the original spectrum from which it was calibrated."
- incident_energy_spread(NX_NUMBER):
- exists: recommended
- unit: NX_ENERGY
- doc: "The energy spread FWHM for the corresponding energy(ies) in incident_energy. In the case of shot-to-shot variation in the energy spread, this is a 2D array of dimension nP by m (slow to fast) of the spreads of the corresponding energy in incident_energy."
- #incident_polarization(NX_NUMBER):
- # exists: recommended
- # doc: "Incident polarization specified as a Stokes vector."
- # \@units(NX_CHAR):
- # doc: "The units for this observable are not included in the NIAC list. Responsibility on correct formatting and parsing is handed to the user by using ‘NX_ANY’. Correct parsing can still be implemented by using this attribute. Fill with: The unit unidata symbol if the unit has one (Example: ‘T’ for the unit of magnetic flux density tesla). The unit unidata name if the unit has a name (Example: ‘farad’ for capacitance). A string describing the units according to unidata unit operation notation, if the unit is a complex combination of named units and does not have a name. Example: for lightsource brilliance (SI) ‘1/(s.mm2.mrad2)’. Here: SI units are ‘V2/m2’."
(NXelectronanalyser):
- description(NX_CHAR):
- doc: "Free text description of the type of detector."
- # fast_axes(NX_CHAR): ### how to use these?
- # exists: optional
- # doc: "List of the axes that are acquired symultaneously by the detector. These refer only to the experimental variables recorded by the electron analyser. Other variables such as temperature, manipulator angles etc. are labeled as fast or slow in the data. Hemispherical in XPS mode: fast_axes: [energy] Hemispherical with channeltron, sweeping energy mode: slow_axes: [energy] axes can be less abstract than this, i.e. [detector_x, detector_y]."
- # slow_axes(NX_CHAR):
- # exists: optional
- # doc: "List of the axes that are acquired by scanning a physical parameter, listed in order of decreasing speed. See fast_axes for examples."
(NXcollectioncolumn):
scheme(NX_CHAR):
- doc: "Scheme of the electron collection column."
- enumeration: [ ### removed some options from NXmpes
+ enumeration: [ ### removed some options from NXmpes
"Standard",
"Angular dispersive",
"Selective area",
"Deflector",
]
- mode(NX_CHAR):
- exists: recommended
- doc: "Labelling of the lens setting in use. Names are typically presets provided by the instrument vendor."
- # projection(NX_CHAR): #### what does this mean?
- # exists: recommended
- tranmission_function(NX_FLOAT):
+ transmission_function(NX_FLOAT):
exists: recommended
doc: "Transmission function in dependance of the electron kinetic energy. To be used in intensity calibration." ### does NX_FLOAT make sense?
(NXenergydispersion):
scheme(NX_CHAR):
- enumeration: ### removed some options from NXmpes
+ enumeration: ### removed some options from NXmpes
[
"hemispherical",
"double hemispherical",
@@ -135,12 +66,9 @@ NXmpes_xps(NXmpes):
"display mirror",
"retarding grid",
]
- pass_energy(NX_FLOAT):
- doc: "Pass energy of energy dispersive element. Determines measurement resolution."
- unit: NX_ENERGY
energy_scan_mode(NX_CHAR):
doc: "Way of scanning the energy axis."
- enumeration: [ ### could potentially add some more here.
+ enumeration: [ ### could potentially add some more here.
"fixed analyzer transmission",
"fixed retarding ratio",
"fixed energies",
@@ -150,220 +78,51 @@ NXmpes_xps(NXmpes):
"constant final state",
"constant initial state",
]
- # entrance_slit(NXaperture): ### is this level of description necessary -> most items exist in NXaperture already
- # exists: optional
- # doc: "Size, position, and shape of the entrance slit in dispersive analyzers (aperture generating the energy filtering)."
- # description(NX_CHAR):
- # exists: optional
- # doc: "Type of aperture inserted in the beam."
- # enumeration: ["slit", "pinhole", "iris"]
- # shape(NX_CHAR):
- # exists: optional
- # doc: "Description of the shape of the active part of the aperture, curved or straight for horizontal slits, square or round for pinhole etc."
- # enumeration:
- # [
- # "straight slit",
- # "curved slit",
- # "pinhole",
- # "circle",
- # "square",
- # "hexagon",
- # "octagon",
- # "bladed",
- # "open",
- # "grid"
- # ]
- # size(NX_NUMBER):
- # exists: optional
- # doc: "The relevant dimension for the entrance_slit, i.e. slit width, pinhole and iris diameter."
- # exit_slit(NXaperture):
- # exists: optional
- # doc: "Size, position and shape of the exit slit in dispersive analyzers."
- # description(NX_CHAR):
- # exists: optional
- # doc: "Type of aperture inserted in the beam."
- # enumeration: ["slit", "pinhole", "iris"]
- # shape(NX_CHAR):
- # exists: optional
- # doc: "Description of the shape of the active part of the aperture, curved or straight for horizontal slits, square or round for pinhole etc."
- # enumeration:
- # [
- # "straight slit",
- # "curved slit",
- # "pinhole",
- # "circle",
- # "square",
- # "hexagon",
- # "octagon",
- # "bladed",
- # "open",
- # "grid"
- # ]
- # size(NX_NUMBER):
- # exists: optional
- # doc: "The relevant dimension for the entrance_slit, i.e. slit width, pinhole and iris diameter."
- # iris(NXaperture):
- # exists: optional
- # doc: "Size, position, and shape of the iris in dispersive analyzers."
- # description(NX_CHAR):
- # exists: optional
- # doc: "Type of aperture inserted in the beam."
- # enumeration: ["slit", "pinhole", "iris"]
- # shape(NX_CHAR):
- # exists: optional
- # doc: "Description of the shape of the active part of the aperture, curved or straight for horizontal slits, square or round for pinhole etc."
- # enumeration:
- # [
- # "straight slit",
- # "curved slit",
- # "pinhole",
- # "circle",
- # "square",
- # "hexagon",
- # "octagon",
- # "bladed",
- # "open",
- # "grid"
- # ]
- # size(NX_NUMBER):
- # exists: optional
- # doc: "The relevant dimension for the entrance_slit, i.e. slit width, pinhole and iris diameter."
+ iris(NXaperture):
+ exists: optional
analyzer_radius(NX_FLOAT):
exists: optional
description: The radius of the hemispherical analyzer in mm (only if hemispherical analyzer is used.)
- (NXdetector):
- # amplifier:type(NX_CHAR):
- # exists: recommended
- # doc: "Description of the detector type."
- # enumeration:
- # ["MCP", "channeltron"]
- # detector_type(NX_CHAR):
- # exists: recommended
- # doc: "Description of the detector type."
- # enumeration:
- # [
- # "DLD",
- # "Phosphor+CCD",
- # "Phosphor+CMOS",
- # "ECMOS",
- # "Anode",
- # "Multi-anode"
- # ]
- # (NXdata): # Raw signal without calibrated axes.
- # exists: recommended
- # \@signal:
- # enumeration: ['raw']
- # raw(NX_NUMBER): # There is a block of numbers named raw.
- # doc: "Raw data before calibration."
- GEOMETRY(NXtransformations): ### took this from NXmpes_liqudidjet, how to describe geometry? on indicidual classes? would like to describe angles between different instrument parts here?
- exists: optional
- doc: "Transformations describing the transformation chain of all relevant vectors in the experiment."
- gravity_axis(NX_NUMBER):
- doc: "Direction of gravity."
- \@vector(NX_NUMBER):
- doc: "The vector in the direction of gravity."
- \@depends_on(NX_CHAR):
- doc: "Set to '.' to specify the normal vector to which all other vectors are related."
- beam_axis(NX_NUMBER):
- doc: "Direction of the photon beam."
- \@vector(NX_NUMBER):
- doc: "The vector of the photon-beam direction into the chamber after the last optical element (or directly from the source if there are no optical elements)."
- \@depends_on(NX_CHAR):
- doc: "This should be a link to /entry/instrument/geometry/gravity_axis."
- analyzer_lens_axis(NX_NUMBER):
- doc: "Direction of lens axis of analyzer."
- \@vector(NX_NUMBER):
- doc: "The vector pointing along the central axis of the analyzer lens system in from the sample."
- \@depends_on(NX_CHAR):
- doc: "This should be a link to /entry/instrument/geometry/beam_axis."
- hemisphere_orientation(NX_NUMBER):
- exists: optional
- doc: "Orientation of the hemisphere with respect to the lens system in case of a hemispherical electron analyzer."
- \@vector(NX_NUMBER):
- doc: "The vector pointing towards the detector from the entrance slit of the hemisphere, and should be perpendicular to the analyzer lens system."
- \@depends_on(NX_CHAR):
- doc: "This should be a link to /entry/instrument/geometry/analyzer_lens_axis."
+ unit: NX_LENGTH
(NXmanipulator):
- # exists: optional
- # doc: "Manipulator for positioning of the sample."
- # sample_temperature(NX_FLOAT):
- # exists: recommended
- # doc: "Sample temperature during the experiment. Can be a single float or an array for temperature-programmed XPS."
- # unit: NX_TEMPERATURE
- sample_heater(NX_CHAR):
+ heater_type(NX_CHAR):
exists: optional
- doc: "Method of heating the sample. Can be e.g. electron beam heating, laser, halogen lamp"
- # heater_power(NX_FLOAT):
- # exists: optional
- # doc: "Power in the heater for temperature control."
- # sample_temperature(NX_FLOAT):
- # exists: optional
- # doc: "Temperature at the closest point to the sample. This field may also be found in NXsample if present."
- # drain_current(NX_FLOAT):
- # exists: recommended
- # doc: "Measured drain current of the sample. This field may also be found in NXsample if present."
- # unit: NX_CURRENT
- # sample_bias(NX_FLOAT):
- # exists: recommended
- # doc: "Possible bias of the sample with respect to analyser ground. This field may also be found in NXsample if present."
- # unit: NX_CURRENT
+ doc: "Method of heating the sample. Can be e.g. electron beam heating, laser, halogen lamp."
+ enumeration: [ ### could potentially add some more here.
+ "electron beam heating",
+ "laser",
+ "halogen lamp",
+ ]
(NXprocess):
- # doc: "Document an event of data processing, reconstruction, or analysis for this data.
- # Describe the appropriate axis calibrations for your experiment using
- # one or more of the following NXcalibrations."
energy_calibration(NXcalibration):
- # exists: recommended
- # applied(NX_BOOLEAN):
- # doc: "Has an energy calibration been applied?"
- calibration_file(NX_CHAR):
- exists: recommended
- doc: "Name of the calibration file containing the calibration data."
- # calibrated_axis(NX_FLOAT):
- # exists: recommended
- # doc: "This is the calibrated energy axis to be used for data plotting."
- # spatial_calibration(NXcalibration):
- # exists: optional
- # applied(NX_BOOLEAN):
- # doc: "Has a spatial calibration been applied?"
- # calibrated_axis(NX_FLOAT):
- # exists: recommended
- # doc: "This is the calibrated spatial axis to be used for data plotting."
+ exists: optional
+ calibration_file(NXnote):
+ exists: optional
+ doc: "Name of the calibration file containing the calibration data."
intensity_calibration(NXcalibration):
- exists: recommended
+ exists: optional
applied(NX_BOOLEAN):
doc: "Has an intensity calibration been applied? That is, has the transmission function of the analyzer been taken into account?"
transmission_function(NX_FLOAT):
exists: recommended
doc: "Transmission function of the electron collection column. This should be a link to /entry/instrument/collectioncolumn/tranmission_function."
energy_reference(NXcalibration):
- exists: recommended
+ exists: optional
applied(NX_BOOLEAN):
doc: "Have the energy axes been adjusted (e.g., in cases where samples are not conductive)?"
emission_line(NX_CHAR):
exists: recommended
doc: "Emission line which was used for the calibration."
- offset(NXfloat):
+ offset(NX_FLOAT):
exists: recommended
doc: "Offset between measured binding energy and calibrated binding energy of the emission line."
- binding_energy(NX_float):
+ binding_energy(NX_FLOAT):
exists: recommended
doc: "The binding energy that the specified emission line appeared at, after adjusting the binding energy scale, in units of eV"
calibrated_axis(NX_FLOAT):
exists: recommended
doc: "This is the calibrated energy axis to be used for data plotting. This should be a link to /entry/data/energy." ######????
- (NXsample):
- name(NX_CHAR):
- doc: "The user-assigned name of the sample."
- description(NX_CHAR):
- exists: optional
- doc: "Full description of the sample."
- # chemical_formula:
- # exists: recommended
- # doc: "The chemical formula of the sample. For mixtures use the NXsample_component group in NXsample instead."
- # atom_types:
- # exists: recommended
- # doc: "List of comma-separated elements from the periodic table that are contained in the sample.
- # If the sample substance has multiple components, all elements from each component must be included in `atom_types`."
+ (NXsample):
form(NX_CHAR):
exists: optional
enumeration:
@@ -372,59 +131,28 @@ NXmpes_xps(NXmpes):
"single crystal",
"pellet",
"powder",
- "calibration sample",
]
- # preparation_date(NX_DATE_TIME):
- # exists: recommended
- # doc: "Date of preparation of the sample for the XPS experiment (i.e. cleaving, last annealing)."
- # temperature(NX_FLOAT):
- # doc: "In the case of a fixed temperature measurement this is the scalar temperature of the sample. In the case of an experiment in which the temperature is changed and recoded, this is an array of length m of temperatures. This should be a link to /entry/instrument/manipulator/sample_temperature."
- # unit: NX_TEMPERATURE
- situation(NX_CHAR): ### missing some enumerations here
- enumeration:
- [
- "vacuum",
- "inert atmosphere",
- "oxidising atmosphere",
- "reducing atmosphere",
- "other"
- ]
gas_pressure(NX_FLOAT): ######## Can be a single number or a log.
unit: NX_PRESSURE
doc: "In the case of a fixed pressure measurement this is the scalar pressure. In the case of an experiment in which pressure changes, or anyway it is recorded, this is an array of length m of pressures."
- # sample_history(NXnote):
- # exists: recommended
- # doc: "A descriptor to keep track of the treatment of the sample before entering the photoemission experiment. Ideally, a full report of the previous operations, in any format (NXnote allows to add pictures, audio, movies). Alternatively, a reference to the location or a unique identifier or other metadata file. In the case these are not available, free-text description."
- # preparation_description(NXnote):
- # doc: "Description of the surface preparation technique for the XPS experiment, i.e. UHV cleaving, in-situ growth, sputtering/annealing etc. Ideally, a full report of the previous operations, in any format(NXnote allows to add pictures, audio, movies). Alternatively, a reference to the location or a unique identifier or other metadata file. In the case these are not available, free-text description."
gas_phase(NX_CHAR):
exists: optional
- doc: "Description of the constitutent gases of the gas phase."
- electric_field(NX_FLOAT):
- exists: optional
- unit: NX_VOLTAGE
- doc: "Electric field applied to the sample with respect to ground / the system, e.g., via biasing."
+ doc: "Description of the constituent gases of the gas phase."
(NXdata):
- # \@signal:
- # enumeration: ["data"]
\@axes(NX_CHAR):
- doc: "The energy axis. Can be either scanned or derived from scanning of other energy axis."
- energy(NX_NUMBER): #### how to represent this here?
- \@units(NX_CHAR):
- exists: recommended
- \@long_name(NX_CHAR):
- exists: optional
- type(NX_CHAR):
+ doc: "It should contain at least one axis called 'energy'."
+ energy(NX_NUMBER): #### how to represent this here?
+ \@type(NX_CHAR):
exists: recommended
- doc: "The energy axis can be either in binding or kinetic energy."
+ doc: "The calibrated energy axis can be either in binding or kinetic energy. "
enumeration:
[
"kinetic",
- "energy"
- ]
- step_size(NX_CHAR):
+ "binding"
+ ]
+ \@step_size(NX_FLOAT):
exists: optional
- doc: "The step size between two consecutive energy values."
+ doc: "The step size between two consecutive energy values if the energy axis is evenly spaced."
data(NX_NUMBER): # There is a block of numbers named data.
doc: "Processed plottable data. Represents a measure of one- or more-dimensional photoemission counts, where
the varied axis may be for example energy, spatial coordinate, pump-probe delay, temperature, etc.
From d2d22f8fc31f33fb3dac6f579ad19eb41c43a416 Mon Sep 17 00:00:00 2001
From: Lukas Pielsticker <50139597+lukaspie@users.noreply.github.com>
Date: Fri, 5 May 2023 09:27:34 +0200
Subject: [PATCH 04/67] Removed some unneeded comments
---
contributed_definitions/nyaml/NXmpes_xps.yaml | 26 ++++++++++---------
1 file changed, 14 insertions(+), 12 deletions(-)
diff --git a/contributed_definitions/nyaml/NXmpes_xps.yaml b/contributed_definitions/nyaml/NXmpes_xps.yaml
index e256f273f0..2852868e97 100644
--- a/contributed_definitions/nyaml/NXmpes_xps.yaml
+++ b/contributed_definitions/nyaml/NXmpes_xps.yaml
@@ -11,9 +11,9 @@ NXmpes_xps(NXmpes):
enumeration: ["NXmpes_xps"]
(NXinstrument):
energy_resolution(NX_FLOAT):
- exists: recommended ###### cannot be required. measured value (typically from Ag 3d5/2 FWHM of sputter-cleaned Ag foil), not known every time and cann update over time (detector degradation).
+ exists: recommended # cannot be required. measured value (typically from Ag 3d5/2 FWHM of sputter-cleaned Ag foil), not known every time and cann update over time (detector degradation).
unit: NX_ENERGY
- manufacturer(NXfabrication): #### should go to NXmpes at some point.
+ manufacturer(NXfabrication): # Should go to NXmpes at some point.
exists: recommended
vendor:
exists: recommended
@@ -27,7 +27,7 @@ NXmpes_xps(NXmpes):
model:
exists: recommended
work_function(NX_FLOAT):
- exists: recommended ###### new
+ exists: recommended
doc: "Work function of the spectrometer."
unit: NX_ENERGY
(NXsource):
@@ -47,7 +47,7 @@ NXmpes_xps(NXmpes):
(NXelectronanalyser):
(NXcollectioncolumn):
scheme(NX_CHAR):
- enumeration: [ ### removed some options from NXmpes
+ enumeration: [
"Standard",
"Angular dispersive",
"Selective area",
@@ -55,10 +55,10 @@ NXmpes_xps(NXmpes):
]
transmission_function(NX_FLOAT):
exists: recommended
- doc: "Transmission function in dependance of the electron kinetic energy. To be used in intensity calibration." ### does NX_FLOAT make sense?
+ doc: "Transmission function in dependance of the electron kinetic energy. To be used in intensity calibration."
(NXenergydispersion):
scheme(NX_CHAR):
- enumeration: ### removed some options from NXmpes
+ enumeration:
[
"hemispherical",
"double hemispherical",
@@ -68,7 +68,8 @@ NXmpes_xps(NXmpes):
]
energy_scan_mode(NX_CHAR):
doc: "Way of scanning the energy axis."
- enumeration: [ ### could potentially add some more here.
+ # Could potentially add some more options here.
+ enumeration: [
"fixed analyzer transmission",
"fixed retarding ratio",
"fixed energies",
@@ -88,7 +89,8 @@ NXmpes_xps(NXmpes):
heater_type(NX_CHAR):
exists: optional
doc: "Method of heating the sample. Can be e.g. electron beam heating, laser, halogen lamp."
- enumeration: [ ### could potentially add some more here.
+ # Could potentially add some more options here.
+ enumeration: [
"electron beam heating",
"laser",
"halogen lamp",
@@ -121,7 +123,7 @@ NXmpes_xps(NXmpes):
doc: "The binding energy that the specified emission line appeared at, after adjusting the binding energy scale, in units of eV"
calibrated_axis(NX_FLOAT):
exists: recommended
- doc: "This is the calibrated energy axis to be used for data plotting. This should be a link to /entry/data/energy." ######????
+ doc: "This is the calibrated energy axis to be used for data plotting. This should be a link to /entry/data/energy."
(NXsample):
form(NX_CHAR):
exists: optional
@@ -132,7 +134,7 @@ NXmpes_xps(NXmpes):
"pellet",
"powder",
]
- gas_pressure(NX_FLOAT): ######## Can be a single number or a log.
+ gas_pressure(NX_FLOAT):
unit: NX_PRESSURE
doc: "In the case of a fixed pressure measurement this is the scalar pressure. In the case of an experiment in which pressure changes, or anyway it is recorded, this is an array of length m of pressures."
gas_phase(NX_CHAR):
@@ -141,7 +143,7 @@ NXmpes_xps(NXmpes):
(NXdata):
\@axes(NX_CHAR):
doc: "It should contain at least one axis called 'energy'."
- energy(NX_NUMBER): #### how to represent this here?
+ energy(NX_NUMBER):
\@type(NX_CHAR):
exists: recommended
doc: "The calibrated energy axis can be either in binding or kinetic energy. "
@@ -153,7 +155,7 @@ NXmpes_xps(NXmpes):
\@step_size(NX_FLOAT):
exists: optional
doc: "The step size between two consecutive energy values if the energy axis is evenly spaced."
- data(NX_NUMBER): # There is a block of numbers named data.
+ data(NX_NUMBER):
doc: "Processed plottable data. Represents a measure of one- or more-dimensional photoemission counts, where
the varied axis may be for example energy, spatial coordinate, pump-probe delay, temperature, etc.
The axes traces should be linked to the actual encoder position in NXinstrument or calibrated axes in NXprocess."
From 33492b83e602c04bf3778707b0e9997e1fad2910 Mon Sep 17 00:00:00 2001
From: Lukas Pielsticker <50139597+lukaspie@users.noreply.github.com>
Date: Fri, 5 May 2023 11:33:40 +0200
Subject: [PATCH 05/67] Add description of instrument orientation
- Angle between beam and sample normal-> needed for determination of probing depth
- Angle between beam and analyzer axes -> needed for data analysis
---
contributed_definitions/nyaml/NXmpes_xps.yaml | 11 ++++++++++-
1 file changed, 10 insertions(+), 1 deletion(-)
diff --git a/contributed_definitions/nyaml/NXmpes_xps.yaml b/contributed_definitions/nyaml/NXmpes_xps.yaml
index 2852868e97..dee2ac6f0e 100644
--- a/contributed_definitions/nyaml/NXmpes_xps.yaml
+++ b/contributed_definitions/nyaml/NXmpes_xps.yaml
@@ -30,6 +30,15 @@ NXmpes_xps(NXmpes):
exists: recommended
doc: "Work function of the spectrometer."
unit: NX_ENERGY
+ # These angles could also be described by NXtransformations on the analyzer and beam.
+ angle_beam_sample(NX_NUMBER):
+ exists: recommended
+ doc: "Orientation of the beam with respect to the sample normal."
+ units: NX_ANGLE
+ angle_beam_analyser(NX_NUMBER):
+ exists: recommended
+ doc: "Orientation of the beam with respect to the central axis of the analyzer."
+ units: NX_ANGLE
(NXsource):
type(NX_CHAR):
enumeration: [
@@ -83,7 +92,7 @@ NXmpes_xps(NXmpes):
exists: optional
analyzer_radius(NX_FLOAT):
exists: optional
- description: The radius of the hemispherical analyzer in mm (only if hemispherical analyzer is used.)
+ description: "The radius of the hemispherical analyzer in mm (only if hemispherical analyzer is used."
unit: NX_LENGTH
(NXmanipulator):
heater_type(NX_CHAR):
From b1e10392dd4d7c8e4cf1bf9ce8397c8f0778ab0a Mon Sep 17 00:00:00 2001
From: Lukas Pielsticker <50139597+lukaspie@users.noreply.github.com>
Date: Tue, 9 May 2023 14:20:10 +0200
Subject: [PATCH 06/67] Move orientation of instrument parts
Instead of having two fields on the instrument for the angle between beam and sample and the angle between beam and analyser, this information is stored in depends_on and NXtransformations in NXinstrument and NXsample, respectively.
---
contributed_definitions/nyaml/NXmpes_xps.yaml | 23 +++++++++++--------
1 file changed, 13 insertions(+), 10 deletions(-)
diff --git a/contributed_definitions/nyaml/NXmpes_xps.yaml b/contributed_definitions/nyaml/NXmpes_xps.yaml
index dee2ac6f0e..df68169d40 100644
--- a/contributed_definitions/nyaml/NXmpes_xps.yaml
+++ b/contributed_definitions/nyaml/NXmpes_xps.yaml
@@ -30,15 +30,6 @@ NXmpes_xps(NXmpes):
exists: recommended
doc: "Work function of the spectrometer."
unit: NX_ENERGY
- # These angles could also be described by NXtransformations on the analyzer and beam.
- angle_beam_sample(NX_NUMBER):
- exists: recommended
- doc: "Orientation of the beam with respect to the sample normal."
- units: NX_ANGLE
- angle_beam_analyser(NX_NUMBER):
- exists: recommended
- doc: "Orientation of the beam with respect to the central axis of the analyzer."
- units: NX_ANGLE
(NXsource):
type(NX_CHAR):
enumeration: [
@@ -104,6 +95,12 @@ NXmpes_xps(NXmpes):
"laser",
"halogen lamp",
]
+ depends_on(NX_CHAR):
+ exists: recommended
+ doc: "Reference to the transformation describing the orientation of the analyzer relative to the beam."
+ (NXtransformations):
+ exists: recommended
+ doc: "Set of transformations, describing the relative orientation of the analyzer with respect to the beam coordinate system."
(NXprocess):
energy_calibration(NXcalibration):
exists: optional
@@ -148,7 +145,13 @@ NXmpes_xps(NXmpes):
doc: "In the case of a fixed pressure measurement this is the scalar pressure. In the case of an experiment in which pressure changes, or anyway it is recorded, this is an array of length m of pressures."
gas_phase(NX_CHAR):
exists: optional
- doc: "Description of the constituent gases of the gas phase."
+ doc: "Description of the constituent gases of the gas phase."
+ depends_on(NX_CHAR):
+ exists: recommended
+ doc: "Reference to a transformation describing the orientation of the sample relative to the beam coordinate system."
+ (NXtransformations):
+ exists: recommended
+ doc: "Set of transformations, describing the relative orientation of the sample with respect to the beam coordinate system."
(NXdata):
\@axes(NX_CHAR):
doc: "It should contain at least one axis called 'energy'."
From 53fca26bc31d65e1aa75cf423d3940f18cfc4fd8 Mon Sep 17 00:00:00 2001
From: Lukas Pielsticker <50139597+lukaspie@users.noreply.github.com>
Date: Tue, 9 May 2023 14:24:20 +0200
Subject: [PATCH 07/67] Update transmission function information
- The transmission function contains an additional NXnote field "file" describing the file in which the TF data is stored.
---
contributed_definitions/nyaml/NXmpes_xps.yaml | 15 +++++++++++++--
1 file changed, 13 insertions(+), 2 deletions(-)
diff --git a/contributed_definitions/nyaml/NXmpes_xps.yaml b/contributed_definitions/nyaml/NXmpes_xps.yaml
index df68169d40..4957dc868a 100644
--- a/contributed_definitions/nyaml/NXmpes_xps.yaml
+++ b/contributed_definitions/nyaml/NXmpes_xps.yaml
@@ -55,7 +55,13 @@ NXmpes_xps(NXmpes):
]
transmission_function(NX_FLOAT):
exists: recommended
- doc: "Transmission function in dependance of the electron kinetic energy. To be used in intensity calibration."
+ doc: "Transmission function of the electron collection column.
+ This should be a link to /entry/process/intensity_calibration/tranmission_function."
+ units: NX_ANY
+ file(NXnote):
+ exists: recommended
+ doc: "File containing the transmission function data of the electron collection column.
+ This should be a link to /entry/instrument/collectioncolumn/transmission_function/file."
(NXenergydispersion):
scheme(NX_CHAR):
enumeration:
@@ -113,7 +119,12 @@ NXmpes_xps(NXmpes):
doc: "Has an intensity calibration been applied? That is, has the transmission function of the analyzer been taken into account?"
transmission_function(NX_FLOAT):
exists: recommended
- doc: "Transmission function of the electron collection column. This should be a link to /entry/instrument/collectioncolumn/tranmission_function."
+ doc: "Transmission function of the electron collection column.
+ This should be a link to /entry/instrument/collectioncolumn/transmission_function."
+ units: NX_ANY
+ file(NXnote):
+ exists: recommended
+ doc: "File containing the transmission function data.
energy_reference(NXcalibration):
exists: optional
applied(NX_BOOLEAN):
From 75a71e4259085639989dad5b5856236dfb4d9f28 Mon Sep 17 00:00:00 2001
From: Lukas Pielsticker <50139597+lukaspie@users.noreply.github.com>
Date: Tue, 9 May 2023 14:32:44 +0200
Subject: [PATCH 08/67] Update documentation, add comments for discussion
---
contributed_definitions/nyaml/NXmpes_xps.yaml | 44 ++++++++++---------
1 file changed, 24 insertions(+), 20 deletions(-)
diff --git a/contributed_definitions/nyaml/NXmpes_xps.yaml b/contributed_definitions/nyaml/NXmpes_xps.yaml
index 4957dc868a..78d5466861 100644
--- a/contributed_definitions/nyaml/NXmpes_xps.yaml
+++ b/contributed_definitions/nyaml/NXmpes_xps.yaml
@@ -60,7 +60,7 @@ NXmpes_xps(NXmpes):
units: NX_ANY
file(NXnote):
exists: recommended
- doc: "File containing the transmission function data of the electron collection column.
+ doc: "Name of the file containing the transmission function data of the electron collection column.
This should be a link to /entry/instrument/collectioncolumn/transmission_function/file."
(NXenergydispersion):
scheme(NX_CHAR):
@@ -84,18 +84,19 @@ NXmpes_xps(NXmpes):
"detector voltage scan",
"constant final state",
"constant initial state",
- ]
+ ]
+ # Not strictly neccessary to have.
iris(NXaperture):
exists: optional
analyzer_radius(NX_FLOAT):
exists: optional
- description: "The radius of the hemispherical analyzer in mm (only if hemispherical analyzer is used."
+ description: "The radius of the hemispherical analyzer in mm (only if hemispherical analyzer is used)."
unit: NX_LENGTH
(NXmanipulator):
heater_type(NX_CHAR):
exists: optional
doc: "Method of heating the sample. Can be e.g. electron beam heating, laser, halogen lamp."
- # Could potentially add some more options here.
+ # Could add some more options here.
enumeration: [
"electron beam heating",
"laser",
@@ -116,7 +117,8 @@ NXmpes_xps(NXmpes):
intensity_calibration(NXcalibration):
exists: optional
applied(NX_BOOLEAN):
- doc: "Has an intensity calibration been applied? That is, has the transmission function of the analyzer been taken into account?"
+ doc: "Has an intensity calibration been applied?
+ That is, has the transmission function of the analyzer been taken into account?"
transmission_function(NX_FLOAT):
exists: recommended
doc: "Transmission function of the electron collection column.
@@ -124,7 +126,7 @@ NXmpes_xps(NXmpes):
units: NX_ANY
file(NXnote):
exists: recommended
- doc: "File containing the transmission function data.
+ doc: "Name of the file containing the transmission function data."
energy_reference(NXcalibration):
exists: optional
applied(NX_BOOLEAN):
@@ -137,14 +139,17 @@ NXmpes_xps(NXmpes):
doc: "Offset between measured binding energy and calibrated binding energy of the emission line."
binding_energy(NX_FLOAT):
exists: recommended
- doc: "The binding energy that the specified emission line appeared at, after adjusting the binding energy scale, in units of eV"
+ doc: "The binding energy that the specified emission line appeared at,
+ after adjusting the binding energy scale, in units of eV"
calibrated_axis(NX_FLOAT):
exists: recommended
- doc: "This is the calibrated energy axis to be used for data plotting. This should be a link to /entry/data/energy."
+ doc: "This is the calibrated energy axis to be used for data plotting.
+ This should be a link to /entry/data/energy."
(NXsample):
form(NX_CHAR):
exists: optional
enumeration:
+ # There should be more options here.
[
"foil",
"single crystal",
@@ -153,7 +158,10 @@ NXmpes_xps(NXmpes):
]
gas_pressure(NX_FLOAT):
unit: NX_PRESSURE
- doc: "In the case of a fixed pressure measurement this is the scalar pressure. In the case of an experiment in which pressure changes, or anyway it is recorded, this is an array of length m of pressures."
+ doc: |
+ In the case of a fixed pressure measurement this is the scalar pressure.
+ In the case of an experiment in which pressure changes, or anyway it is recorded,
+ this is an array of length m of pressures.
gas_phase(NX_CHAR):
exists: optional
doc: "Description of the constituent gases of the gas phase."
@@ -165,11 +173,15 @@ NXmpes_xps(NXmpes):
doc: "Set of transformations, describing the relative orientation of the sample with respect to the beam coordinate system."
(NXdata):
\@axes(NX_CHAR):
- doc: "It should contain at least one axis called 'energy'."
+ doc: "The data should contain at least one axis called 'energy'."
energy(NX_NUMBER):
+ doc: |
+ The calibrated energy axis can be either in binding or kinetic energy.
+ This should be a link to either
+ /entry/process/energy calibration/calibrated_axis or
+ /entry/process/energy_reference/calibrated_axis.
\@type(NX_CHAR):
exists: recommended
- doc: "The calibrated energy axis can be either in binding or kinetic energy. "
enumeration:
[
"kinetic",
@@ -177,12 +189,4 @@ NXmpes_xps(NXmpes):
]
\@step_size(NX_FLOAT):
exists: optional
- doc: "The step size between two consecutive energy values if the energy axis is evenly spaced."
- data(NX_NUMBER):
- doc: "Processed plottable data. Represents a measure of one- or more-dimensional photoemission counts, where
- the varied axis may be for example energy, spatial coordinate, pump-probe delay, temperature, etc.
- The axes traces should be linked to the actual encoder position in NXinstrument or calibrated axes in NXprocess."
- \@units(NX_ANY):
- exists: recommended
- \@long_name(NX_CHAR):
- exists: optional
\ No newline at end of file
+ doc: "The step size between two consecutive energy values if the energy axis is evenly spaced."
\ No newline at end of file
From 11ff4da87a98ee8edf79588c5e0411cfe41293b2 Mon Sep 17 00:00:00 2001
From: Lukas Pielsticker <50139597+lukaspie@users.noreply.github.com>
Date: Tue, 25 Apr 2023 08:44:52 +0200
Subject: [PATCH 09/67] Initial draft of NXmpes_xps sub app-def
---
contributed_definitions/nyaml/NXmpes_xps.yaml | 192 ------------------
1 file changed, 192 deletions(-)
delete mode 100644 contributed_definitions/nyaml/NXmpes_xps.yaml
diff --git a/contributed_definitions/nyaml/NXmpes_xps.yaml b/contributed_definitions/nyaml/NXmpes_xps.yaml
deleted file mode 100644
index 78d5466861..0000000000
--- a/contributed_definitions/nyaml/NXmpes_xps.yaml
+++ /dev/null
@@ -1,192 +0,0 @@
-#lukas.pielsticker at cec.mpg.de, 04/2023
-#Draft version of a NeXus application definition for XPS.
-
-doc: This is the application definition for X-ray photoelectron spectroscopy.
-category: application
-NXmpes_xps(NXmpes):
- (NXentry):
- end_time(NX_DATE_TIME):
- exists: recommended
- definition(NX_CHAR):
- enumeration: ["NXmpes_xps"]
- (NXinstrument):
- energy_resolution(NX_FLOAT):
- exists: recommended # cannot be required. measured value (typically from Ag 3d5/2 FWHM of sputter-cleaned Ag foil), not known every time and cann update over time (detector degradation).
- unit: NX_ENERGY
- manufacturer(NXfabrication): # Should go to NXmpes at some point.
- exists: recommended
- vendor:
- exists: recommended
- enumeration: [
- "SPECS GmbH",
- "Kratos",
- "Physical Electronics",
- "Scienta",
- "Thermo Fischer Scientific",
- ]
- model:
- exists: recommended
- work_function(NX_FLOAT):
- exists: recommended
- doc: "Work function of the spectrometer."
- unit: NX_ENERGY
- (NXsource):
- type(NX_CHAR):
- enumeration: [
- "Synchrotron X-ray Source",
- "Rotating Anode X-ray",
- "Fixed Tube X-ray",
- "UV Laser",
- "Free-Electron Laser",
- "UV Plasma Source",
- "Metal Jet X-ray",
- ]
- probe(NX_CHAR):
- doc: "Type of probe. In XPS it's always X-ray photons (or UV light in UPS), so the full NIAC list is restricted."
- enumeration: ["x-ray", "ultraviolet"]
- (NXelectronanalyser):
- (NXcollectioncolumn):
- scheme(NX_CHAR):
- enumeration: [
- "Standard",
- "Angular dispersive",
- "Selective area",
- "Deflector",
- ]
- transmission_function(NX_FLOAT):
- exists: recommended
- doc: "Transmission function of the electron collection column.
- This should be a link to /entry/process/intensity_calibration/tranmission_function."
- units: NX_ANY
- file(NXnote):
- exists: recommended
- doc: "Name of the file containing the transmission function data of the electron collection column.
- This should be a link to /entry/instrument/collectioncolumn/transmission_function/file."
- (NXenergydispersion):
- scheme(NX_CHAR):
- enumeration:
- [
- "hemispherical",
- "double hemispherical",
- "cylindrical mirror",
- "display mirror",
- "retarding grid",
- ]
- energy_scan_mode(NX_CHAR):
- doc: "Way of scanning the energy axis."
- # Could potentially add some more options here.
- enumeration: [
- "fixed analyzer transmission",
- "fixed retarding ratio",
- "fixed energies",
- "snapshot",
- "imaging",
- "detector voltage scan",
- "constant final state",
- "constant initial state",
- ]
- # Not strictly neccessary to have.
- iris(NXaperture):
- exists: optional
- analyzer_radius(NX_FLOAT):
- exists: optional
- description: "The radius of the hemispherical analyzer in mm (only if hemispherical analyzer is used)."
- unit: NX_LENGTH
- (NXmanipulator):
- heater_type(NX_CHAR):
- exists: optional
- doc: "Method of heating the sample. Can be e.g. electron beam heating, laser, halogen lamp."
- # Could add some more options here.
- enumeration: [
- "electron beam heating",
- "laser",
- "halogen lamp",
- ]
- depends_on(NX_CHAR):
- exists: recommended
- doc: "Reference to the transformation describing the orientation of the analyzer relative to the beam."
- (NXtransformations):
- exists: recommended
- doc: "Set of transformations, describing the relative orientation of the analyzer with respect to the beam coordinate system."
- (NXprocess):
- energy_calibration(NXcalibration):
- exists: optional
- calibration_file(NXnote):
- exists: optional
- doc: "Name of the calibration file containing the calibration data."
- intensity_calibration(NXcalibration):
- exists: optional
- applied(NX_BOOLEAN):
- doc: "Has an intensity calibration been applied?
- That is, has the transmission function of the analyzer been taken into account?"
- transmission_function(NX_FLOAT):
- exists: recommended
- doc: "Transmission function of the electron collection column.
- This should be a link to /entry/instrument/collectioncolumn/transmission_function."
- units: NX_ANY
- file(NXnote):
- exists: recommended
- doc: "Name of the file containing the transmission function data."
- energy_reference(NXcalibration):
- exists: optional
- applied(NX_BOOLEAN):
- doc: "Have the energy axes been adjusted (e.g., in cases where samples are not conductive)?"
- emission_line(NX_CHAR):
- exists: recommended
- doc: "Emission line which was used for the calibration."
- offset(NX_FLOAT):
- exists: recommended
- doc: "Offset between measured binding energy and calibrated binding energy of the emission line."
- binding_energy(NX_FLOAT):
- exists: recommended
- doc: "The binding energy that the specified emission line appeared at,
- after adjusting the binding energy scale, in units of eV"
- calibrated_axis(NX_FLOAT):
- exists: recommended
- doc: "This is the calibrated energy axis to be used for data plotting.
- This should be a link to /entry/data/energy."
- (NXsample):
- form(NX_CHAR):
- exists: optional
- enumeration:
- # There should be more options here.
- [
- "foil",
- "single crystal",
- "pellet",
- "powder",
- ]
- gas_pressure(NX_FLOAT):
- unit: NX_PRESSURE
- doc: |
- In the case of a fixed pressure measurement this is the scalar pressure.
- In the case of an experiment in which pressure changes, or anyway it is recorded,
- this is an array of length m of pressures.
- gas_phase(NX_CHAR):
- exists: optional
- doc: "Description of the constituent gases of the gas phase."
- depends_on(NX_CHAR):
- exists: recommended
- doc: "Reference to a transformation describing the orientation of the sample relative to the beam coordinate system."
- (NXtransformations):
- exists: recommended
- doc: "Set of transformations, describing the relative orientation of the sample with respect to the beam coordinate system."
- (NXdata):
- \@axes(NX_CHAR):
- doc: "The data should contain at least one axis called 'energy'."
- energy(NX_NUMBER):
- doc: |
- The calibrated energy axis can be either in binding or kinetic energy.
- This should be a link to either
- /entry/process/energy calibration/calibrated_axis or
- /entry/process/energy_reference/calibrated_axis.
- \@type(NX_CHAR):
- exists: recommended
- enumeration:
- [
- "kinetic",
- "binding"
- ]
- \@step_size(NX_FLOAT):
- exists: optional
- doc: "The step size between two consecutive energy values if the energy axis is evenly spaced."
\ No newline at end of file
From 5cd71d7908ff8d3ae346428d506bdc904ac1257b Mon Sep 17 00:00:00 2001
From: Lukas Pielsticker <50139597+lukaspie@users.noreply.github.com>
Date: Thu, 4 May 2023 13:50:23 +0200
Subject: [PATCH 10/67] Prepare NXmpes_xps for extending NXmpes
---
contributed_definitions/nyaml/NXmpes_xps.yaml | 435 ++++++++++++++++++
1 file changed, 435 insertions(+)
create mode 100644 contributed_definitions/nyaml/NXmpes_xps.yaml
diff --git a/contributed_definitions/nyaml/NXmpes_xps.yaml b/contributed_definitions/nyaml/NXmpes_xps.yaml
new file mode 100644
index 0000000000..e0d17ff779
--- /dev/null
+++ b/contributed_definitions/nyaml/NXmpes_xps.yaml
@@ -0,0 +1,435 @@
+#lukas.pielsticker at cec.mpg.de, 04/2023
+#Draft version of a NeXus application definition for XPS.
+
+doc: This is the application definition for X-ray photoelectron spectroscopy.
+category: application
+NXmpes_xps(NXmpes):
+ (NXentry):
+ end_time(NX_DATE_TIME):
+ exists: recommended
+ doc: "Datetime of the end of the measurement."
+ definition(NX_CHAR):
+ \@version(NX_CHAR):
+ enumeration: ["NXmpes_xps"]
+ # (NXuser): #### nothing changed, can be removed from here?
+ # doc: "Contact information of at least the user of the instrument or the
+ # investigator who performed this experiment.
+ # Adding multiple users if relevant is recommended."
+ # name(NX_CHAR):
+ # exists: recommended
+ # doc: "Name of the user."
+ # affiliation(NX_CHAR):
+ # exists: recommended
+ # doc: "Name of the affiliation of the user at the point in time when the
+ # experiment was performed."
+ # address(NX_CHAR):
+ # exists: recommended
+ # doc: "Full address (street, street number, ZIP, city, country) of the
+ # user's affiliation."
+ # email(NX_CHAR):
+ # doc: "Email address of the user."
+ # orcid(NX_CHAR):
+ # exists: recommended
+ # doc: "Author ID defined by https://orcid.org/."
+ (NXinstrument):
+ energy_resolution(NX_FLOAT):
+ exists: recommended ###### cannot be required. measured value (typically from Ag 3d5/2 FWHM of sputter-cleaned Ag foil), not known every time and cann update over time (detector degradation).
+ unit: NX_ENERGY
+ manufacturer(NX_CHAR):
+ exists: recommended
+ doc: "The name of the company that manufactured the spectrometer."
+ enumeration: [
+ "SPECS GmbH",
+ "Kratos",
+ "Physical Electronics",
+ "Scienta",
+ "Thermo Fischer Scientific",
+ ]
+ (NXsource):
+ type(NX_CHAR):
+ enumeration: [ ### removed some options from NXmpes
+ "Synchrotron X-ray Source",
+ "Rotating Anode X-ray",
+ "Fixed Tube X-ray",
+ "UV Laser",
+ "Free-Electron Laser",
+ "UV Plasma Source",
+ "Metal Jet X-ray",
+ ]
+ probe(NX_CHAR):
+ doc: "Type of probe. In XPS it's always X-ray photons (or UV light in UPS), so the full NIAC list is restricted."
+ enumeration: ["x-ray", "ultraviolet"]
+ (NXmonochromator):
+ exists: optional
+ applied(NX_BOOLEAN):
+ doc: "Has the incident beam been monochromatized? "
+ type(NX_CHAR):
+ enumeration: [
+ "Crystal",
+ "Grating",
+ ]
+ crystal(NXcrystal):
+ exists: optional
+ doc: "For crystal based monochromators. Use as many crystals as necessary."
+ grating(NXgrating):
+ exists: optional
+ doc: "For diffraction grating based monochromators. Use as many crystals as necessary."
+ energy(NX_FLOAT):
+ doc: "The scalar energy of the monchromatic beam. This should link to /entry/instrument/beam/incident_energy." ######how to do links?
+ unit: NX_ENERGY
+ energy_error(NX_FLOAT):
+ doc: "The energy spread FWHM for the corresponding energy in energy. This should link to /entry/instrument/beam/incident_energy_spread."
+ unit: NX_ENERGY
+ transformations(NXtransformations) ###### should we describe the beam rotation by the mono?
+ exists: optional
+ (NXbeam):
+ distance(NX_NUMBER):
+ exists: recommended ### cannot be required, hard to know???
+ doc: "Distance of the point of evaluation of the beam from the sample surface."
+ unit: NX_LENGTH
+ incident_energy(NX_FLOAT):
+ unit: NX_ENERGY
+ doc: "In the case of a monchromatic beam this is the scalar energy. Several other use cases are permitted, depending on the presence of other incident_energy_X fields. In the case of a polychromatic beam this is an array of length m of energies, with the relative weights in incident_energy_weights. In the case of a monochromatic beam that varies shot-to-shot, this is an array of energies, one for each recorded shot. Here, incident_energy_weights and incident_energy_spread are not set. In the case of a polychromatic beam that varies shot-to-shot, this is an array of length m with the relative weights in incident_energy_weights as a 2D array. In the case of a polychromatic beam that varies shot-to-shot and where the channels also vary, this is a 2D array of dimensions nP by m (slow to fast) with the relative weights in incident_energy_weights as a 2D array. Note, variants are a good way to represent several of these use cases in a single dataset, e.g. if a calibrated, single-value energy value is available along with the original spectrum from which it was calibrated."
+ incident_energy_spread(NX_NUMBER):
+ exists: recommended
+ unit: NX_ENERGY
+ doc: "The energy spread FWHM for the corresponding energy(ies) in incident_energy. In the case of shot-to-shot variation in the energy spread, this is a 2D array of dimension nP by m (slow to fast) of the spreads of the corresponding energy in incident_energy."
+ #incident_polarization(NX_NUMBER):
+ # exists: recommended
+ # doc: "Incident polarization specified as a Stokes vector."
+ # \@units(NX_CHAR):
+ # doc: "The units for this observable are not included in the NIAC list. Responsibility on correct formatting and parsing is handed to the user by using ‘NX_ANY’. Correct parsing can still be implemented by using this attribute. Fill with: The unit unidata symbol if the unit has one (Example: ‘T’ for the unit of magnetic flux density tesla). The unit unidata name if the unit has a name (Example: ‘farad’ for capacitance). A string describing the units according to unidata unit operation notation, if the unit is a complex combination of named units and does not have a name. Example: for lightsource brilliance (SI) ‘1/(s.mm2.mrad2)’. Here: SI units are ‘V2/m2’."
+ (NXelectronanalyser):
+ description(NX_CHAR):
+ doc: "Free text description of the type of detector."
+ # fast_axes(NX_CHAR): ### how to use these?
+ # exists: optional
+ # doc: "List of the axes that are acquired symultaneously by the detector. These refer only to the experimental variables recorded by the electron analyser. Other variables such as temperature, manipulator angles etc. are labeled as fast or slow in the data. Hemispherical in XPS mode: fast_axes: [energy] Hemispherical with channeltron, sweeping energy mode: slow_axes: [energy] axes can be less abstract than this, i.e. [detector_x, detector_y]."
+ # slow_axes(NX_CHAR):
+ # exists: optional
+ # doc: "List of the axes that are acquired by scanning a physical parameter, listed in order of decreasing speed. See fast_axes for examples."
+ (NXcollectioncolumn):
+ scheme(NX_CHAR):
+ doc: "Scheme of the electron collection column."
+ enumeration: [ ### removed some options from NXmpes
+ "Standard",
+ "Angular dispersive",
+ "Selective area",
+ "Deflector",
+ ]
+ mode(NX_CHAR):
+ exists: recommended
+ doc: "Labelling of the lens setting in use. Names are typically presets provided by the instrument vendor."
+ # projection(NX_CHAR): #### what does this mean?
+ # exists: recommended
+ tranmission_function(NX_FLOAT):
+ exists: recommended
+ doc: "Transmission function in dependance of the electron kinetic energy. To be used in intensity calibration." ### does NX_FLOAT make sense?
+ (NXenergydispersion):
+ scheme(NX_CHAR):
+ enumeration: ### removed some options from NXmpes
+ [
+ "hemispherical",
+ "double hemispherical",
+ "cylindrical mirror",
+ "display mirror",
+ "retarding grid",
+ ]
+ pass_energy(NX_FLOAT):
+ doc: "Pass energy of energy dispersive element. Determines measurement resolution."
+ unit: NX_ENERGY
+ energy_scan_mode(NX_CHAR):
+ doc: "Way of scanning the energy axis."
+ enumeration: [ ### could potentially add some more here.
+ "fixed analyzer transmission",
+ "fixed retarding ratio",
+ "fixed energies",
+ "snapshot",
+ "imaging",
+ "detector voltage scan",
+ "constant final state",
+ "constant initial state",
+ ]
+ # entrance_slit(NXaperture): ### is this level of description necessary -> most items exist in NXaperture already
+ # exists: optional
+ # doc: "Size, position, and shape of the entrance slit in dispersive analyzers (aperture generating the energy filtering)."
+ # description(NX_CHAR):
+ # exists: optional
+ # doc: "Type of aperture inserted in the beam."
+ # enumeration: ["slit", "pinhole", "iris"]
+ # shape(NX_CHAR):
+ # exists: optional
+ # doc: "Description of the shape of the active part of the aperture, curved or straight for horizontal slits, square or round for pinhole etc."
+ # enumeration:
+ # [
+ # "straight slit",
+ # "curved slit",
+ # "pinhole",
+ # "circle",
+ # "square",
+ # "hexagon",
+ # "octagon",
+ # "bladed",
+ # "open",
+ # "grid"
+ # ]
+ # size(NX_NUMBER):
+ # exists: optional
+ # doc: "The relevant dimension for the entrance_slit, i.e. slit width, pinhole and iris diameter."
+ # exit_slit(NXaperture):
+ # exists: optional
+ # doc: "Size, position and shape of the exit slit in dispersive analyzers."
+ # description(NX_CHAR):
+ # exists: optional
+ # doc: "Type of aperture inserted in the beam."
+ # enumeration: ["slit", "pinhole", "iris"]
+ # shape(NX_CHAR):
+ # exists: optional
+ # doc: "Description of the shape of the active part of the aperture, curved or straight for horizontal slits, square or round for pinhole etc."
+ # enumeration:
+ # [
+ # "straight slit",
+ # "curved slit",
+ # "pinhole",
+ # "circle",
+ # "square",
+ # "hexagon",
+ # "octagon",
+ # "bladed",
+ # "open",
+ # "grid"
+ # ]
+ # size(NX_NUMBER):
+ # exists: optional
+ # doc: "The relevant dimension for the entrance_slit, i.e. slit width, pinhole and iris diameter."
+ # iris(NXaperture):
+ # exists: optional
+ # doc: "Size, position, and shape of the iris in dispersive analyzers."
+ # description(NX_CHAR):
+ # exists: optional
+ # doc: "Type of aperture inserted in the beam."
+ # enumeration: ["slit", "pinhole", "iris"]
+ # shape(NX_CHAR):
+ # exists: optional
+ # doc: "Description of the shape of the active part of the aperture, curved or straight for horizontal slits, square or round for pinhole etc."
+ # enumeration:
+ # [
+ # "straight slit",
+ # "curved slit",
+ # "pinhole",
+ # "circle",
+ # "square",
+ # "hexagon",
+ # "octagon",
+ # "bladed",
+ # "open",
+ # "grid"
+ # ]
+ # size(NX_NUMBER):
+ # exists: optional
+ # doc: "The relevant dimension for the entrance_slit, i.e. slit width, pinhole and iris diameter."
+ analyzer_radius(NX_FLOAT):
+ exists: optional
+ description: The radius of the hemispherical analyzer in mm (only if hemispherical analyzer is used.)
+ (NXdetector):
+ # amplifier:type(NX_CHAR):
+ # exists: recommended
+ # doc: "Description of the detector type."
+ # enumeration:
+ # ["MCP", "channeltron"]
+ # detector_type(NX_CHAR):
+ # exists: recommended
+ # doc: "Description of the detector type."
+ # enumeration:
+ # [
+ # "DLD",
+ # "Phosphor+CCD",
+ # "Phosphor+CMOS",
+ # "ECMOS",
+ # "Anode",
+ # "Multi-anode"
+ # ]
+ # (NXdata): # Raw signal without calibrated axes.
+ # exists: recommended
+ # \@signal:
+ # enumeration: ['raw']
+ # raw(NX_NUMBER): # There is a block of numbers named raw.
+ # doc: "Raw data before calibration."
+ GEOMETRY(NXtransformations): ### took this from NXmpes_liqudidjet, how to describe geometry? on indicidual classes? would like to describe angles between different instrument parts here?
+ exists: optional
+ doc: "Transformations describing the transformation chain of all relevant vectors in the experiment."
+ gravity_axis(NX_NUMBER):
+ doc: "Direction of gravity."
+ \@vector(NX_NUMBER):
+ doc: "The vector in the direction of gravity."
+ \@depends_on(NX_CHAR):
+ doc: "Set to '.' to specify the normal vector to which all other vectors are related."
+ beam_axis(NX_NUMBER):
+ doc: "Direction of the photon beam."
+ \@vector(NX_NUMBER):
+ doc: "The vector of the photon-beam direction into the chamber after the last optical element (or directly from the source if there are no optical elements)."
+ \@depends_on(NX_CHAR):
+ doc: "This should be a link to /entry/instrument/geometry/gravity_axis."
+ analyzer_lens_axis(NX_NUMBER):
+ doc: "Direction of lens axis of analyzer."
+ \@vector(NX_NUMBER):
+ doc: "The vector pointing along the central axis of the analyzer lens system in from the sample."
+ \@depends_on(NX_CHAR):
+ doc: "This should be a link to /entry/instrument/geometry/beam_axis."
+ hemisphere_orientation(NX_NUMBER):
+ exists: optional
+ doc: "Orientation of the hemisphere with respect to the lens system in case of a hemispherical electron analyzer."
+ \@vector(NX_NUMBER):
+ doc: "The vector pointing towards the detector from the entrance slit of the hemisphere, and should be perpendicular to the analyzer lens system."
+ \@depends_on(NX_CHAR):
+ doc: "This should be a link to /entry/instrument/geometry/analyzer_lens_axis."
+ (NXmanipulator):
+ # exists: optional
+ # doc: "Manipulator for positioning of the sample."
+ # sample_temperature(NX_FLOAT):
+ # exists: recommended
+ # doc: "Sample temperature during the experiment. Can be a single float or an array for temperature-programmed XPS."
+ # unit: NX_TEMPERATURE
+ sample_heater(NX_CHAR):
+ exists: optional
+ doc: "Method of heating the sample. Can be e.g. electron beam heating, laser, halogen lamp"
+ # heater_power(NX_FLOAT):
+ # exists: optional
+ # doc: "Power in the heater for temperature control."
+ # sample_temperature(NX_FLOAT):
+ # exists: optional
+ # doc: "Temperature at the closest point to the sample. This field may also be found in NXsample if present."
+ # drain_current(NX_FLOAT):
+ # exists: recommended
+ # doc: "Measured drain current of the sample. This field may also be found in NXsample if present."
+ # unit: NX_CURRENT
+ # sample_bias(NX_FLOAT):
+ # exists: recommended
+ # doc: "Possible bias of the sample with respect to analyser ground. This field may also be found in NXsample if present."
+ # unit: NX_CURRENT
+ (NXprocess):
+ # doc: "Document an event of data processing, reconstruction, or analysis for this data.
+ # Describe the appropriate axis calibrations for your experiment using
+ # one or more of the following NXcalibrations."
+ energy_calibration(NXcalibration):
+ # exists: recommended
+ # applied(NX_BOOLEAN):
+ # doc: "Has an energy calibration been applied?"
+ calibration_file(NX_CHAR):
+ exists: recommended
+ doc: "Name of the calibration file containing the calibration data."
+ # calibrated_axis(NX_FLOAT):
+ # exists: recommended
+ # doc: "This is the calibrated energy axis to be used for data plotting."
+ # spatial_calibration(NXcalibration):
+ # exists: optional
+ # applied(NX_BOOLEAN):
+ # doc: "Has a spatial calibration been applied?"
+ # calibrated_axis(NX_FLOAT):
+ # exists: recommended
+ # doc: "This is the calibrated spatial axis to be used for data plotting."
+ intensity_calibration(NXcalibration):
+ exists: recommended
+ applied(NX_BOOLEAN):
+ doc: "Has an intensity calibration been applied? That is, has the transmission function of the analyzer been taken into account?"
+ transmission_function(NX_FLOAT):
+ exists: recommended
+ doc: "Transmission function of the electron collection column. This should be a link to /entry/instrument/collectioncolumn/tranmission_function."
+ energy_reference(NXcalibration):
+ exists: recommended
+ applied(NX_BOOLEAN):
+ doc: "Have the energy axes been adjusted (e.g., in cases where samples are not conductive)?"
+ emission_line(NX_CHAR):
+ exists: recommended
+ doc: "Emission line which was used for the calibration."
+ offset(NXfloat):
+ exists: recommended
+ doc: "Offset between measured binding energy and calibrated binding energy of the emission line."
+ binding_energy(NX_float):
+ exists: recommended
+ doc: "The binding energy that the specified emission line appeared at, after adjusting the binding energy scale, in units of eV"
+ calibrated_axis(NX_FLOAT):
+ exists: recommended
+ doc: "This is the calibrated energy axis to be used for data plotting. This should be a link to /entry/data/energy." ######????
+ (NXsample):
+ name(NX_CHAR):
+ doc: "The user-assigned name of the sample."
+ description(NX_CHAR):
+ exists: optional
+ doc: "Full description of the sample."
+ # chemical_formula:
+ # exists: recommended
+ # doc: "The chemical formula of the sample. For mixtures use the NXsample_component group in NXsample instead."
+ # atom_types:
+ # exists: recommended
+ # doc: "List of comma-separated elements from the periodic table that are contained in the sample.
+ # If the sample substance has multiple components, all elements from each component must be included in `atom_types`."
+ form(NX_CHAR):
+ exists: optional
+ enumeration:
+ [
+ "foil",
+ "single crystal",
+ "pellet",
+ "powder",
+ "calibration sample",
+ ]
+ # preparation_date(NX_DATE_TIME):
+ # exists: recommended
+ # doc: "Date of preparation of the sample for the XPS experiment (i.e. cleaving, last annealing)."
+ # temperature(NX_FLOAT):
+ # doc: "In the case of a fixed temperature measurement this is the scalar temperature of the sample. In the case of an experiment in which the temperature is changed and recoded, this is an array of length m of temperatures. This should be a link to /entry/instrument/manipulator/sample_temperature."
+ # unit: NX_TEMPERATURE
+ situation(NX_CHAR): ### missing some enumerations here
+ enumeration:
+ [
+ "vacuum",
+ "inert atmosphere",
+ "oxidising atmosphere",
+ "reducing atmosphere",
+ "other"
+ ]
+ gas_pressure(NX_FLOAT): ######## Can be a single number or a log.
+ unit: NX_PRESSURE
+ doc: "In the case of a fixed pressure measurement this is the scalar pressure. In the case of an experiment in which pressure changes, or anyway it is recorded, this is an array of length m of pressures."
+ # sample_history(NXnote):
+ # exists: recommended
+ # doc: "A descriptor to keep track of the treatment of the sample before entering the photoemission experiment. Ideally, a full report of the previous operations, in any format (NXnote allows to add pictures, audio, movies). Alternatively, a reference to the location or a unique identifier or other metadata file. In the case these are not available, free-text description."
+ # preparation_description(NXnote):
+ # doc: "Description of the surface preparation technique for the XPS experiment, i.e. UHV cleaving, in-situ growth, sputtering/annealing etc. Ideally, a full report of the previous operations, in any format(NXnote allows to add pictures, audio, movies). Alternatively, a reference to the location or a unique identifier or other metadata file. In the case these are not available, free-text description."
+ gas_phase(NX_CHAR):
+ exists: optional
+ doc: "Description of the constitutent gases of the gas phase."
+ electric_field(NX_FLOAT):
+ exists: optional
+ unit: NX_VOLTAGE
+ doc: "Electric field applied to the sample with respect to ground / the system, e.g., via biasing."
+ (NXdata):
+ # \@signal:
+ # enumeration: ["data"]
+ \@axes(NX_CHAR):
+ doc: "The energy axis. Can be either scanned or derived from scanning of other energy axis."
+ energy(NX_NUMBER): #### how to represent this here?
+ \@units(NX_CHAR):
+ exists: recommended
+ \@long_name(NX_CHAR):
+ exists: optional
+ type(NX_CHAR):
+ exists: recommended
+ doc: "The energy axis can be either in binding or kinetic energy."
+ enumeration:
+ [
+ "kinetic",
+ "energy"
+ ]
+ step_size(NX_CHAR):
+ exists: optional
+ doc: "The step size between two consecutive energy values."
+ data(NX_NUMBER): # There is a block of numbers named data.
+ doc: "Processed plottable data. Represents a measure of one- or more-dimensional photoemission counts, where
+ the varied axis may be for example energy, spatial coordinate, pump-probe delay, temperature, etc.
+ The axes traces should be linked to the actual encoder position in NXinstrument or calibrated axes in NXprocess."
+ \@units(NX_ANY):
+ exists: recommended
+ \@long_name(NX_CHAR):
+ exists: optional
\ No newline at end of file
From 5b76d234855e49e6d7a86b65289344ad45ea2de7 Mon Sep 17 00:00:00 2001
From: Lukas Pielsticker <50139597+lukaspie@users.noreply.github.com>
Date: Thu, 4 May 2023 18:42:57 +0200
Subject: [PATCH 11/67] Removed information already given in base classes
---
contributed_definitions/nyaml/NXmpes_xps.yaml | 358 +++---------------
1 file changed, 43 insertions(+), 315 deletions(-)
diff --git a/contributed_definitions/nyaml/NXmpes_xps.yaml b/contributed_definitions/nyaml/NXmpes_xps.yaml
index e0d17ff779..e256f273f0 100644
--- a/contributed_definitions/nyaml/NXmpes_xps.yaml
+++ b/contributed_definitions/nyaml/NXmpes_xps.yaml
@@ -7,47 +7,32 @@ NXmpes_xps(NXmpes):
(NXentry):
end_time(NX_DATE_TIME):
exists: recommended
- doc: "Datetime of the end of the measurement."
definition(NX_CHAR):
- \@version(NX_CHAR):
enumeration: ["NXmpes_xps"]
- # (NXuser): #### nothing changed, can be removed from here?
- # doc: "Contact information of at least the user of the instrument or the
- # investigator who performed this experiment.
- # Adding multiple users if relevant is recommended."
- # name(NX_CHAR):
- # exists: recommended
- # doc: "Name of the user."
- # affiliation(NX_CHAR):
- # exists: recommended
- # doc: "Name of the affiliation of the user at the point in time when the
- # experiment was performed."
- # address(NX_CHAR):
- # exists: recommended
- # doc: "Full address (street, street number, ZIP, city, country) of the
- # user's affiliation."
- # email(NX_CHAR):
- # doc: "Email address of the user."
- # orcid(NX_CHAR):
- # exists: recommended
- # doc: "Author ID defined by https://orcid.org/."
(NXinstrument):
energy_resolution(NX_FLOAT):
exists: recommended ###### cannot be required. measured value (typically from Ag 3d5/2 FWHM of sputter-cleaned Ag foil), not known every time and cann update over time (detector degradation).
unit: NX_ENERGY
- manufacturer(NX_CHAR):
+ manufacturer(NXfabrication): #### should go to NXmpes at some point.
exists: recommended
- doc: "The name of the company that manufactured the spectrometer."
- enumeration: [
+ vendor:
+ exists: recommended
+ enumeration: [
"SPECS GmbH",
"Kratos",
"Physical Electronics",
"Scienta",
"Thermo Fischer Scientific",
]
+ model:
+ exists: recommended
+ work_function(NX_FLOAT):
+ exists: recommended ###### new
+ doc: "Work function of the spectrometer."
+ unit: NX_ENERGY
(NXsource):
type(NX_CHAR):
- enumeration: [ ### removed some options from NXmpes
+ enumeration: [
"Synchrotron X-ray Source",
"Rotating Anode X-ray",
"Fixed Tube X-ray",
@@ -59,75 +44,21 @@ NXmpes_xps(NXmpes):
probe(NX_CHAR):
doc: "Type of probe. In XPS it's always X-ray photons (or UV light in UPS), so the full NIAC list is restricted."
enumeration: ["x-ray", "ultraviolet"]
- (NXmonochromator):
- exists: optional
- applied(NX_BOOLEAN):
- doc: "Has the incident beam been monochromatized? "
- type(NX_CHAR):
- enumeration: [
- "Crystal",
- "Grating",
- ]
- crystal(NXcrystal):
- exists: optional
- doc: "For crystal based monochromators. Use as many crystals as necessary."
- grating(NXgrating):
- exists: optional
- doc: "For diffraction grating based monochromators. Use as many crystals as necessary."
- energy(NX_FLOAT):
- doc: "The scalar energy of the monchromatic beam. This should link to /entry/instrument/beam/incident_energy." ######how to do links?
- unit: NX_ENERGY
- energy_error(NX_FLOAT):
- doc: "The energy spread FWHM for the corresponding energy in energy. This should link to /entry/instrument/beam/incident_energy_spread."
- unit: NX_ENERGY
- transformations(NXtransformations) ###### should we describe the beam rotation by the mono?
- exists: optional
- (NXbeam):
- distance(NX_NUMBER):
- exists: recommended ### cannot be required, hard to know???
- doc: "Distance of the point of evaluation of the beam from the sample surface."
- unit: NX_LENGTH
- incident_energy(NX_FLOAT):
- unit: NX_ENERGY
- doc: "In the case of a monchromatic beam this is the scalar energy. Several other use cases are permitted, depending on the presence of other incident_energy_X fields. In the case of a polychromatic beam this is an array of length m of energies, with the relative weights in incident_energy_weights. In the case of a monochromatic beam that varies shot-to-shot, this is an array of energies, one for each recorded shot. Here, incident_energy_weights and incident_energy_spread are not set. In the case of a polychromatic beam that varies shot-to-shot, this is an array of length m with the relative weights in incident_energy_weights as a 2D array. In the case of a polychromatic beam that varies shot-to-shot and where the channels also vary, this is a 2D array of dimensions nP by m (slow to fast) with the relative weights in incident_energy_weights as a 2D array. Note, variants are a good way to represent several of these use cases in a single dataset, e.g. if a calibrated, single-value energy value is available along with the original spectrum from which it was calibrated."
- incident_energy_spread(NX_NUMBER):
- exists: recommended
- unit: NX_ENERGY
- doc: "The energy spread FWHM for the corresponding energy(ies) in incident_energy. In the case of shot-to-shot variation in the energy spread, this is a 2D array of dimension nP by m (slow to fast) of the spreads of the corresponding energy in incident_energy."
- #incident_polarization(NX_NUMBER):
- # exists: recommended
- # doc: "Incident polarization specified as a Stokes vector."
- # \@units(NX_CHAR):
- # doc: "The units for this observable are not included in the NIAC list. Responsibility on correct formatting and parsing is handed to the user by using ‘NX_ANY’. Correct parsing can still be implemented by using this attribute. Fill with: The unit unidata symbol if the unit has one (Example: ‘T’ for the unit of magnetic flux density tesla). The unit unidata name if the unit has a name (Example: ‘farad’ for capacitance). A string describing the units according to unidata unit operation notation, if the unit is a complex combination of named units and does not have a name. Example: for lightsource brilliance (SI) ‘1/(s.mm2.mrad2)’. Here: SI units are ‘V2/m2’."
(NXelectronanalyser):
- description(NX_CHAR):
- doc: "Free text description of the type of detector."
- # fast_axes(NX_CHAR): ### how to use these?
- # exists: optional
- # doc: "List of the axes that are acquired symultaneously by the detector. These refer only to the experimental variables recorded by the electron analyser. Other variables such as temperature, manipulator angles etc. are labeled as fast or slow in the data. Hemispherical in XPS mode: fast_axes: [energy] Hemispherical with channeltron, sweeping energy mode: slow_axes: [energy] axes can be less abstract than this, i.e. [detector_x, detector_y]."
- # slow_axes(NX_CHAR):
- # exists: optional
- # doc: "List of the axes that are acquired by scanning a physical parameter, listed in order of decreasing speed. See fast_axes for examples."
(NXcollectioncolumn):
scheme(NX_CHAR):
- doc: "Scheme of the electron collection column."
- enumeration: [ ### removed some options from NXmpes
+ enumeration: [ ### removed some options from NXmpes
"Standard",
"Angular dispersive",
"Selective area",
"Deflector",
]
- mode(NX_CHAR):
- exists: recommended
- doc: "Labelling of the lens setting in use. Names are typically presets provided by the instrument vendor."
- # projection(NX_CHAR): #### what does this mean?
- # exists: recommended
- tranmission_function(NX_FLOAT):
+ transmission_function(NX_FLOAT):
exists: recommended
doc: "Transmission function in dependance of the electron kinetic energy. To be used in intensity calibration." ### does NX_FLOAT make sense?
(NXenergydispersion):
scheme(NX_CHAR):
- enumeration: ### removed some options from NXmpes
+ enumeration: ### removed some options from NXmpes
[
"hemispherical",
"double hemispherical",
@@ -135,12 +66,9 @@ NXmpes_xps(NXmpes):
"display mirror",
"retarding grid",
]
- pass_energy(NX_FLOAT):
- doc: "Pass energy of energy dispersive element. Determines measurement resolution."
- unit: NX_ENERGY
energy_scan_mode(NX_CHAR):
doc: "Way of scanning the energy axis."
- enumeration: [ ### could potentially add some more here.
+ enumeration: [ ### could potentially add some more here.
"fixed analyzer transmission",
"fixed retarding ratio",
"fixed energies",
@@ -150,220 +78,51 @@ NXmpes_xps(NXmpes):
"constant final state",
"constant initial state",
]
- # entrance_slit(NXaperture): ### is this level of description necessary -> most items exist in NXaperture already
- # exists: optional
- # doc: "Size, position, and shape of the entrance slit in dispersive analyzers (aperture generating the energy filtering)."
- # description(NX_CHAR):
- # exists: optional
- # doc: "Type of aperture inserted in the beam."
- # enumeration: ["slit", "pinhole", "iris"]
- # shape(NX_CHAR):
- # exists: optional
- # doc: "Description of the shape of the active part of the aperture, curved or straight for horizontal slits, square or round for pinhole etc."
- # enumeration:
- # [
- # "straight slit",
- # "curved slit",
- # "pinhole",
- # "circle",
- # "square",
- # "hexagon",
- # "octagon",
- # "bladed",
- # "open",
- # "grid"
- # ]
- # size(NX_NUMBER):
- # exists: optional
- # doc: "The relevant dimension for the entrance_slit, i.e. slit width, pinhole and iris diameter."
- # exit_slit(NXaperture):
- # exists: optional
- # doc: "Size, position and shape of the exit slit in dispersive analyzers."
- # description(NX_CHAR):
- # exists: optional
- # doc: "Type of aperture inserted in the beam."
- # enumeration: ["slit", "pinhole", "iris"]
- # shape(NX_CHAR):
- # exists: optional
- # doc: "Description of the shape of the active part of the aperture, curved or straight for horizontal slits, square or round for pinhole etc."
- # enumeration:
- # [
- # "straight slit",
- # "curved slit",
- # "pinhole",
- # "circle",
- # "square",
- # "hexagon",
- # "octagon",
- # "bladed",
- # "open",
- # "grid"
- # ]
- # size(NX_NUMBER):
- # exists: optional
- # doc: "The relevant dimension for the entrance_slit, i.e. slit width, pinhole and iris diameter."
- # iris(NXaperture):
- # exists: optional
- # doc: "Size, position, and shape of the iris in dispersive analyzers."
- # description(NX_CHAR):
- # exists: optional
- # doc: "Type of aperture inserted in the beam."
- # enumeration: ["slit", "pinhole", "iris"]
- # shape(NX_CHAR):
- # exists: optional
- # doc: "Description of the shape of the active part of the aperture, curved or straight for horizontal slits, square or round for pinhole etc."
- # enumeration:
- # [
- # "straight slit",
- # "curved slit",
- # "pinhole",
- # "circle",
- # "square",
- # "hexagon",
- # "octagon",
- # "bladed",
- # "open",
- # "grid"
- # ]
- # size(NX_NUMBER):
- # exists: optional
- # doc: "The relevant dimension for the entrance_slit, i.e. slit width, pinhole and iris diameter."
+ iris(NXaperture):
+ exists: optional
analyzer_radius(NX_FLOAT):
exists: optional
description: The radius of the hemispherical analyzer in mm (only if hemispherical analyzer is used.)
- (NXdetector):
- # amplifier:type(NX_CHAR):
- # exists: recommended
- # doc: "Description of the detector type."
- # enumeration:
- # ["MCP", "channeltron"]
- # detector_type(NX_CHAR):
- # exists: recommended
- # doc: "Description of the detector type."
- # enumeration:
- # [
- # "DLD",
- # "Phosphor+CCD",
- # "Phosphor+CMOS",
- # "ECMOS",
- # "Anode",
- # "Multi-anode"
- # ]
- # (NXdata): # Raw signal without calibrated axes.
- # exists: recommended
- # \@signal:
- # enumeration: ['raw']
- # raw(NX_NUMBER): # There is a block of numbers named raw.
- # doc: "Raw data before calibration."
- GEOMETRY(NXtransformations): ### took this from NXmpes_liqudidjet, how to describe geometry? on indicidual classes? would like to describe angles between different instrument parts here?
- exists: optional
- doc: "Transformations describing the transformation chain of all relevant vectors in the experiment."
- gravity_axis(NX_NUMBER):
- doc: "Direction of gravity."
- \@vector(NX_NUMBER):
- doc: "The vector in the direction of gravity."
- \@depends_on(NX_CHAR):
- doc: "Set to '.' to specify the normal vector to which all other vectors are related."
- beam_axis(NX_NUMBER):
- doc: "Direction of the photon beam."
- \@vector(NX_NUMBER):
- doc: "The vector of the photon-beam direction into the chamber after the last optical element (or directly from the source if there are no optical elements)."
- \@depends_on(NX_CHAR):
- doc: "This should be a link to /entry/instrument/geometry/gravity_axis."
- analyzer_lens_axis(NX_NUMBER):
- doc: "Direction of lens axis of analyzer."
- \@vector(NX_NUMBER):
- doc: "The vector pointing along the central axis of the analyzer lens system in from the sample."
- \@depends_on(NX_CHAR):
- doc: "This should be a link to /entry/instrument/geometry/beam_axis."
- hemisphere_orientation(NX_NUMBER):
- exists: optional
- doc: "Orientation of the hemisphere with respect to the lens system in case of a hemispherical electron analyzer."
- \@vector(NX_NUMBER):
- doc: "The vector pointing towards the detector from the entrance slit of the hemisphere, and should be perpendicular to the analyzer lens system."
- \@depends_on(NX_CHAR):
- doc: "This should be a link to /entry/instrument/geometry/analyzer_lens_axis."
+ unit: NX_LENGTH
(NXmanipulator):
- # exists: optional
- # doc: "Manipulator for positioning of the sample."
- # sample_temperature(NX_FLOAT):
- # exists: recommended
- # doc: "Sample temperature during the experiment. Can be a single float or an array for temperature-programmed XPS."
- # unit: NX_TEMPERATURE
- sample_heater(NX_CHAR):
+ heater_type(NX_CHAR):
exists: optional
- doc: "Method of heating the sample. Can be e.g. electron beam heating, laser, halogen lamp"
- # heater_power(NX_FLOAT):
- # exists: optional
- # doc: "Power in the heater for temperature control."
- # sample_temperature(NX_FLOAT):
- # exists: optional
- # doc: "Temperature at the closest point to the sample. This field may also be found in NXsample if present."
- # drain_current(NX_FLOAT):
- # exists: recommended
- # doc: "Measured drain current of the sample. This field may also be found in NXsample if present."
- # unit: NX_CURRENT
- # sample_bias(NX_FLOAT):
- # exists: recommended
- # doc: "Possible bias of the sample with respect to analyser ground. This field may also be found in NXsample if present."
- # unit: NX_CURRENT
+ doc: "Method of heating the sample. Can be e.g. electron beam heating, laser, halogen lamp."
+ enumeration: [ ### could potentially add some more here.
+ "electron beam heating",
+ "laser",
+ "halogen lamp",
+ ]
(NXprocess):
- # doc: "Document an event of data processing, reconstruction, or analysis for this data.
- # Describe the appropriate axis calibrations for your experiment using
- # one or more of the following NXcalibrations."
energy_calibration(NXcalibration):
- # exists: recommended
- # applied(NX_BOOLEAN):
- # doc: "Has an energy calibration been applied?"
- calibration_file(NX_CHAR):
- exists: recommended
- doc: "Name of the calibration file containing the calibration data."
- # calibrated_axis(NX_FLOAT):
- # exists: recommended
- # doc: "This is the calibrated energy axis to be used for data plotting."
- # spatial_calibration(NXcalibration):
- # exists: optional
- # applied(NX_BOOLEAN):
- # doc: "Has a spatial calibration been applied?"
- # calibrated_axis(NX_FLOAT):
- # exists: recommended
- # doc: "This is the calibrated spatial axis to be used for data plotting."
+ exists: optional
+ calibration_file(NXnote):
+ exists: optional
+ doc: "Name of the calibration file containing the calibration data."
intensity_calibration(NXcalibration):
- exists: recommended
+ exists: optional
applied(NX_BOOLEAN):
doc: "Has an intensity calibration been applied? That is, has the transmission function of the analyzer been taken into account?"
transmission_function(NX_FLOAT):
exists: recommended
doc: "Transmission function of the electron collection column. This should be a link to /entry/instrument/collectioncolumn/tranmission_function."
energy_reference(NXcalibration):
- exists: recommended
+ exists: optional
applied(NX_BOOLEAN):
doc: "Have the energy axes been adjusted (e.g., in cases where samples are not conductive)?"
emission_line(NX_CHAR):
exists: recommended
doc: "Emission line which was used for the calibration."
- offset(NXfloat):
+ offset(NX_FLOAT):
exists: recommended
doc: "Offset between measured binding energy and calibrated binding energy of the emission line."
- binding_energy(NX_float):
+ binding_energy(NX_FLOAT):
exists: recommended
doc: "The binding energy that the specified emission line appeared at, after adjusting the binding energy scale, in units of eV"
calibrated_axis(NX_FLOAT):
exists: recommended
doc: "This is the calibrated energy axis to be used for data plotting. This should be a link to /entry/data/energy." ######????
- (NXsample):
- name(NX_CHAR):
- doc: "The user-assigned name of the sample."
- description(NX_CHAR):
- exists: optional
- doc: "Full description of the sample."
- # chemical_formula:
- # exists: recommended
- # doc: "The chemical formula of the sample. For mixtures use the NXsample_component group in NXsample instead."
- # atom_types:
- # exists: recommended
- # doc: "List of comma-separated elements from the periodic table that are contained in the sample.
- # If the sample substance has multiple components, all elements from each component must be included in `atom_types`."
+ (NXsample):
form(NX_CHAR):
exists: optional
enumeration:
@@ -372,59 +131,28 @@ NXmpes_xps(NXmpes):
"single crystal",
"pellet",
"powder",
- "calibration sample",
]
- # preparation_date(NX_DATE_TIME):
- # exists: recommended
- # doc: "Date of preparation of the sample for the XPS experiment (i.e. cleaving, last annealing)."
- # temperature(NX_FLOAT):
- # doc: "In the case of a fixed temperature measurement this is the scalar temperature of the sample. In the case of an experiment in which the temperature is changed and recoded, this is an array of length m of temperatures. This should be a link to /entry/instrument/manipulator/sample_temperature."
- # unit: NX_TEMPERATURE
- situation(NX_CHAR): ### missing some enumerations here
- enumeration:
- [
- "vacuum",
- "inert atmosphere",
- "oxidising atmosphere",
- "reducing atmosphere",
- "other"
- ]
gas_pressure(NX_FLOAT): ######## Can be a single number or a log.
unit: NX_PRESSURE
doc: "In the case of a fixed pressure measurement this is the scalar pressure. In the case of an experiment in which pressure changes, or anyway it is recorded, this is an array of length m of pressures."
- # sample_history(NXnote):
- # exists: recommended
- # doc: "A descriptor to keep track of the treatment of the sample before entering the photoemission experiment. Ideally, a full report of the previous operations, in any format (NXnote allows to add pictures, audio, movies). Alternatively, a reference to the location or a unique identifier or other metadata file. In the case these are not available, free-text description."
- # preparation_description(NXnote):
- # doc: "Description of the surface preparation technique for the XPS experiment, i.e. UHV cleaving, in-situ growth, sputtering/annealing etc. Ideally, a full report of the previous operations, in any format(NXnote allows to add pictures, audio, movies). Alternatively, a reference to the location or a unique identifier or other metadata file. In the case these are not available, free-text description."
gas_phase(NX_CHAR):
exists: optional
- doc: "Description of the constitutent gases of the gas phase."
- electric_field(NX_FLOAT):
- exists: optional
- unit: NX_VOLTAGE
- doc: "Electric field applied to the sample with respect to ground / the system, e.g., via biasing."
+ doc: "Description of the constituent gases of the gas phase."
(NXdata):
- # \@signal:
- # enumeration: ["data"]
\@axes(NX_CHAR):
- doc: "The energy axis. Can be either scanned or derived from scanning of other energy axis."
- energy(NX_NUMBER): #### how to represent this here?
- \@units(NX_CHAR):
- exists: recommended
- \@long_name(NX_CHAR):
- exists: optional
- type(NX_CHAR):
+ doc: "It should contain at least one axis called 'energy'."
+ energy(NX_NUMBER): #### how to represent this here?
+ \@type(NX_CHAR):
exists: recommended
- doc: "The energy axis can be either in binding or kinetic energy."
+ doc: "The calibrated energy axis can be either in binding or kinetic energy. "
enumeration:
[
"kinetic",
- "energy"
- ]
- step_size(NX_CHAR):
+ "binding"
+ ]
+ \@step_size(NX_FLOAT):
exists: optional
- doc: "The step size between two consecutive energy values."
+ doc: "The step size between two consecutive energy values if the energy axis is evenly spaced."
data(NX_NUMBER): # There is a block of numbers named data.
doc: "Processed plottable data. Represents a measure of one- or more-dimensional photoemission counts, where
the varied axis may be for example energy, spatial coordinate, pump-probe delay, temperature, etc.
From 27bf92706b677651002e314a7ed51c27432e037d Mon Sep 17 00:00:00 2001
From: Lukas Pielsticker <50139597+lukaspie@users.noreply.github.com>
Date: Fri, 5 May 2023 09:27:34 +0200
Subject: [PATCH 12/67] Removed some unneeded comments
---
contributed_definitions/nyaml/NXmpes_xps.yaml | 26 ++++++++++---------
1 file changed, 14 insertions(+), 12 deletions(-)
diff --git a/contributed_definitions/nyaml/NXmpes_xps.yaml b/contributed_definitions/nyaml/NXmpes_xps.yaml
index e256f273f0..2852868e97 100644
--- a/contributed_definitions/nyaml/NXmpes_xps.yaml
+++ b/contributed_definitions/nyaml/NXmpes_xps.yaml
@@ -11,9 +11,9 @@ NXmpes_xps(NXmpes):
enumeration: ["NXmpes_xps"]
(NXinstrument):
energy_resolution(NX_FLOAT):
- exists: recommended ###### cannot be required. measured value (typically from Ag 3d5/2 FWHM of sputter-cleaned Ag foil), not known every time and cann update over time (detector degradation).
+ exists: recommended # cannot be required. measured value (typically from Ag 3d5/2 FWHM of sputter-cleaned Ag foil), not known every time and cann update over time (detector degradation).
unit: NX_ENERGY
- manufacturer(NXfabrication): #### should go to NXmpes at some point.
+ manufacturer(NXfabrication): # Should go to NXmpes at some point.
exists: recommended
vendor:
exists: recommended
@@ -27,7 +27,7 @@ NXmpes_xps(NXmpes):
model:
exists: recommended
work_function(NX_FLOAT):
- exists: recommended ###### new
+ exists: recommended
doc: "Work function of the spectrometer."
unit: NX_ENERGY
(NXsource):
@@ -47,7 +47,7 @@ NXmpes_xps(NXmpes):
(NXelectronanalyser):
(NXcollectioncolumn):
scheme(NX_CHAR):
- enumeration: [ ### removed some options from NXmpes
+ enumeration: [
"Standard",
"Angular dispersive",
"Selective area",
@@ -55,10 +55,10 @@ NXmpes_xps(NXmpes):
]
transmission_function(NX_FLOAT):
exists: recommended
- doc: "Transmission function in dependance of the electron kinetic energy. To be used in intensity calibration." ### does NX_FLOAT make sense?
+ doc: "Transmission function in dependance of the electron kinetic energy. To be used in intensity calibration."
(NXenergydispersion):
scheme(NX_CHAR):
- enumeration: ### removed some options from NXmpes
+ enumeration:
[
"hemispherical",
"double hemispherical",
@@ -68,7 +68,8 @@ NXmpes_xps(NXmpes):
]
energy_scan_mode(NX_CHAR):
doc: "Way of scanning the energy axis."
- enumeration: [ ### could potentially add some more here.
+ # Could potentially add some more options here.
+ enumeration: [
"fixed analyzer transmission",
"fixed retarding ratio",
"fixed energies",
@@ -88,7 +89,8 @@ NXmpes_xps(NXmpes):
heater_type(NX_CHAR):
exists: optional
doc: "Method of heating the sample. Can be e.g. electron beam heating, laser, halogen lamp."
- enumeration: [ ### could potentially add some more here.
+ # Could potentially add some more options here.
+ enumeration: [
"electron beam heating",
"laser",
"halogen lamp",
@@ -121,7 +123,7 @@ NXmpes_xps(NXmpes):
doc: "The binding energy that the specified emission line appeared at, after adjusting the binding energy scale, in units of eV"
calibrated_axis(NX_FLOAT):
exists: recommended
- doc: "This is the calibrated energy axis to be used for data plotting. This should be a link to /entry/data/energy." ######????
+ doc: "This is the calibrated energy axis to be used for data plotting. This should be a link to /entry/data/energy."
(NXsample):
form(NX_CHAR):
exists: optional
@@ -132,7 +134,7 @@ NXmpes_xps(NXmpes):
"pellet",
"powder",
]
- gas_pressure(NX_FLOAT): ######## Can be a single number or a log.
+ gas_pressure(NX_FLOAT):
unit: NX_PRESSURE
doc: "In the case of a fixed pressure measurement this is the scalar pressure. In the case of an experiment in which pressure changes, or anyway it is recorded, this is an array of length m of pressures."
gas_phase(NX_CHAR):
@@ -141,7 +143,7 @@ NXmpes_xps(NXmpes):
(NXdata):
\@axes(NX_CHAR):
doc: "It should contain at least one axis called 'energy'."
- energy(NX_NUMBER): #### how to represent this here?
+ energy(NX_NUMBER):
\@type(NX_CHAR):
exists: recommended
doc: "The calibrated energy axis can be either in binding or kinetic energy. "
@@ -153,7 +155,7 @@ NXmpes_xps(NXmpes):
\@step_size(NX_FLOAT):
exists: optional
doc: "The step size between two consecutive energy values if the energy axis is evenly spaced."
- data(NX_NUMBER): # There is a block of numbers named data.
+ data(NX_NUMBER):
doc: "Processed plottable data. Represents a measure of one- or more-dimensional photoemission counts, where
the varied axis may be for example energy, spatial coordinate, pump-probe delay, temperature, etc.
The axes traces should be linked to the actual encoder position in NXinstrument or calibrated axes in NXprocess."
From 42f7f721c53da85388eda6d291f4b110dbd662ce Mon Sep 17 00:00:00 2001
From: Lukas Pielsticker <50139597+lukaspie@users.noreply.github.com>
Date: Fri, 5 May 2023 11:33:40 +0200
Subject: [PATCH 13/67] Add description of instrument orientation
- Angle between beam and sample normal-> needed for determination of probing depth
- Angle between beam and analyzer axes -> needed for data analysis
---
contributed_definitions/nyaml/NXmpes_xps.yaml | 11 ++++++++++-
1 file changed, 10 insertions(+), 1 deletion(-)
diff --git a/contributed_definitions/nyaml/NXmpes_xps.yaml b/contributed_definitions/nyaml/NXmpes_xps.yaml
index 2852868e97..dee2ac6f0e 100644
--- a/contributed_definitions/nyaml/NXmpes_xps.yaml
+++ b/contributed_definitions/nyaml/NXmpes_xps.yaml
@@ -30,6 +30,15 @@ NXmpes_xps(NXmpes):
exists: recommended
doc: "Work function of the spectrometer."
unit: NX_ENERGY
+ # These angles could also be described by NXtransformations on the analyzer and beam.
+ angle_beam_sample(NX_NUMBER):
+ exists: recommended
+ doc: "Orientation of the beam with respect to the sample normal."
+ units: NX_ANGLE
+ angle_beam_analyser(NX_NUMBER):
+ exists: recommended
+ doc: "Orientation of the beam with respect to the central axis of the analyzer."
+ units: NX_ANGLE
(NXsource):
type(NX_CHAR):
enumeration: [
@@ -83,7 +92,7 @@ NXmpes_xps(NXmpes):
exists: optional
analyzer_radius(NX_FLOAT):
exists: optional
- description: The radius of the hemispherical analyzer in mm (only if hemispherical analyzer is used.)
+ description: "The radius of the hemispherical analyzer in mm (only if hemispherical analyzer is used."
unit: NX_LENGTH
(NXmanipulator):
heater_type(NX_CHAR):
From 34e9046f9d6fa60396d3369666aa48bfc570a04e Mon Sep 17 00:00:00 2001
From: Lukas Pielsticker <50139597+lukaspie@users.noreply.github.com>
Date: Tue, 9 May 2023 14:20:10 +0200
Subject: [PATCH 14/67] Move orientation of instrument parts
Instead of having two fields on the instrument for the angle between beam and sample and the angle between beam and analyser, this information is stored in depends_on and NXtransformations in NXinstrument and NXsample, respectively.
---
contributed_definitions/nyaml/NXmpes_xps.yaml | 23 +++++++++++--------
1 file changed, 13 insertions(+), 10 deletions(-)
diff --git a/contributed_definitions/nyaml/NXmpes_xps.yaml b/contributed_definitions/nyaml/NXmpes_xps.yaml
index dee2ac6f0e..df68169d40 100644
--- a/contributed_definitions/nyaml/NXmpes_xps.yaml
+++ b/contributed_definitions/nyaml/NXmpes_xps.yaml
@@ -30,15 +30,6 @@ NXmpes_xps(NXmpes):
exists: recommended
doc: "Work function of the spectrometer."
unit: NX_ENERGY
- # These angles could also be described by NXtransformations on the analyzer and beam.
- angle_beam_sample(NX_NUMBER):
- exists: recommended
- doc: "Orientation of the beam with respect to the sample normal."
- units: NX_ANGLE
- angle_beam_analyser(NX_NUMBER):
- exists: recommended
- doc: "Orientation of the beam with respect to the central axis of the analyzer."
- units: NX_ANGLE
(NXsource):
type(NX_CHAR):
enumeration: [
@@ -104,6 +95,12 @@ NXmpes_xps(NXmpes):
"laser",
"halogen lamp",
]
+ depends_on(NX_CHAR):
+ exists: recommended
+ doc: "Reference to the transformation describing the orientation of the analyzer relative to the beam."
+ (NXtransformations):
+ exists: recommended
+ doc: "Set of transformations, describing the relative orientation of the analyzer with respect to the beam coordinate system."
(NXprocess):
energy_calibration(NXcalibration):
exists: optional
@@ -148,7 +145,13 @@ NXmpes_xps(NXmpes):
doc: "In the case of a fixed pressure measurement this is the scalar pressure. In the case of an experiment in which pressure changes, or anyway it is recorded, this is an array of length m of pressures."
gas_phase(NX_CHAR):
exists: optional
- doc: "Description of the constituent gases of the gas phase."
+ doc: "Description of the constituent gases of the gas phase."
+ depends_on(NX_CHAR):
+ exists: recommended
+ doc: "Reference to a transformation describing the orientation of the sample relative to the beam coordinate system."
+ (NXtransformations):
+ exists: recommended
+ doc: "Set of transformations, describing the relative orientation of the sample with respect to the beam coordinate system."
(NXdata):
\@axes(NX_CHAR):
doc: "It should contain at least one axis called 'energy'."
From d60f8601f3fd0b5c258fd9a417c6aa33b37580f4 Mon Sep 17 00:00:00 2001
From: Lukas Pielsticker <50139597+lukaspie@users.noreply.github.com>
Date: Tue, 9 May 2023 14:24:20 +0200
Subject: [PATCH 15/67] Update transmission function information
- The transmission function contains an additional NXnote field "file" describing the file in which the TF data is stored.
---
contributed_definitions/nyaml/NXmpes_xps.yaml | 15 +++++++++++++--
1 file changed, 13 insertions(+), 2 deletions(-)
diff --git a/contributed_definitions/nyaml/NXmpes_xps.yaml b/contributed_definitions/nyaml/NXmpes_xps.yaml
index df68169d40..4957dc868a 100644
--- a/contributed_definitions/nyaml/NXmpes_xps.yaml
+++ b/contributed_definitions/nyaml/NXmpes_xps.yaml
@@ -55,7 +55,13 @@ NXmpes_xps(NXmpes):
]
transmission_function(NX_FLOAT):
exists: recommended
- doc: "Transmission function in dependance of the electron kinetic energy. To be used in intensity calibration."
+ doc: "Transmission function of the electron collection column.
+ This should be a link to /entry/process/intensity_calibration/tranmission_function."
+ units: NX_ANY
+ file(NXnote):
+ exists: recommended
+ doc: "File containing the transmission function data of the electron collection column.
+ This should be a link to /entry/instrument/collectioncolumn/transmission_function/file."
(NXenergydispersion):
scheme(NX_CHAR):
enumeration:
@@ -113,7 +119,12 @@ NXmpes_xps(NXmpes):
doc: "Has an intensity calibration been applied? That is, has the transmission function of the analyzer been taken into account?"
transmission_function(NX_FLOAT):
exists: recommended
- doc: "Transmission function of the electron collection column. This should be a link to /entry/instrument/collectioncolumn/tranmission_function."
+ doc: "Transmission function of the electron collection column.
+ This should be a link to /entry/instrument/collectioncolumn/transmission_function."
+ units: NX_ANY
+ file(NXnote):
+ exists: recommended
+ doc: "File containing the transmission function data.
energy_reference(NXcalibration):
exists: optional
applied(NX_BOOLEAN):
From ffeb32c3b63ef04289cba794b141900eec6cd757 Mon Sep 17 00:00:00 2001
From: Lukas Pielsticker <50139597+lukaspie@users.noreply.github.com>
Date: Tue, 9 May 2023 14:32:44 +0200
Subject: [PATCH 16/67] Update documentation, add comments for discussion
---
contributed_definitions/nyaml/NXmpes_xps.yaml | 44 ++++++++++---------
1 file changed, 24 insertions(+), 20 deletions(-)
diff --git a/contributed_definitions/nyaml/NXmpes_xps.yaml b/contributed_definitions/nyaml/NXmpes_xps.yaml
index 4957dc868a..78d5466861 100644
--- a/contributed_definitions/nyaml/NXmpes_xps.yaml
+++ b/contributed_definitions/nyaml/NXmpes_xps.yaml
@@ -60,7 +60,7 @@ NXmpes_xps(NXmpes):
units: NX_ANY
file(NXnote):
exists: recommended
- doc: "File containing the transmission function data of the electron collection column.
+ doc: "Name of the file containing the transmission function data of the electron collection column.
This should be a link to /entry/instrument/collectioncolumn/transmission_function/file."
(NXenergydispersion):
scheme(NX_CHAR):
@@ -84,18 +84,19 @@ NXmpes_xps(NXmpes):
"detector voltage scan",
"constant final state",
"constant initial state",
- ]
+ ]
+ # Not strictly neccessary to have.
iris(NXaperture):
exists: optional
analyzer_radius(NX_FLOAT):
exists: optional
- description: "The radius of the hemispherical analyzer in mm (only if hemispherical analyzer is used."
+ description: "The radius of the hemispherical analyzer in mm (only if hemispherical analyzer is used)."
unit: NX_LENGTH
(NXmanipulator):
heater_type(NX_CHAR):
exists: optional
doc: "Method of heating the sample. Can be e.g. electron beam heating, laser, halogen lamp."
- # Could potentially add some more options here.
+ # Could add some more options here.
enumeration: [
"electron beam heating",
"laser",
@@ -116,7 +117,8 @@ NXmpes_xps(NXmpes):
intensity_calibration(NXcalibration):
exists: optional
applied(NX_BOOLEAN):
- doc: "Has an intensity calibration been applied? That is, has the transmission function of the analyzer been taken into account?"
+ doc: "Has an intensity calibration been applied?
+ That is, has the transmission function of the analyzer been taken into account?"
transmission_function(NX_FLOAT):
exists: recommended
doc: "Transmission function of the electron collection column.
@@ -124,7 +126,7 @@ NXmpes_xps(NXmpes):
units: NX_ANY
file(NXnote):
exists: recommended
- doc: "File containing the transmission function data.
+ doc: "Name of the file containing the transmission function data."
energy_reference(NXcalibration):
exists: optional
applied(NX_BOOLEAN):
@@ -137,14 +139,17 @@ NXmpes_xps(NXmpes):
doc: "Offset between measured binding energy and calibrated binding energy of the emission line."
binding_energy(NX_FLOAT):
exists: recommended
- doc: "The binding energy that the specified emission line appeared at, after adjusting the binding energy scale, in units of eV"
+ doc: "The binding energy that the specified emission line appeared at,
+ after adjusting the binding energy scale, in units of eV"
calibrated_axis(NX_FLOAT):
exists: recommended
- doc: "This is the calibrated energy axis to be used for data plotting. This should be a link to /entry/data/energy."
+ doc: "This is the calibrated energy axis to be used for data plotting.
+ This should be a link to /entry/data/energy."
(NXsample):
form(NX_CHAR):
exists: optional
enumeration:
+ # There should be more options here.
[
"foil",
"single crystal",
@@ -153,7 +158,10 @@ NXmpes_xps(NXmpes):
]
gas_pressure(NX_FLOAT):
unit: NX_PRESSURE
- doc: "In the case of a fixed pressure measurement this is the scalar pressure. In the case of an experiment in which pressure changes, or anyway it is recorded, this is an array of length m of pressures."
+ doc: |
+ In the case of a fixed pressure measurement this is the scalar pressure.
+ In the case of an experiment in which pressure changes, or anyway it is recorded,
+ this is an array of length m of pressures.
gas_phase(NX_CHAR):
exists: optional
doc: "Description of the constituent gases of the gas phase."
@@ -165,11 +173,15 @@ NXmpes_xps(NXmpes):
doc: "Set of transformations, describing the relative orientation of the sample with respect to the beam coordinate system."
(NXdata):
\@axes(NX_CHAR):
- doc: "It should contain at least one axis called 'energy'."
+ doc: "The data should contain at least one axis called 'energy'."
energy(NX_NUMBER):
+ doc: |
+ The calibrated energy axis can be either in binding or kinetic energy.
+ This should be a link to either
+ /entry/process/energy calibration/calibrated_axis or
+ /entry/process/energy_reference/calibrated_axis.
\@type(NX_CHAR):
exists: recommended
- doc: "The calibrated energy axis can be either in binding or kinetic energy. "
enumeration:
[
"kinetic",
@@ -177,12 +189,4 @@ NXmpes_xps(NXmpes):
]
\@step_size(NX_FLOAT):
exists: optional
- doc: "The step size between two consecutive energy values if the energy axis is evenly spaced."
- data(NX_NUMBER):
- doc: "Processed plottable data. Represents a measure of one- or more-dimensional photoemission counts, where
- the varied axis may be for example energy, spatial coordinate, pump-probe delay, temperature, etc.
- The axes traces should be linked to the actual encoder position in NXinstrument or calibrated axes in NXprocess."
- \@units(NX_ANY):
- exists: recommended
- \@long_name(NX_CHAR):
- exists: optional
\ No newline at end of file
+ doc: "The step size between two consecutive energy values if the energy axis is evenly spaced."
\ No newline at end of file
From 8880b42a8277e3321bb25077ba01227f945bb659 Mon Sep 17 00:00:00 2001
From: Lukas Pielsticker <50139597+lukaspie@users.noreply.github.com>
Date: Thu, 4 Jan 2024 15:24:40 +0100
Subject: [PATCH 17/67] fix NXmpes yaml
---
contributed_definitions/NXmpes.nxdl.xml | 4 ++--
contributed_definitions/nyaml/NXmpes.yaml | 2 +-
2 files changed, 3 insertions(+), 3 deletions(-)
diff --git a/contributed_definitions/NXmpes.nxdl.xml b/contributed_definitions/NXmpes.nxdl.xml
index f2eb36fab0..8a07c0a25d 100644
--- a/contributed_definitions/NXmpes.nxdl.xml
+++ b/contributed_definitions/NXmpes.nxdl.xml
@@ -33,8 +33,8 @@
- This is the most general application definition for
- photoemission experiments.
+ This is the most general application definition for multidimensional
+ photoelectron spectroscopy.
Groups and fields are named according to the
`ISO 18115-1:2023`_ specification as well as the `IUPAC Recommendations 2020`_.
diff --git a/contributed_definitions/nyaml/NXmpes.yaml b/contributed_definitions/nyaml/NXmpes.yaml
index 8965b8cb50..51b1ad3616 100644
--- a/contributed_definitions/nyaml/NXmpes.yaml
+++ b/contributed_definitions/nyaml/NXmpes.yaml
@@ -1736,4 +1736,4 @@ NXmpes(NXobject):
#
#
#
-#
+#
\ No newline at end of file
From 0e2201c91e96d67afbb59a0d2e39c27fdebf1319 Mon Sep 17 00:00:00 2001
From: Lukas Pielsticker <50139597+lukaspie@users.noreply.github.com>
Date: Tue, 9 Jan 2024 09:56:55 +0100
Subject: [PATCH 18/67] update to current NXmpes status
---
contributed_definitions/Nxmpes_xps.nxdl.xml | 108 +++++++++
contributed_definitions/nyaml/NXmpes_xps.yaml | 225 ++++--------------
2 files changed, 152 insertions(+), 181 deletions(-)
create mode 100644 contributed_definitions/Nxmpes_xps.nxdl.xml
diff --git a/contributed_definitions/Nxmpes_xps.nxdl.xml b/contributed_definitions/Nxmpes_xps.nxdl.xml
new file mode 100644
index 0000000000..57f77d1d91
--- /dev/null
+++ b/contributed_definitions/Nxmpes_xps.nxdl.xml
@@ -0,0 +1,108 @@
+
+
+
+
+
+ This is the application definition for X-ray photoelectron spectroscopy.
+
+
+
+
+
+
+
+
+
+ A name of the experimental method according to `Clause 11`_ of
+ the `ISO 18115-1:2023`_ specification.
+
+ Examples for XPS-related experiments include:
+ * X-ray photoelectron spectroscopy (XPS)
+ * angle-resolved X-ray photoelectron spectroscopy (ARXPS)
+ * ultraviolet photoelectron spectroscopy (UPS)
+ * hard X-ray photoemission spectroscopy (HAXPES)
+ * near ambient pressure X-ray photoelectron spectroscopy (NAPXPS)
+ * electron spectroscopy for chemical analysis (ESCA)
+
+ .. _ISO 18115-1:2023: https://www.iso.org/standard/74811.html
+ .. _Clause 11: https://www.iso.org/obp/ui/en/#iso:std:iso:18115:-1:ed-3:v1:en:sec:11
+
+
+
+
+ XPS spectrometer
+
+
+
+
+
+
+ Angle between incoming beam and the center analyser axis.
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ Angle between incoming beam and the sample.
+
+
+
+
+
+
+
+
+
+
+
+
+ Represents a measure of one- or more-dimensional photoemission counts, where the
+ varied axis may be for example energy, pump-probe delay, temperature, etc.
+ The axes traces should be linked to the actual encoder position in NXinstrument
+ or calibrated axes in NXprocess.
+
+
+
+
+
diff --git a/contributed_definitions/nyaml/NXmpes_xps.yaml b/contributed_definitions/nyaml/NXmpes_xps.yaml
index 78d5466861..753509b044 100644
--- a/contributed_definitions/nyaml/NXmpes_xps.yaml
+++ b/contributed_definitions/nyaml/NXmpes_xps.yaml
@@ -1,192 +1,55 @@
-#lukas.pielsticker at cec.mpg.de, 04/2023
-#Draft version of a NeXus application definition for XPS.
-
doc: This is the application definition for X-ray photoelectron spectroscopy.
category: application
NXmpes_xps(NXmpes):
(NXentry):
- end_time(NX_DATE_TIME):
- exists: recommended
definition(NX_CHAR):
- enumeration: ["NXmpes_xps"]
+ enumeration: [NXmpes_xps]
+ method:
+ exists: recommended
+ doc: |
+ A name of the experimental method according to `Clause 11`_ of
+ the `ISO 18115-1:2023`_ specification.
+
+ Examples for XPS-related experiments include:
+ * X-ray photoelectron spectroscopy (XPS)
+ * angle-resolved X-ray photoelectron spectroscopy (ARXPS)
+ * ultraviolet photoelectron spectroscopy (UPS)
+ * hard X-ray photoemission spectroscopy (HAXPES)
+ * near ambient pressure X-ray photoelectron spectroscopy (NAPXPS)
+ * electron spectroscopy for chemical analysis (ESCA)
+
+ .. _ISO 18115-1:2023: https://www.iso.org/standard/74811.html
+ .. _Clause 11: https://www.iso.org/obp/ui/en/#iso:std:iso:18115:-1:ed-3:v1:en:sec:11
(NXinstrument):
- energy_resolution(NX_FLOAT):
- exists: recommended # cannot be required. measured value (typically from Ag 3d5/2 FWHM of sputter-cleaned Ag foil), not known every time and cann update over time (detector degradation).
- unit: NX_ENERGY
- manufacturer(NXfabrication): # Should go to NXmpes at some point.
- exists: recommended
- vendor:
- exists: recommended
- enumeration: [
- "SPECS GmbH",
- "Kratos",
- "Physical Electronics",
- "Scienta",
- "Thermo Fischer Scientific",
- ]
- model:
- exists: recommended
- work_function(NX_FLOAT):
- exists: recommended
- doc: "Work function of the spectrometer."
- unit: NX_ENERGY
- (NXsource):
- type(NX_CHAR):
- enumeration: [
- "Synchrotron X-ray Source",
- "Rotating Anode X-ray",
- "Fixed Tube X-ray",
- "UV Laser",
- "Free-Electron Laser",
- "UV Plasma Source",
- "Metal Jet X-ray",
- ]
- probe(NX_CHAR):
- doc: "Type of probe. In XPS it's always X-ray photons (or UV light in UPS), so the full NIAC list is restricted."
- enumeration: ["x-ray", "ultraviolet"]
+ doc: XPS spectrometer
(NXelectronanalyser):
- (NXcollectioncolumn):
- scheme(NX_CHAR):
- enumeration: [
- "Standard",
- "Angular dispersive",
- "Selective area",
- "Deflector",
- ]
- transmission_function(NX_FLOAT):
- exists: recommended
- doc: "Transmission function of the electron collection column.
- This should be a link to /entry/process/intensity_calibration/tranmission_function."
- units: NX_ANY
- file(NXnote):
- exists: recommended
- doc: "Name of the file containing the transmission function data of the electron collection column.
- This should be a link to /entry/instrument/collectioncolumn/transmission_function/file."
- (NXenergydispersion):
- scheme(NX_CHAR):
- enumeration:
- [
- "hemispherical",
- "double hemispherical",
- "cylindrical mirror",
- "display mirror",
- "retarding grid",
- ]
- energy_scan_mode(NX_CHAR):
- doc: "Way of scanning the energy axis."
- # Could potentially add some more options here.
- enumeration: [
- "fixed analyzer transmission",
- "fixed retarding ratio",
- "fixed energies",
- "snapshot",
- "imaging",
- "detector voltage scan",
- "constant final state",
- "constant initial state",
- ]
- # Not strictly neccessary to have.
- iris(NXaperture):
- exists: optional
- analyzer_radius(NX_FLOAT):
- exists: optional
- description: "The radius of the hemispherical analyzer in mm (only if hemispherical analyzer is used)."
- unit: NX_LENGTH
- (NXmanipulator):
- heater_type(NX_CHAR):
- exists: optional
- doc: "Method of heating the sample. Can be e.g. electron beam heating, laser, halogen lamp."
- # Could add some more options here.
- enumeration: [
- "electron beam heating",
- "laser",
- "halogen lamp",
- ]
- depends_on(NX_CHAR):
- exists: recommended
- doc: "Reference to the transformation describing the orientation of the analyzer relative to the beam."
- (NXtransformations):
- exists: recommended
- doc: "Set of transformations, describing the relative orientation of the analyzer with respect to the beam coordinate system."
- (NXprocess):
- energy_calibration(NXcalibration):
- exists: optional
- calibration_file(NXnote):
- exists: optional
- doc: "Name of the calibration file containing the calibration data."
- intensity_calibration(NXcalibration):
- exists: optional
- applied(NX_BOOLEAN):
- doc: "Has an intensity calibration been applied?
- That is, has the transmission function of the analyzer been taken into account?"
- transmission_function(NX_FLOAT):
- exists: recommended
- doc: "Transmission function of the electron collection column.
- This should be a link to /entry/instrument/collectioncolumn/transmission_function."
- units: NX_ANY
- file(NXnote):
- exists: recommended
- doc: "Name of the file containing the transmission function data."
- energy_reference(NXcalibration):
- exists: optional
- applied(NX_BOOLEAN):
- doc: "Have the energy axes been adjusted (e.g., in cases where samples are not conductive)?"
- emission_line(NX_CHAR):
- exists: recommended
- doc: "Emission line which was used for the calibration."
- offset(NX_FLOAT):
- exists: recommended
- doc: "Offset between measured binding energy and calibrated binding energy of the emission line."
- binding_energy(NX_FLOAT):
- exists: recommended
- doc: "The binding energy that the specified emission line appeared at,
- after adjusting the binding energy scale, in units of eV"
- calibrated_axis(NX_FLOAT):
+ work_function(NX_FLOAT):
+ exists: recommended
+ (NXtransformations):
+ angle_beam_analyser(NX_NUMBER):
exists: recommended
- doc: "This is the calibrated energy axis to be used for data plotting.
- This should be a link to /entry/data/energy."
- (NXsample):
- form(NX_CHAR):
- exists: optional
- enumeration:
- # There should be more options here.
- [
- "foil",
- "single crystal",
- "pellet",
- "powder",
- ]
- gas_pressure(NX_FLOAT):
- unit: NX_PRESSURE
- doc: |
- In the case of a fixed pressure measurement this is the scalar pressure.
- In the case of an experiment in which pressure changes, or anyway it is recorded,
- this is an array of length m of pressures.
- gas_phase(NX_CHAR):
- exists: optional
- doc: "Description of the constituent gases of the gas phase."
- depends_on(NX_CHAR):
- exists: recommended
- doc: "Reference to a transformation describing the orientation of the sample relative to the beam coordinate system."
+ doc: Angle between incoming beam and the center analyser axis.
+ unit: NX_ANGLE
+ (NXenergydispersion):
+ scheme:
+ enumeration: [hemispherical, double hemispherical, cylindrical mirror]
+ energy_scan_mode:
+ enumeration: [fixed_analyser_transmission, fixed_energy, snapshot]
+ diameter(NX_FLOAT):
+ exists: recommended
+ (NXsample):
(NXtransformations):
- exists: recommended
- doc: "Set of transformations, describing the relative orientation of the sample with respect to the beam coordinate system."
+ angle_beam_sample(NX_NUMBER):
+ exists: recommended
+ doc: Angle between incoming beam and the sample.
+ unit: NX_ANGLE
(NXdata):
- \@axes(NX_CHAR):
- doc: "The data should contain at least one axis called 'energy'."
- energy(NX_NUMBER):
+ \@signal:
+ enumeration: [data]
+ data(NX_NUMBER):
+ unit: NX_ANY
doc: |
- The calibrated energy axis can be either in binding or kinetic energy.
- This should be a link to either
- /entry/process/energy calibration/calibrated_axis or
- /entry/process/energy_reference/calibrated_axis.
- \@type(NX_CHAR):
- exists: recommended
- enumeration:
- [
- "kinetic",
- "binding"
- ]
- \@step_size(NX_FLOAT):
- exists: optional
- doc: "The step size between two consecutive energy values if the energy axis is evenly spaced."
\ No newline at end of file
+ Represents a measure of one- or more-dimensional photoemission counts, where the
+ varied axis may be for example energy, pump-probe delay, temperature, etc.
+ The axes traces should be linked to the actual encoder position in NXinstrument
+ or calibrated axes in NXprocess.
\ No newline at end of file
From 7600d2775d0da16d28aa60aed13022793da51e04 Mon Sep 17 00:00:00 2001
From: Lukas Pielsticker <50139597+lukaspie@users.noreply.github.com>
Date: Tue, 9 Jan 2024 12:00:58 +0100
Subject: [PATCH 19/67] refine NXtransformations
---
contributed_definitions/Nxmpes_xps.nxdl.xml | 22 +++++++++++++++++++
contributed_definitions/nyaml/NXmpes_xps.yaml | 14 ++++++++++++
2 files changed, 36 insertions(+)
diff --git a/contributed_definitions/Nxmpes_xps.nxdl.xml b/contributed_definitions/Nxmpes_xps.nxdl.xml
index 57f77d1d91..e36f294e2b 100644
--- a/contributed_definitions/Nxmpes_xps.nxdl.xml
+++ b/contributed_definitions/Nxmpes_xps.nxdl.xml
@@ -54,11 +54,22 @@
+
+
+ Reference to the transformation describing the orientation of the analyzer
+ relative to the beam.
+
+
Angle between incoming beam and the center analyser axis.
+
+
+
+
+
@@ -81,11 +92,22 @@
+
+
+ Reference to the transformation describing the orientation of the sample
+ relative to the beam.
+
+
Angle between incoming beam and the sample.
+
+
+
+
+
diff --git a/contributed_definitions/nyaml/NXmpes_xps.yaml b/contributed_definitions/nyaml/NXmpes_xps.yaml
index 753509b044..fb3d54c34d 100644
--- a/contributed_definitions/nyaml/NXmpes_xps.yaml
+++ b/contributed_definitions/nyaml/NXmpes_xps.yaml
@@ -25,11 +25,18 @@ NXmpes_xps(NXmpes):
(NXelectronanalyser):
work_function(NX_FLOAT):
exists: recommended
+ depends_on(NX_CHAR):
+ exists: recommended
+ doc: |
+ Reference to the transformation describing the orientation of the analyzer
+ relative to the beam.
(NXtransformations):
angle_beam_analyser(NX_NUMBER):
exists: recommended
doc: Angle between incoming beam and the center analyser axis.
unit: NX_ANGLE
+ \@transformation_type:
+ enumeration: [rotation]
(NXenergydispersion):
scheme:
enumeration: [hemispherical, double hemispherical, cylindrical mirror]
@@ -38,11 +45,18 @@ NXmpes_xps(NXmpes):
diameter(NX_FLOAT):
exists: recommended
(NXsample):
+ depends_on(NX_CHAR):
+ exists: recommended
+ doc: |
+ Reference to the transformation describing the orientation of the sample
+ relative to the beam.
(NXtransformations):
angle_beam_sample(NX_NUMBER):
exists: recommended
doc: Angle between incoming beam and the sample.
unit: NX_ANGLE
+ \@transformation_type:
+ enumeration: [rotation]
(NXdata):
\@signal:
enumeration: [data]
From 563d4e923e4db708b0b7c298ea127dda54333744 Mon Sep 17 00:00:00 2001
From: Lukas Pielsticker <50139597+lukaspie@users.noreply.github.com>
Date: Fri, 12 Jan 2024 16:45:52 +0100
Subject: [PATCH 20/67] add coordinate system and coordinate_system_set
---
contributed_definitions/Nxmpes_xps.nxdl.xml | 56 ++++-
contributed_definitions/nyaml/NXmpes_xps.yaml | 218 +++++++++++++++++-
2 files changed, 257 insertions(+), 17 deletions(-)
diff --git a/contributed_definitions/Nxmpes_xps.nxdl.xml b/contributed_definitions/Nxmpes_xps.nxdl.xml
index e36f294e2b..7b9694dbcc 100644
--- a/contributed_definitions/Nxmpes_xps.nxdl.xml
+++ b/contributed_definitions/Nxmpes_xps.nxdl.xml
@@ -37,24 +37,53 @@
the `ISO 18115-1:2023`_ specification.
Examples for XPS-related experiments include:
- * X-ray photoelectron spectroscopy (XPS)
- * angle-resolved X-ray photoelectron spectroscopy (ARXPS)
- * ultraviolet photoelectron spectroscopy (UPS)
- * hard X-ray photoemission spectroscopy (HAXPES)
- * near ambient pressure X-ray photoelectron spectroscopy (NAPXPS)
- * electron spectroscopy for chemical analysis (ESCA)
+ * X-ray photoelectron spectroscopy (XPS)
+ * angle-resolved X-ray photoelectron spectroscopy (ARXPS)
+ * ultraviolet photoelectron spectroscopy (UPS)
+ * hard X-ray photoemission spectroscopy (HAXPES)
+ * near ambient pressure X-ray photoelectron spectroscopy (NAPXPS)
+ * electron spectroscopy for chemical analysis (ESCA)
.. _ISO 18115-1:2023: https://www.iso.org/standard/74811.html
.. _Clause 11: https://www.iso.org/obp/ui/en/#iso:std:iso:18115:-1:ed-3:v1:en:sec:11
+
+
+
+ Description of the XPS base coordinate system, which is defined such that the positive z-axis
+ points towards the analyzer entry, and the x-axis lies within the beam/analyzer plane.
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ Set of transformations, describing the orientation of the XPS coordinate system with respect to
+ the beam coordinate system (.). These should be links towards the NXtransformations instances
+ defined on the individual parts of NXinstrument.
+
+
XPS spectrometer
-
-
+
Reference to the transformation describing the orientation of the analyzer
relative to the beam.
@@ -70,6 +99,11 @@
+
+
+ Link to the XPS base coordinate system.
+
+
@@ -84,6 +118,7 @@
+
@@ -108,6 +143,11 @@
+
+
+ Link to the XPS base coordinate system.
+
+
diff --git a/contributed_definitions/nyaml/NXmpes_xps.yaml b/contributed_definitions/nyaml/NXmpes_xps.yaml
index fb3d54c34d..87dbe0e0c2 100644
--- a/contributed_definitions/nyaml/NXmpes_xps.yaml
+++ b/contributed_definitions/nyaml/NXmpes_xps.yaml
@@ -1,5 +1,7 @@
-doc: This is the application definition for X-ray photoelectron spectroscopy.
category: application
+doc: |
+ This is the application definition for X-ray photoelectron spectroscopy.
+type: group
NXmpes_xps(NXmpes):
(NXentry):
definition(NX_CHAR):
@@ -20,12 +22,27 @@ NXmpes_xps(NXmpes):
.. _ISO 18115-1:2023: https://www.iso.org/standard/74811.html
.. _Clause 11: https://www.iso.org/obp/ui/en/#iso:std:iso:18115:-1:ed-3:v1:en:sec:11
+ geometries(NXcoordinate_system_set):
+ coordinate_system(NX_coordinate_system):
+ doc: |
+ Description of the XPS base coordinate system, which is defined such that the positive z-axis
+ points towards the analyzer entry, and the x-axis lies within the beam/analyzer plane.
+ origin:
+ enumeration: [beam/analyzer plane]
+ handedness:
+ enumeration: [right_handed]
+ z_direction:
+ enumeration: [analyzer entry axis]
+ (NXtransformations):
+ doc: |
+ Set of transformations, describing the orientation of the XPS coordinate system with respect to
+ the beam coordinate system (.). These should be links towards the NXtransformations instances
+ defined on the individual parts of NXinstrument.
(NXinstrument):
- doc: XPS spectrometer
+ doc: |
+ XPS spectrometer
(NXelectronanalyser):
- work_function(NX_FLOAT):
- exists: recommended
- depends_on(NX_CHAR):
+ depends_on:
exists: recommended
doc: |
Reference to the transformation describing the orientation of the analyzer
@@ -33,15 +50,20 @@ NXmpes_xps(NXmpes):
(NXtransformations):
angle_beam_analyser(NX_NUMBER):
exists: recommended
- doc: Angle between incoming beam and the center analyser axis.
unit: NX_ANGLE
+ doc: |
+ Angle between incoming beam and the center analyser axis.
\@transformation_type:
enumeration: [rotation]
+ depends_on(link):
+ target: /entry/instrument/geometries/coordinate_system
+ doc: |
+ Link to the XPS base coordinate system.
(NXenergydispersion):
scheme:
enumeration: [hemispherical, double hemispherical, cylindrical mirror]
energy_scan_mode:
- enumeration: [fixed_analyser_transmission, fixed_energy, snapshot]
+ enumeration: [fixed_analyser_transmission, fixed_retardation_ratio, fixed_energy, snapshot]
diameter(NX_FLOAT):
exists: recommended
(NXsample):
@@ -53,10 +75,15 @@ NXmpes_xps(NXmpes):
(NXtransformations):
angle_beam_sample(NX_NUMBER):
exists: recommended
- doc: Angle between incoming beam and the sample.
unit: NX_ANGLE
+ doc: |
+ Angle between incoming beam and the sample.
\@transformation_type:
enumeration: [rotation]
+ depends_on(link):
+ target: /entry/instrument/geometries/coordinate_system
+ doc: |
+ Link to the XPS base coordinate system.
(NXdata):
\@signal:
enumeration: [data]
@@ -66,4 +93,177 @@ NXmpes_xps(NXmpes):
Represents a measure of one- or more-dimensional photoemission counts, where the
varied axis may be for example energy, pump-probe delay, temperature, etc.
The axes traces should be linked to the actual encoder position in NXinstrument
- or calibrated axes in NXprocess.
\ No newline at end of file
+ or calibrated axes in NXprocess.
+
+# ++++++++++++++++++++++++++++++++++ SHA HASH ++++++++++++++++++++++++++++++++++
+# 8c2a1186258f8c27b18b84b536f85709d4751a79f87594f9cb8136dac70016a9
+#
+#
+#
+#
+#
+# This is the application definition for X-ray photoelectron spectroscopy.
+#
+#
+#
+#
+#
+#
+#
+#
+#
+# A name of the experimental method according to `Clause 11`_ of
+# the `ISO 18115-1:2023`_ specification.
+#
+# Examples for XPS-related experiments include:
+# * X-ray photoelectron spectroscopy (XPS)
+# * angle-resolved X-ray photoelectron spectroscopy (ARXPS)
+# * ultraviolet photoelectron spectroscopy (UPS)
+# * hard X-ray photoemission spectroscopy (HAXPES)
+# * near ambient pressure X-ray photoelectron spectroscopy (NAPXPS)
+# * electron spectroscopy for chemical analysis (ESCA)
+#
+# .. _ISO 18115-1:2023: https://www.iso.org/standard/74811.html
+# .. _Clause 11: https://www.iso.org/obp/ui/en/#iso:std:iso:18115:-1:ed-3:v1:en:sec:11
+#
+#
+#
+#
+#
+# Description of the XPS base coordinate system, which is defined such that the positive z-axis
+# points towards the analyzer entry, and the x-axis lies within the beam/analyzer plane.
+#
+#
+#
+#
+#
+#
+#
+#
+#
+#
+#
+#
+#
+#
+#
+#
+#
+#
+#
+#
+# Set of transformations, describing the orientation of the XPS coordinate system with respect to
+# the beam coordinate system (.). These should be links towards the NXtransformations instances
+# defined on the individual parts of NXinstrument.
+#
+#
+#
+#
+# XPS spectrometer
+#
+#
+#
+#
+# Reference to the transformation describing the orientation of the analyzer
+# relative to the beam.
+#
+#
+#
+#
+#
+# Angle between incoming beam and the center analyser axis.
+#
+#
+#
+#
+#
+#
+#
+#
+# Link to the XPS base coordinate system.
+#
+#
+#
+#
+#
+#
+#
+#
+#
+#
+#
+#
+#
+#
+#
+#
+#
+#
+#
+#
+#
+#
+#
+#
+#
+#
+#
+# Reference to the transformation describing the orientation of the sample
+# relative to the beam.
+#
+#
+#
+#
+#
+# Angle between incoming beam and the sample.
+#
+#
+#
+#
+#
+#
+#
+#
+# Link to the XPS base coordinate system.
+#
+#
+#
+#
+#
+#
+#
+#
+#
+#
+#
+#
+#
+# Represents a measure of one- or more-dimensional photoemission counts, where the
+# varied axis may be for example energy, pump-probe delay, temperature, etc.
+# The axes traces should be linked to the actual encoder position in NXinstrument
+# or calibrated axes in NXprocess.
+#
+#
+#
+#
+#
From 51b28b25ca444b8f1cfe5952f71a1b71ed90b2f3 Mon Sep 17 00:00:00 2001
From: domna
Date: Mon, 29 Jan 2024 12:30:30 +0100
Subject: [PATCH 21/67] Adds mpes_xps to mpes structure
---
manual/source/mpes-structure.rst | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/manual/source/mpes-structure.rst b/manual/source/mpes-structure.rst
index e0091995cb..af9821caee 100644
--- a/manual/source/mpes-structure.rst
+++ b/manual/source/mpes-structure.rst
@@ -33,4 +33,4 @@ Here's a list of application definitions related to photoemission spectroscopy:
An appdef for angle-resolved photoemission spectroscopy (ARPES) experiments.
:ref:`NXxps`:
- An application definition for XPS/UPS measurements.
\ No newline at end of file
+ An application definition for XPS/UPS measurements.
From 8029e66546a42ad6bd85d1ffa63cc4f006968465 Mon Sep 17 00:00:00 2001
From: Lukas Pielsticker <50139597+lukaspie@users.noreply.github.com>
Date: Fri, 9 Feb 2024 12:33:19 +0100
Subject: [PATCH 22/67] rename to NXxps
---
contributed_definitions/NXxps.nxdl.xml | 15 -
contributed_definitions/Nxmpes_xps.nxdl.xml | 170 -----------
contributed_definitions/nyaml/NXmpes_xps.yaml | 269 ------------------
contributed_definitions/nyaml/NXxps.yaml | 1 +
4 files changed, 1 insertion(+), 454 deletions(-)
delete mode 100644 contributed_definitions/Nxmpes_xps.nxdl.xml
delete mode 100644 contributed_definitions/nyaml/NXmpes_xps.yaml
diff --git a/contributed_definitions/NXxps.nxdl.xml b/contributed_definitions/NXxps.nxdl.xml
index de4e591852..b27a136475 100644
--- a/contributed_definitions/NXxps.nxdl.xml
+++ b/contributed_definitions/NXxps.nxdl.xml
@@ -49,21 +49,6 @@
-
-
- In traditional surface science, a left-handed coordinate system is used such that the positive z-axis
- points along the normal of the sample stage, and the x- and y-axes lie in the plane of the sample stage.
- However, in NeXus, a coordinate system that is the same as `McStas`_ is used. `xps_coordinate_system`
- gives the user the opportunity to work in the traditional base coordinate system.
-
- .. _McStas: http://mcstas.org/
-
- .. image:: xps/xps_cs.png
- :width: 40%
-
-
-
-
diff --git a/contributed_definitions/Nxmpes_xps.nxdl.xml b/contributed_definitions/Nxmpes_xps.nxdl.xml
deleted file mode 100644
index 7b9694dbcc..0000000000
--- a/contributed_definitions/Nxmpes_xps.nxdl.xml
+++ /dev/null
@@ -1,170 +0,0 @@
-
-
-
-
-
- This is the application definition for X-ray photoelectron spectroscopy.
-
-
-
-
-
-
-
-
-
- A name of the experimental method according to `Clause 11`_ of
- the `ISO 18115-1:2023`_ specification.
-
- Examples for XPS-related experiments include:
- * X-ray photoelectron spectroscopy (XPS)
- * angle-resolved X-ray photoelectron spectroscopy (ARXPS)
- * ultraviolet photoelectron spectroscopy (UPS)
- * hard X-ray photoemission spectroscopy (HAXPES)
- * near ambient pressure X-ray photoelectron spectroscopy (NAPXPS)
- * electron spectroscopy for chemical analysis (ESCA)
-
- .. _ISO 18115-1:2023: https://www.iso.org/standard/74811.html
- .. _Clause 11: https://www.iso.org/obp/ui/en/#iso:std:iso:18115:-1:ed-3:v1:en:sec:11
-
-
-
-
-
- Description of the XPS base coordinate system, which is defined such that the positive z-axis
- points towards the analyzer entry, and the x-axis lies within the beam/analyzer plane.
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
- Set of transformations, describing the orientation of the XPS coordinate system with respect to
- the beam coordinate system (.). These should be links towards the NXtransformations instances
- defined on the individual parts of NXinstrument.
-
-
-
-
- XPS spectrometer
-
-
-
-
- Reference to the transformation describing the orientation of the analyzer
- relative to the beam.
-
-
-
-
-
- Angle between incoming beam and the center analyser axis.
-
-
-
-
-
-
-
-
- Link to the XPS base coordinate system.
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
- Reference to the transformation describing the orientation of the sample
- relative to the beam.
-
-
-
-
-
- Angle between incoming beam and the sample.
-
-
-
-
-
-
-
-
- Link to the XPS base coordinate system.
-
-
-
-
-
-
-
-
-
-
-
-
-
- Represents a measure of one- or more-dimensional photoemission counts, where the
- varied axis may be for example energy, pump-probe delay, temperature, etc.
- The axes traces should be linked to the actual encoder position in NXinstrument
- or calibrated axes in NXprocess.
-
-
-
-
-
diff --git a/contributed_definitions/nyaml/NXmpes_xps.yaml b/contributed_definitions/nyaml/NXmpes_xps.yaml
deleted file mode 100644
index 87dbe0e0c2..0000000000
--- a/contributed_definitions/nyaml/NXmpes_xps.yaml
+++ /dev/null
@@ -1,269 +0,0 @@
-category: application
-doc: |
- This is the application definition for X-ray photoelectron spectroscopy.
-type: group
-NXmpes_xps(NXmpes):
- (NXentry):
- definition(NX_CHAR):
- enumeration: [NXmpes_xps]
- method:
- exists: recommended
- doc: |
- A name of the experimental method according to `Clause 11`_ of
- the `ISO 18115-1:2023`_ specification.
-
- Examples for XPS-related experiments include:
- * X-ray photoelectron spectroscopy (XPS)
- * angle-resolved X-ray photoelectron spectroscopy (ARXPS)
- * ultraviolet photoelectron spectroscopy (UPS)
- * hard X-ray photoemission spectroscopy (HAXPES)
- * near ambient pressure X-ray photoelectron spectroscopy (NAPXPS)
- * electron spectroscopy for chemical analysis (ESCA)
-
- .. _ISO 18115-1:2023: https://www.iso.org/standard/74811.html
- .. _Clause 11: https://www.iso.org/obp/ui/en/#iso:std:iso:18115:-1:ed-3:v1:en:sec:11
- geometries(NXcoordinate_system_set):
- coordinate_system(NX_coordinate_system):
- doc: |
- Description of the XPS base coordinate system, which is defined such that the positive z-axis
- points towards the analyzer entry, and the x-axis lies within the beam/analyzer plane.
- origin:
- enumeration: [beam/analyzer plane]
- handedness:
- enumeration: [right_handed]
- z_direction:
- enumeration: [analyzer entry axis]
- (NXtransformations):
- doc: |
- Set of transformations, describing the orientation of the XPS coordinate system with respect to
- the beam coordinate system (.). These should be links towards the NXtransformations instances
- defined on the individual parts of NXinstrument.
- (NXinstrument):
- doc: |
- XPS spectrometer
- (NXelectronanalyser):
- depends_on:
- exists: recommended
- doc: |
- Reference to the transformation describing the orientation of the analyzer
- relative to the beam.
- (NXtransformations):
- angle_beam_analyser(NX_NUMBER):
- exists: recommended
- unit: NX_ANGLE
- doc: |
- Angle between incoming beam and the center analyser axis.
- \@transformation_type:
- enumeration: [rotation]
- depends_on(link):
- target: /entry/instrument/geometries/coordinate_system
- doc: |
- Link to the XPS base coordinate system.
- (NXenergydispersion):
- scheme:
- enumeration: [hemispherical, double hemispherical, cylindrical mirror]
- energy_scan_mode:
- enumeration: [fixed_analyser_transmission, fixed_retardation_ratio, fixed_energy, snapshot]
- diameter(NX_FLOAT):
- exists: recommended
- (NXsample):
- depends_on(NX_CHAR):
- exists: recommended
- doc: |
- Reference to the transformation describing the orientation of the sample
- relative to the beam.
- (NXtransformations):
- angle_beam_sample(NX_NUMBER):
- exists: recommended
- unit: NX_ANGLE
- doc: |
- Angle between incoming beam and the sample.
- \@transformation_type:
- enumeration: [rotation]
- depends_on(link):
- target: /entry/instrument/geometries/coordinate_system
- doc: |
- Link to the XPS base coordinate system.
- (NXdata):
- \@signal:
- enumeration: [data]
- data(NX_NUMBER):
- unit: NX_ANY
- doc: |
- Represents a measure of one- or more-dimensional photoemission counts, where the
- varied axis may be for example energy, pump-probe delay, temperature, etc.
- The axes traces should be linked to the actual encoder position in NXinstrument
- or calibrated axes in NXprocess.
-
-# ++++++++++++++++++++++++++++++++++ SHA HASH ++++++++++++++++++++++++++++++++++
-# 8c2a1186258f8c27b18b84b536f85709d4751a79f87594f9cb8136dac70016a9
-#
-#
-#
-#
-#
-# This is the application definition for X-ray photoelectron spectroscopy.
-#
-#
-#
-#
-#
-#
-#
-#
-#
-# A name of the experimental method according to `Clause 11`_ of
-# the `ISO 18115-1:2023`_ specification.
-#
-# Examples for XPS-related experiments include:
-# * X-ray photoelectron spectroscopy (XPS)
-# * angle-resolved X-ray photoelectron spectroscopy (ARXPS)
-# * ultraviolet photoelectron spectroscopy (UPS)
-# * hard X-ray photoemission spectroscopy (HAXPES)
-# * near ambient pressure X-ray photoelectron spectroscopy (NAPXPS)
-# * electron spectroscopy for chemical analysis (ESCA)
-#
-# .. _ISO 18115-1:2023: https://www.iso.org/standard/74811.html
-# .. _Clause 11: https://www.iso.org/obp/ui/en/#iso:std:iso:18115:-1:ed-3:v1:en:sec:11
-#
-#
-#
-#
-#
-# Description of the XPS base coordinate system, which is defined such that the positive z-axis
-# points towards the analyzer entry, and the x-axis lies within the beam/analyzer plane.
-#
-#
-#
-#
-#
-#
-#
-#
-#
-#
-#
-#
-#
-#
-#
-#
-#
-#
-#
-#
-# Set of transformations, describing the orientation of the XPS coordinate system with respect to
-# the beam coordinate system (.). These should be links towards the NXtransformations instances
-# defined on the individual parts of NXinstrument.
-#
-#
-#
-#
-# XPS spectrometer
-#
-#
-#
-#
-# Reference to the transformation describing the orientation of the analyzer
-# relative to the beam.
-#
-#
-#
-#
-#
-# Angle between incoming beam and the center analyser axis.
-#
-#
-#
-#
-#
-#
-#
-#
-# Link to the XPS base coordinate system.
-#
-#
-#
-#
-#
-#
-#
-#
-#
-#
-#
-#
-#
-#
-#
-#
-#
-#
-#
-#
-#
-#
-#
-#
-#
-#
-#
-# Reference to the transformation describing the orientation of the sample
-# relative to the beam.
-#
-#
-#
-#
-#
-# Angle between incoming beam and the sample.
-#
-#
-#
-#
-#
-#
-#
-#
-# Link to the XPS base coordinate system.
-#
-#
-#
-#
-#
-#
-#
-#
-#
-#
-#
-#
-#
-# Represents a measure of one- or more-dimensional photoemission counts, where the
-# varied axis may be for example energy, pump-probe delay, temperature, etc.
-# The axes traces should be linked to the actual encoder position in NXinstrument
-# or calibrated axes in NXprocess.
-#
-#
-#
-#
-#
diff --git a/contributed_definitions/nyaml/NXxps.yaml b/contributed_definitions/nyaml/NXxps.yaml
index dfb2cd7622..18515ad8f7 100644
--- a/contributed_definitions/nyaml/NXxps.yaml
+++ b/contributed_definitions/nyaml/NXxps.yaml
@@ -7,6 +7,7 @@ NXxps(NXmpes):
definition(NX_CHAR):
enumeration: [NXxps]
method:
+ exists: recommended
doc: |
A name of the experimental method according to `Clause 11`_ of
the `ISO 18115-1:2023`_ specification.
From c0ee5a7b808157007b8ce84b04c689a0626a879a Mon Sep 17 00:00:00 2001
From: Lukas Pielsticker <50139597+lukaspie@users.noreply.github.com>
Date: Tue, 13 Feb 2024 13:15:03 +0100
Subject: [PATCH 23/67] initial attempt at modeling XPS peak fitting
---
contributed_definitions/NXbackground.nxdl.xml | 80 +++++
contributed_definitions/NXfit_region.nxdl.xml | 55 +++
contributed_definitions/NXmpes.nxdl.xml | 6 +-
contributed_definitions/NXpeak.nxdl.xml | 8 +-
contributed_definitions/NXpeak_model.nxdl.xml | 77 +++++
contributed_definitions/NXxps.nxdl.xml | 173 ++++++++++
.../nyaml/NXbackground.yaml | 127 +++++++
.../nyaml/NXfit_region.yaml | 84 +++++
contributed_definitions/nyaml/NXpeak.yaml | 2 +-
.../nyaml/NXpeak_model.yaml | 120 +++++++
contributed_definitions/nyaml/NXxps.yaml | 312 +++++++++++++++++-
11 files changed, 1037 insertions(+), 7 deletions(-)
create mode 100644 contributed_definitions/NXbackground.nxdl.xml
create mode 100644 contributed_definitions/NXfit_region.nxdl.xml
create mode 100644 contributed_definitions/NXpeak_model.nxdl.xml
create mode 100644 contributed_definitions/nyaml/NXbackground.yaml
create mode 100644 contributed_definitions/nyaml/NXfit_region.yaml
create mode 100644 contributed_definitions/nyaml/NXpeak_model.yaml
diff --git a/contributed_definitions/NXbackground.nxdl.xml b/contributed_definitions/NXbackground.nxdl.xml
new file mode 100644
index 0000000000..9247e5cd05
--- /dev/null
+++ b/contributed_definitions/NXbackground.nxdl.xml
@@ -0,0 +1,80 @@
+
+
+
+
+
+
+ The symbols used in the schema to specify e.g. dimensions of arrays.
+
+
+
+ Number of support points
+
+
+
+
+ Description of background for an NXpeak_model.
+
+
+
+ Human-readable label which specifies which concept/entity
+ the background represents/identifies.
+
+
+
+
+ Is the background described analytically via a functional form
+ or is it empirically defined via measured/reported
+ intensity/counts as a function of an independent variable.
+
+ Relevant details of the functional form shall be described through
+ NXcollection.
+
+
+
+
+ In the case of an empirical description of the background,
+ this array holds the position values for the independent variable.
+
+
+
+
+
+
+
+ In the case of an empirical description of the background,
+ this array holds the intensity/count values at each position.
+
+
+
+
+
+
+
+ In the case of an analytical description (or if description is other) this
+ collection holds parameter of (and eventually) the functional form.
+ For example in the case of Gaussians mu, sigma, cut-off values,
+ and background intensity are relevant parameter.
+
+
+
diff --git a/contributed_definitions/NXfit_region.nxdl.xml b/contributed_definitions/NXfit_region.nxdl.xml
new file mode 100644
index 0000000000..89ad83fcc5
--- /dev/null
+++ b/contributed_definitions/NXfit_region.nxdl.xml
@@ -0,0 +1,55 @@
+
+
+
+
+
+ Description of region for peak fitting (i.e., in an NXpeak_model).
+
+ Used for descibring a subpart of the abscissa (in 2D spectra) that is
+ used for fitting.
+
+
+
+ Human-readable label which specifies which concept/entity
+ the region represents/identifies.
+
+
+
+
+ Minimal value of the defined region.
+
+
+
+
+ Minimal value of the defined region.
+
+
+
+
+ In the case of an analytical description (or if peak_model is other) this
+ collection holds parameter of (and eventually) the functional form.
+ For example in the case of Gaussians mu, sigma, cut-off values,
+ and background intensity are relevant parameter.
+
+
+
diff --git a/contributed_definitions/NXmpes.nxdl.xml b/contributed_definitions/NXmpes.nxdl.xml
index 8a07c0a25d..3df8510c50 100644
--- a/contributed_definitions/NXmpes.nxdl.xml
+++ b/contributed_definitions/NXmpes.nxdl.xml
@@ -33,8 +33,8 @@
- This is the most general application definition for multidimensional
- photoelectron spectroscopy.
+ This is the most general application definition for
+ photoemission experiments.
Groups and fields are named according to the
`ISO 18115-1:2023`_ specification as well as the `IUPAC Recommendations 2020`_.
@@ -914,4 +914,4 @@
-
+
\ No newline at end of file
diff --git a/contributed_definitions/NXpeak.nxdl.xml b/contributed_definitions/NXpeak.nxdl.xml
index 0eea9cbe3f..ea3fc17c3d 100644
--- a/contributed_definitions/NXpeak.nxdl.xml
+++ b/contributed_definitions/NXpeak.nxdl.xml
@@ -59,6 +59,12 @@
+
+
+ Index of the peak, for determining the numbering of multiple
+ NXpeak instances. Starts with 1.
+
+
In the case of an empirical description of the peak and its shoulders,
@@ -79,7 +85,7 @@
- In the case of an analytical description (or if peak_model is other) this
+ In the case of an analytical description (or if description is other) this
collection holds parameter of (and eventually) the functional form.
For example in the case of Gaussians mu, sigma, cut-off values,
and background intensity are relevant parameter.
diff --git a/contributed_definitions/NXpeak_model.nxdl.xml b/contributed_definitions/NXpeak_model.nxdl.xml
new file mode 100644
index 0000000000..8351adbdb5
--- /dev/null
+++ b/contributed_definitions/NXpeak_model.nxdl.xml
@@ -0,0 +1,77 @@
+
+
+
+
+
+
+ The symbols used in the schema to specify e.g. dimensions of arrays.
+
+
+
+ Number of peaks.
+
+
+
+
+ Peak fitting of a one-dimensional spectrum.
+
+
+
+ Subset of the abscisssa that is used for fitting.
+ It is envisioned that regions are labeled as regions_0, regions_1, and so on.
+
+
+
+
+ One spectral peak of the peak model.
+ It is envisioned that peaks are labeled as peak_0, peak_1, and so on.
+
+
+
+
+ Description of the function used for background subtraction.
+
+
+
+
+ Resulting envelope of all NXpeak instances.
+
+ Should have the same dimension as the `position` axes of the individual peaks.
+
+
+
+
+ Figure-of-merit, e.g., :math:`\Chi^2`, or the standard deviation of the residuals,
+ to determine the goodness of fit, i.e., how well the peak model fits the measured
+ observations.
+
+ This value (which is a single number) is oftenused to guide adjustments to the
+ fitting parameters in the peak fitting process.
+
+
+
+
+ Atomic concentration of each species defined by one peak in the peak model.
+
+
+
diff --git a/contributed_definitions/NXxps.nxdl.xml b/contributed_definitions/NXxps.nxdl.xml
index b27a136475..89a4065fce 100644
--- a/contributed_definitions/NXxps.nxdl.xml
+++ b/contributed_definitions/NXxps.nxdl.xml
@@ -49,6 +49,21 @@
+
+
+ In traditional surface science, a left-handed coordinate system is used such that the positive z-axis
+ points along the normal of the sample stage, and the x- and y-axes lie in the plane of the sample stage.
+ However, in NeXus, a coordinate system that is the same as `McStas`_ is used. `xps_coordinate_system`
+ gives the user the opportunity to work in the traditional base coordinate system.
+
+ .. _McStas: http://mcstas.org/
+
+ .. image:: xps/xps_cs.png
+ :width: 40%
+
+
+
+
@@ -333,5 +348,163 @@
+
+
+ Peak model for XPS fitting. Each `NXfit` instance shall be used for the description of
+ _one_ peak fit in _one_ XPS region. As an example, this could be used to describe the
+ fitting of one measured C 1s spectrum.
+
+ This concept is related to term `3.29`_ of the ISO 18115-1:2023 standard.
+
+ .. _3.29: https://www.iso.org/obp/ui/en/#iso:std:iso:18115:-1:ed-3:v1:en:term:3.29
+
+
+
+
+ Input data and results of the fit.
+
+
+
+ Dependent variable for this fit procedure.
+
+ This could be a link to entry/data/data.
+
+
+
+
+ Independent variable for this fit procedure.
+
+ This could be a link to entry/data/energy.
+
+
+
+
+
+
+
+
+
+
+ This could be a link to entry/data/energy.
+
+
+
+
+ Intensity values of the fitted function at each energy in the position field.
+
+ This concept is related to term `3.15`_ of the ISO 18115-1:2023 standard.
+
+ .. _3.15: https://www.iso.org/obp/ui/en/#iso:std:iso:18115:-1:ed-3:v1:en:term:3.15
+
+
+
+
+
+
+
+
+ Area of the peak.
+
+
+
+
+ Width of a peak at a defined fraction of the peak height.
+
+ Usually, this will be the Full Width at Half Maximum of the peak (FWHM).
+ For asymmetric peaks, convenient measures of peak width are the half-widths of
+ each side of the peak at half maximum intensity.
+
+ This concept is related to term `3.28`_ of the ISO 18115-1:2023 standard.
+
+ .. _3.28: https://www.iso.org/obp/ui/en/#iso:std:iso:18115:-1:ed-3:v1:en:term:3.28
+
+
+
+
+
+ Position of the peak on the energy axis.
+
+
+
+
+
+
+ Total area under the peak after background removal.
+
+ This concept is related to term `3.16`_ of the ISO 18115-1:2023 standard.
+
+ .. _3.16: https://www.iso.org/obp/ui/en/#iso:std:iso:18115:-1:ed-3:v1:en:term:3.16
+
+
+
+
+
+ Functional form of the fitted XPS background.
+
+ This concept is related to term `3.21`_ of the ISO 18115-1:2023 standard.
+
+ .. _3.21: https://www.iso.org/obp/ui/en/#iso:std:iso:18115:-1:ed-3:v1:en:term:3.21
+
+
+
+
+
+
+
+
+
+
+
+ Linear background, i.e., a simple straight line from the minimal to
+ the maximal abscissa value.
+
+
+
+
+ Shirley background. In the Shirley background, the background intensity at any
+ given binding energy is proportional to the intensity of the total peak area
+ above the background in the lower binding energy peak range (i.e., the
+ background goes up in proportion to the total number of photoelectrons below its
+ binding energy position).
+
+
+
+
+ Tougaard background (or Tougaard universal cross-section approach) which is a
+ methodology for integrating the intensity of the background at a given binding
+ energy from the spectral intensities to higher kinetic energies
+
+
+
+
+ In case none of the enumeration items apply, description should be _other_
+ and the functional form of the background should be given by the `formula`
+ field.
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ Atomic concentration of each species defined by one peak in the peak model.
+ This should be an array with the indices pointing to the individual peaks
+ (i.e, peak_0, peak_1, etc.)
+
+
+
diff --git a/contributed_definitions/nyaml/NXbackground.yaml b/contributed_definitions/nyaml/NXbackground.yaml
new file mode 100644
index 0000000000..13b9004293
--- /dev/null
+++ b/contributed_definitions/nyaml/NXbackground.yaml
@@ -0,0 +1,127 @@
+category: base
+doc: |
+ Description of background for an NXpeak_model.
+symbols:
+ doc: |
+ The symbols used in the schema to specify e.g. dimensions of arrays.
+ n_support: |
+ Number of support points
+type: group
+NXbackground(NXobject):
+ label(NX_CHAR):
+ doc: |
+ Human-readable label which specifies which concept/entity
+ the background represents/identifies.
+ description(NX_CHAR):
+ doc: |
+ Is the background described analytically via a functional form
+ or is it empirically defined via measured/reported
+ intensity/counts as a function of an independent variable.
+
+ Relevant details of the functional form shall be described through
+ NXcollection.
+ position(NX_NUMBER):
+ unit: NX_ANY
+ doc: |
+ In the case of an empirical description of the background,
+ this array holds the position values for the independent variable.
+ dimensions:
+ rank: 1
+ dim: [[1, n_support]]
+ intensity(NX_NUMBER):
+ unit: NX_ANY
+ doc: |
+ In the case of an empirical description of the background,
+ this array holds the intensity/count values at each position.
+ dimensions:
+ rank: 1
+ dim: [[1, n_support]]
+ (NXcollection):
+ doc: |
+ In the case of an analytical description (or if description is other) this
+ collection holds parameter of (and eventually) the functional form.
+ For example in the case of Gaussians mu, sigma, cut-off values,
+ and background intensity are relevant parameter.
+
+# ++++++++++++++++++++++++++++++++++ SHA HASH ++++++++++++++++++++++++++++++++++
+# b830bece7ddf1d02e6d3a4e72574540c6c75a1ccd34aaec9cec2a6a0d7e1215e
+#
+#
+#
+#
+#
+#
+# The symbols used in the schema to specify e.g. dimensions of arrays.
+#
+#
+#
+# Number of support points
+#
+#
+#
+#
+# Description of background for an NXpeak_model.
+#
+#
+#
+# Human-readable label which specifies which concept/entity
+# the background represents/identifies.
+#
+#
+#
+#
+# Is the background described analytically via a functional form
+# or is it empirically defined via measured/reported
+# intensity/counts as a function of an independent variable.
+#
+# Relevant details of the functional form shall be described through
+# NXcollection.
+#
+#
+#
+#
+# In the case of an empirical description of the background,
+# this array holds the position values for the independent variable.
+#
+#
+#
+#
+#
+#
+#
+# In the case of an empirical description of the background,
+# this array holds the intensity/count values at each position.
+#
+#
+#
+#
+#
+#
+#
+# In the case of an analytical description (or if description is other) this
+# collection holds parameter of (and eventually) the functional form.
+# For example in the case of Gaussians mu, sigma, cut-off values,
+# and background intensity are relevant parameter.
+#
+#
+#
diff --git a/contributed_definitions/nyaml/NXfit_region.yaml b/contributed_definitions/nyaml/NXfit_region.yaml
new file mode 100644
index 0000000000..d3c9d50171
--- /dev/null
+++ b/contributed_definitions/nyaml/NXfit_region.yaml
@@ -0,0 +1,84 @@
+category: base
+doc: |
+ Description of region for peak fitting (i.e., in an NXpeak_model).
+
+ Used for descibring a subpart of the abscissa (in 2D spectra) that is
+ used for fitting.
+type: group
+NXfit_region(NXobject):
+ label(NX_CHAR):
+ doc: |
+ Human-readable label which specifies which concept/entity
+ the region represents/identifies.
+ start(NX_NUMBER):
+ unit: NX_ANY
+ doc: |
+ Minimal value of the defined region.
+ stop(NX_NUMBER):
+ unit: NX_ANY
+ doc: |
+ Minimal value of the defined region.
+ (NXcollection):
+ doc: |
+ In the case of an analytical description (or if peak_model is other) this
+ collection holds parameter of (and eventually) the functional form.
+ For example in the case of Gaussians mu, sigma, cut-off values,
+ and background intensity are relevant parameter.
+
+# ++++++++++++++++++++++++++++++++++ SHA HASH ++++++++++++++++++++++++++++++++++
+# 977612f25d062246a5d813884920b21014f9e8fdf5194cd374c6a38845aede50
+#
+#
+#
+#
+#
+# Description of region for peak fitting (i.e., in an NXpeak_model).
+#
+# Used for descibring a subpart of the abscissa (in 2D spectra) that is
+# used for fitting.
+#
+#
+#
+# Human-readable label which specifies which concept/entity
+# the region represents/identifies.
+#
+#
+#
+#
+# Minimal value of the defined region.
+#
+#
+#
+#
+# Minimal value of the defined region.
+#
+#
+#
+#
+# In the case of an analytical description (or if peak_model is other) this
+# collection holds parameter of (and eventually) the functional form.
+# For example in the case of Gaussians mu, sigma, cut-off values,
+# and background intensity are relevant parameter.
+#
+#
+#
diff --git a/contributed_definitions/nyaml/NXpeak.yaml b/contributed_definitions/nyaml/NXpeak.yaml
index 46f05f9200..dcf73e6dad 100644
--- a/contributed_definitions/nyaml/NXpeak.yaml
+++ b/contributed_definitions/nyaml/NXpeak.yaml
@@ -36,7 +36,7 @@ NXpeak(NXobject):
dim: (n_support,)
(NXparameters):
doc: |
- In the case of an analytical description (or if peak_model is other) this
+ In the case of an analytical description (or if description is other) this
collection holds parameter of (and eventually) the functional form.
For example in the case of Gaussians mu, sigma, cut-off values,
and background intensity are relevant parameter.
diff --git a/contributed_definitions/nyaml/NXpeak_model.yaml b/contributed_definitions/nyaml/NXpeak_model.yaml
new file mode 100644
index 0000000000..dbdf6a206b
--- /dev/null
+++ b/contributed_definitions/nyaml/NXpeak_model.yaml
@@ -0,0 +1,120 @@
+category: base
+doc: |
+ Peak fitting of a one-dimensional spectrum.
+symbols:
+ doc: |
+ The symbols used in the schema to specify e.g. dimensions of arrays.
+ n_peaks: |
+ Number of peaks.
+type: group
+NXpeak_model(NXprocess):
+ region_REGION(NXfit_region):
+ doc: |
+ Subset of the abscisssa that is used for fitting.
+ It is envisioned that regions are labeled as regions_0, regions_1, and so on.
+ peak_PEAK(NXpeak):
+ doc: |
+ One spectral peak of the peak model.
+ It is envisioned that peaks are labeled as peak_0, peak_1, and so on.
+ background(NX_background):
+ doc: |
+ Description of the function used for background subtraction.
+ envelope(NX_NUMBER):
+ unit: NX_ANY
+ doc: |
+ Resulting envelope of all NXpeak instances.
+
+ Should have the same dimension as the `position` axes of the individual peaks.
+ figure_of_merit(NX_NUMBER):
+ unit: NX_UNITLESS
+ doc: |
+ Figure-of-merit, e.g., :math:`\Chi^2`, or the standard deviation of the residuals,
+ to determine the goodness of fit, i.e., how well the peak model fits the measured
+ observations.
+
+ This value (which is a single number) is oftenused to guide adjustments to the
+ fitting parameters in the peak fitting process.
+ relative_concentration(NX_FLOAT):
+ unit: NX_ANY
+ doc: |
+ Atomic concentration of each species defined by one peak in the peak model.
+
+# ++++++++++++++++++++++++++++++++++ SHA HASH ++++++++++++++++++++++++++++++++++
+# 13bb218f2c25c0e41f54dd416852f694d0fbb2cfff457aabd85f691839a4ab72
+#
+#
+#
+#
+#
+#
+# The symbols used in the schema to specify e.g. dimensions of arrays.
+#
+#
+#
+# Number of peaks.
+#
+#
+#
+#
+# Peak fitting of a one-dimensional spectrum.
+#
+#
+#
+# Subset of the abscisssa that is used for fitting.
+# It is envisioned that regions are labeled as regions_0, regions_1, and so on.
+#
+#
+#
+#
+# One spectral peak of the peak model.
+# It is envisioned that peaks are labeled as peak_0, peak_1, and so on.
+#
+#
+#
+#
+# Description of the function used for background subtraction.
+#
+#
+#
+#
+# Resulting envelope of all NXpeak instances.
+#
+# Should have the same dimension as the `position` axes of the individual peaks.
+#
+#
+#
+#
+# Figure-of-merit, e.g., :math:`\Chi^2`, or the standard deviation of the residuals,
+# to determine the goodness of fit, i.e., how well the peak model fits the measured
+# observations.
+#
+# This value (which is a single number) is oftenused to guide adjustments to the
+# fitting parameters in the peak fitting process.
+#
+#
+#
+#
+# Atomic concentration of each species defined by one peak in the peak model.
+#
+#
+#
diff --git a/contributed_definitions/nyaml/NXxps.yaml b/contributed_definitions/nyaml/NXxps.yaml
index 18515ad8f7..c15d457deb 100644
--- a/contributed_definitions/nyaml/NXxps.yaml
+++ b/contributed_definitions/nyaml/NXxps.yaml
@@ -7,7 +7,6 @@ NXxps(NXmpes):
definition(NX_CHAR):
enumeration: [NXxps]
method:
- exists: recommended
doc: |
A name of the experimental method according to `Clause 11`_ of
the `ISO 18115-1:2023`_ specification.
@@ -231,9 +230,160 @@ NXxps(NXmpes):
\@reference:
exists: recommended
\@energy_indices:
+ (NXfit):
+ exists: recommended
+ doc:
+ - |
+ Peak model for XPS fitting. Each `NXfit` instance shall be used for the description of
+ _one_ peak fit in _one_ XPS region. As an example, this could be used to describe the
+ fitting of one measured C 1s spectrum.
+ - |
+ xref:
+ spec: ISO 18115-1:2023
+ term: 3.29
+ url: https://www.iso.org/obp/ui/en/#iso:std:iso:18115:-1:ed-3:v1:en:term:3.29
+ label:
+ data(NXdata):
+ doc: |
+ Input data and results of the fit.
+ input_dependent(NX_NUMBER):
+ unit: NX_ANY
+ doc: |
+ Dependent variable for this fit procedure.
+
+ This could be a link to entry/data/data.
+ input_independent(NX_NUMBER):
+ unit: NX_ANY
+ doc: |
+ Independent variable for this fit procedure.
+
+ This could be a link to entry/data/energy.
+ envelope(NX_NUMBER):
+ residual(NX_NUMBER):
+ exists: recommended
+ peakPEAK(NXpeak):
+ label:
+ data(NXdata):
+ position(NX_NUMBER):
+ unit: NX_ENERGY
+ doc: |
+ This could be a link to entry/data/energy.
+ intensity(NX_NUMBER):
+ doc:
+ - |
+ Intensity values of the fitted function at each energy in the position field.
+ - |
+ xref:
+ spec: ISO 18115-1:2023
+ term: 3.15
+ url: https://www.iso.org/obp/ui/en/#iso:std:iso:18115:-1:ed-3:v1:en:term:3.15
+ function(NXfit_function):
+ exists: recommended
+ description:
+ formula:
+ exists: recommended
+ area(NXfit_parameter):
+ exists: optional
+ doc: |
+ Area of the peak.
+ width(NXfit_parameter):
+ exists: optional
+ doc:
+ - |
+ Width of a peak at a defined fraction of the peak height.
+ - |
+ Usually, this will be the Full Width at Half Maximum of the peak (FWHM).
+ For asymmetric peaks, convenient measures of peak width are the half-widths of
+ each side of the peak at half maximum intensity.
+ - |
+ xref:
+ spec: ISO 18115-1:2023
+ term: 3.28
+ url: https://www.iso.org/obp/ui/en/#iso:std:iso:18115:-1:ed-3:v1:en:term:3.28
+ value:
+ unit: NX_ENERGY
+ position(NXfit_parameter):
+ exists: optional
+ doc: |
+ Position of the peak on the energy axis.
+ value:
+ unit: NX_ENERGY
+ total_area:
+ exists: recommended
+ doc:
+ - |
+ Total area under the peak after background removal.
+ - |
+ xref:
+ spec: ISO 18115-1:2023
+ term: 3.16
+ url: https://www.iso.org/obp/ui/en/#iso:std:iso:18115:-1:ed-3:v1:en:term:3.16
+ backgroundBACKGROUND(NXfit_background):
+ doc:
+ - |
+ Functional form of the fitted XPS background.
+ - |
+ xref:
+ spec: ISO 18115-1:2023
+ term: 3.21
+ url: https://www.iso.org/obp/ui/en/#iso:std:iso:18115:-1:ed-3:v1:en:term:3.21
+ label:
+ exists: recommended
+ data(NXdata):
+ position(NX_NUMBER):
+ unit: NX_ENERGY
+ intensity(NX_NUMBER):
+ function(NXfit_function):
+ exists: recommended
+ description:
+ enumeration:
+ linear:
+ doc: |
+ Linear background, i.e., a simple straight line from the minimal to
+ the maximal abscissa value.
+ Shirley:
+ doc: |
+ Shirley background. In the Shirley background, the background intensity at any
+ given binding energy is proportional to the intensity of the total peak area
+ above the background in the lower binding energy peak range (i.e., the
+ background goes up in proportion to the total number of photoelectrons below its
+ binding energy position).
+ Tougaard:
+ doc: |
+ Tougaard background (or Tougaard universal cross-section approach) which is a
+ methodology for integrating the intensity of the background at a given binding
+ energy from the spectral intensities to higher kinetic energies
+ other:
+ doc: |
+ In case none of the enumeration items apply, description should be _other_
+ and the functional form of the background should be given by the `formula`
+ field.
+ formula:
+ exists: recommended
+ global_fit_function(NXfit_function):
+ exists: recommended
+ description:
+ exists: recommended
+ formula:
+ exists: recommended
+ error_function(NXfit_function):
+ exists: recommended
+ description:
+ exists: recommended
+ formula:
+ exists: recommended
+ figure_of_meritMETRIC(NX_NUMBER):
+ exists: recommended
+ \@metric:
+ relative_concentration(NX_FLOAT):
+ unit: NX_ANY
+ doc: |
+ Atomic concentration of each species defined by one peak in the peak model.
+ This should be an array with the indices pointing to the individual peaks
+ (i.e, peak_0, peak_1, etc.)
# ++++++++++++++++++++++++++++++++++ SHA HASH ++++++++++++++++++++++++++++++++++
-# 804ce774ddb827110dd20f43f5edf1748376d129a0b4f6416c94980c77270e55
+# 04421486bc5dffb01865fb8e056d77e5f5157304a3bc3ab9024c8ad160fe21e6
#
#
#
+
+
+
+ The symbols used in the schema to specify e.g. dimensions of arrays.
+
+
+
+ Number of discretization points inside the fitting region.
+
+
+
+
+ Description of a fit procedure.
+
+
+
+ Human-readable label for this fit procedure.
+
+
+
+
+ Subset of the independent axis for this fit procedure.
+
+
+
+
+
+
+
+ One spectral peak of the peak model.
+ It is envisioned that peaks are labeled as peak_0, peak_1, and so on.
+
+
+
+ Total area under the curve. (can also be used for the total area minus any
+ background values.)
+
+
+
+
+ Relative sensitivity for this peak, to be used for quantification in
+ an NXprocess.
+
+ As an example, in X-ray spectroscopy could depend on the energy scale3
+ (see position), the ionization cross section, and the element probed.
+
+
+
+
+ Relative area of this peak compared to other peaks.
+
+ The relative area can simply be derived by dividing the total_area by the
+ total area of all peaks or by a more complicated method (e.g., by
+ additionally dividing by the relative sensitivity factors). Details shall
+ be given in fitting_method
+
+
+
+
+ Constraint on the minimum and maximum area of this peak.
+
+
+
+
+
+ Link to a peak the area constraint depends on.
+
+
+
+
+
+ Constraint on the minimum and maximum width of this peak.
+
+
+
+
+
+ Link to a peak the width constraint depends on.
+
+
+
+
+
+ Constraint on the minimum and maximum position of this peak on the abscissa.
+
+
+
+
+
+ Link to a peak the position constraint depends on.
+
+
+
+
+
+
+ One fitted background (functional, position, and intensities) of the peak fit.
+ It is envisioned that peaks are labeled as background_0, background_1, and
+ so on.
+
+
+
+
+ Description of the method used to optimize the parameters during peak fitting.
+ Examples:
+ - least squares
+ - non-linear least squares
+ - Levenberg-Marquardt algorithm (damped least-squares)
+ - linear regression
+ - Bayesian linear regression
+
+
+
+
+ Resulting envelope of all NXpeak instances.
+
+ Should have the same dimension as the `position` axes of the individual peaks.
+
+
+
+
+
+
+
+ Figure-of-merit to determine the goodness of fit, i.e., how well the peak model
+ fits the measured observations.
+
+ This value (which is a single number) is oftenused to guide adjustments to the
+ fitting parameters in the peak fitting process.
+
+
+
+ Metric used to determine the goodness of fit. Examples include:
+ - :math:`\Chi^2`, the standard deviation of the residuals
+ - reduced :math:`\Chi^2`:, :math:`\Chi^2`: per degree of freedom
+ - :math:`R^2`, the coefficient of determination
+
+
+
+
+
+ Difference between the envelope and the data to be fitted.
+
+
+
+
+
+
diff --git a/contributed_definitions/NXbackground.nxdl.xml b/contributed_definitions/NXfit_background.nxdl.xml
similarity index 83%
rename from contributed_definitions/NXbackground.nxdl.xml
rename to contributed_definitions/NXfit_background.nxdl.xml
index 9247e5cd05..0b2e73f5cb 100644
--- a/contributed_definitions/NXbackground.nxdl.xml
+++ b/contributed_definitions/NXfit_background.nxdl.xml
@@ -21,14 +21,15 @@
#
# For further information, see http://www.nexusformat.org
-->
-
+
The symbols used in the schema to specify e.g. dimensions of arrays.
- Number of support points
+ Number of discretization points at which the functional form of the
+ background has been evaluated.
@@ -48,7 +49,7 @@
intensity/counts as a function of an independent variable.
Relevant details of the functional form shall be described through
- NXcollection.
+ background_parameters.
@@ -69,12 +70,12 @@
-
+
- In the case of an analytical description (or if description is other) this
- collection holds parameter of (and eventually) the functional form.
- For example in the case of Gaussians mu, sigma, cut-off values,
- and background intensity are relevant parameter.
+ In the case of an analytical description (or if description is other),
+ this holds parameter of the functional form.
+ For example in the case of Gaussians mu, sigma, and cut-off values are
+ relevant parameters.
diff --git a/contributed_definitions/NXfit_region.nxdl.xml b/contributed_definitions/NXfit_region.nxdl.xml
deleted file mode 100644
index ae018ff988..0000000000
--- a/contributed_definitions/NXfit_region.nxdl.xml
+++ /dev/null
@@ -1,60 +0,0 @@
-
-
-
-
-
- Description of region for peak fitting (i.e., in an NXpeak_model).
-
- Used for descibring a subpart of the abscissa (in 2D spectra) that is
- used for fitting.
-
-
-
- Human-readable label which specifies which concept/entity
- the region represents/identifies.
-
-
-
-
- Minimal value of the defined region.
-
-
-
-
- Minimal value of the defined region.
-
-
-
-
- Fitted background (functional, position, and intensities).
-
-
-
-
- In the case of an analytical description (or if peak_model is other) this
- collection holds parameter of (and eventually) the functional form.
- For example in the case of Gaussians mu, sigma, cut-off values,
- and background intensity are relevant parameter.
-
-
-
diff --git a/contributed_definitions/NXpeak.nxdl.xml b/contributed_definitions/NXpeak.nxdl.xml
index 5685e12599..996c7e9113 100644
--- a/contributed_definitions/NXpeak.nxdl.xml
+++ b/contributed_definitions/NXpeak.nxdl.xml
@@ -28,12 +28,13 @@
- Number of support points.
+ Number of discretization points at which the functional form of the peak
+ has been evaluated.
- Base class for describing spectral peaks, their functional form, and support values
+ Base class for describing a spectral peak, its functional form, and support values
(i.e., the discretization (points) at which the function has been evaluated).
@@ -68,7 +69,7 @@
- In the case of an empirical description of the peak and its shoulders,
+ In the case of an empirical description of the peak,
this array holds the position values for the independent variable.
@@ -77,66 +78,19 @@
- In the case of an empirical description of the peak and its shoulders,
+ In the case of an empirical description of the peak,
this array holds the intensity/count values at each position.
-<<<<<<< HEAD
-=======
-
-
- Width of a peak at a defined fraction of the peak height.
-
- Usually, this will be the Full Width at Half Maximum of the peak (FWHM).
- For asymmetric peaks, convenient measures of peak width are the half-widths of
- each side of the peak at half maximum intensity.
-
-
-
- Specification of the definition of `width`.
-
-
-
-
- Full Width at Half Maximum of the peak.
-
-
-
-
- Half Width at Half Maximum of the peak.
-
-
-
-
- For asymmetrical peaks, the half-widths of each side of the peak at
- half maximum intensity is given.
-
-
-
-
- For other peak width definitions.
-
-
-
-
-
-
-
- A formula to describe the line shape using set of parameters as entered
- by the `peak_parameters` fields.
-
-
-
->>>>>>> ef396415d (update lineshape in NXpeak)
In the case of an analytical description (or if description is other) this
- collection holds parameter of (and eventually) the functional form.
- For example in the case of Gaussians mu, sigma, cut-off values,
- and background intensity are relevant parameter.
+ collection holds parameter of the functional form.
+ For example in the case of Gaussians mu, sigma, and cut-off values are
+ relevant parameters.
diff --git a/contributed_definitions/NXpeak_model.nxdl.xml b/contributed_definitions/NXpeak_model.nxdl.xml
deleted file mode 100644
index 13e6828ad2..0000000000
--- a/contributed_definitions/NXpeak_model.nxdl.xml
+++ /dev/null
@@ -1,88 +0,0 @@
-
-
-
-
-
-
- The symbols used in the schema to specify e.g. dimensions of arrays.
-
-
-
- Number of peaks.
-
-
-
-
- Peak fitting of a one-dimensional spectrum.
-
-
-
- Subset of the abscisssa that is used for fitting.
- It is envisioned that regions are labeled as regions_0, regions_1, and so on.
-
-
-
-
- One spectral peak of the peak model.
- It is envisioned that peaks are labeled as peak_0, peak_1, and so on.
-
-
-
-
- Description of the function used for background subtraction.
-
-
-
-
- Resulting envelope of all NXpeak instances.
-
- Should have the same dimension as the `position` axes of the individual peaks.
-
-
-
-
- Figure-of-merit, e.g., :math:`\Chi^2`, or the standard deviation of the residuals,
- to determine the goodness of fit, i.e., how well the peak model fits the measured
- observations.
-
- This value (which is a single number) is oftenused to guide adjustments to the
- fitting parameters in the peak fitting process.
-
-
-
-
- Description of the method used to optimize the parameters during peak fitting.
- Examples:
- - least squares
- - non-linear least squares
- - Levenberg-Marquardt algorithm (damped least-squares)
- - linear regression
- - Bayesian linear regression
-
-
-
-
- Atomic concentration of each species defined by one peak in the peak model.
-
-
-
diff --git a/contributed_definitions/nyaml/NXfit.yaml b/contributed_definitions/nyaml/NXfit.yaml
new file mode 100644
index 0000000000..e0b3ddbdac
--- /dev/null
+++ b/contributed_definitions/nyaml/NXfit.yaml
@@ -0,0 +1,288 @@
+category: base
+doc: |
+ Description of a fit procedure.
+symbols:
+ doc: |
+ The symbols used in the schema to specify e.g. dimensions of arrays.
+ n_points: |
+ Number of discretization points inside the fitting region.
+type: group
+NXfit(NXobject):
+ label:
+ doc: |
+ Human-readable label for this fit procedure.
+ region(NX_NUMBER):
+ unit: NX_ANY
+ doc: |
+ Subset of the independent axis for this fit procedure.
+ dim: (n_points,)
+ peak_PEAK(NXpeak):
+ doc: |
+ One spectral peak of the peak model.
+ It is envisioned that peaks are labeled as peak_0, peak_1, and so on.
+ total_area(NX_NUMBER):
+ unit: NX_ANY
+ doc: |
+ Total area under the curve. (can also be used for the total area minus any
+ background values.)
+ relative_sensitivity_factor(NX_NUMBER):
+ unit: NX_UNITLESS
+ doc: |
+ Relative sensitivity for this peak, to be used for quantification in
+ an NXprocess.
+
+ As an example, in X-ray spectroscopy could depend on the energy scale3
+ (see position), the ionization cross section, and the element probed.
+ relative_area(NX_NUMBER):
+ unit: NX_ANY
+ doc: |
+ Relative area of this peak compared to other peaks.
+
+ The relative area can simply be derived by dividing the total_area by the
+ total area of all peaks or by a more complicated method (e.g., by
+ additionally dividing by the relative sensitivity factors). Details shall
+ be given in fitting_method
+ area_constraint(NXparameters):
+ doc: |
+ Constraint on the minimum and maximum area of this peak.
+ minimal_value(NX_NUMBER):
+ unit: NX_ANY
+ maximal_value(NX_NUMBER):
+ unit: NX_ANY
+ depends_on:
+ doc: |
+ Link to a peak the area constraint depends on.
+ width_constraint(NXparameters):
+ doc: |
+ Constraint on the minimum and maximum width of this peak.
+ minimal_value(NX_NUMBER):
+ unit: NX_ANY
+ maximal_value(NX_NUMBER):
+ unit: NX_ANY
+ depends_on:
+ doc: |
+ Link to a peak the width constraint depends on.
+ position_constraint(NXparameters):
+ doc: |
+ Constraint on the minimum and maximum position of this peak on the abscissa.
+ minimal_value(NX_NUMBER):
+ unit: NX_ANY
+ maximal_value(NX_NUMBER):
+ unit: NX_ANY
+ depends_on:
+ doc: |
+ Link to a peak the position constraint depends on.
+ background_BACKGROUND(NXfit_background):
+ doc: |
+ One fitted background (functional, position, and intensities) of the peak fit.
+ It is envisioned that peaks are labeled as background_0, background_1, and
+ so on.
+ fitting_method:
+ doc: |
+ Description of the method used to optimize the parameters during peak fitting.
+ Examples:
+ - least squares
+ - non-linear least squares
+ - Levenberg-Marquardt algorithm (damped least-squares)
+ - linear regression
+ - Bayesian linear regression
+ envelope(NX_NUMBER):
+ unit: NX_ANY
+ doc: |
+ Resulting envelope of all NXpeak instances.
+
+ Should have the same dimension as the `position` axes of the individual peaks.
+ dim: (n_points,)
+ figure_of_merit_METRIC(NX_NUMBER):
+ unit: NX_UNITLESS
+ doc: |
+ Figure-of-merit to determine the goodness of fit, i.e., how well the peak model
+ fits the measured observations.
+
+ This value (which is a single number) is oftenused to guide adjustments to the
+ fitting parameters in the peak fitting process.
+ \@metric:
+ doc: |
+ Metric used to determine the goodness of fit. Examples include:
+ - :math:`\Chi^2`, the standard deviation of the residuals
+ - reduced :math:`\Chi^2`:, :math:`\Chi^2`: per degree of freedom
+ - :math:`R^2`, the coefficient of determination
+ residual(NX_NUMBER):
+ unit: NX_UNITLESS
+ doc: |
+ Difference between the envelope and the data to be fitted.
+ dim: (n_points,)
+
+# ++++++++++++++++++++++++++++++++++ SHA HASH ++++++++++++++++++++++++++++++++++
+# 332a87f3d66a159e0249e86266ae53783011b8e4384bb6bcd21ebb8bdcdb09cb
+#
+#
+#
+#
+#
+#
+# The symbols used in the schema to specify e.g. dimensions of arrays.
+#
+#
+#
+# Number of discretization points inside the fitting region.
+#
+#
+#
+#
+# Description of a fit procedure.
+#
+#
+#
+# Human-readable label for this fit procedure.
+#
+#
+#
+#
+# Subset of the independent axis for this fit procedure.
+#
+#
+#
+#
+#
+#
+#
+# One spectral peak of the peak model.
+# It is envisioned that peaks are labeled as peak_0, peak_1, and so on.
+#
+#
+#
+# Total area under the curve. (can also be used for the total area minus any
+# background values.)
+#
+#
+#
+#
+# Relative sensitivity for this peak, to be used for quantification in
+# an NXprocess.
+#
+# As an example, in X-ray spectroscopy could depend on the energy scale3
+# (see position), the ionization cross section, and the element probed.
+#
+#
+#
+#
+# Relative area of this peak compared to other peaks.
+#
+# The relative area can simply be derived by dividing the total_area by the
+# total area of all peaks or by a more complicated method (e.g., by
+# additionally dividing by the relative sensitivity factors). Details shall
+# be given in fitting_method
+#
+#
+#
+#
+# Constraint on the minimum and maximum area of this peak.
+#
+#
+#
+#
+#
+# Link to a peak the area constraint depends on.
+#
+#
+#
+#
+#
+# Constraint on the minimum and maximum width of this peak.
+#
+#
+#
+#
+#
+# Link to a peak the width constraint depends on.
+#
+#
+#
+#
+#
+# Constraint on the minimum and maximum position of this peak on the abscissa.
+#
+#
+#
+#
+#
+# Link to a peak the position constraint depends on.
+#
+#
+#
+#
+#
+#
+# One fitted background (functional, position, and intensities) of the peak fit.
+# It is envisioned that peaks are labeled as background_0, background_1, and
+# so on.
+#
+#
+#
+#
+# Description of the method used to optimize the parameters during peak fitting.
+# Examples:
+# - least squares
+# - non-linear least squares
+# - Levenberg-Marquardt algorithm (damped least-squares)
+# - linear regression
+# - Bayesian linear regression
+#
+#
+#
+#
+# Resulting envelope of all NXpeak instances.
+#
+# Should have the same dimension as the `position` axes of the individual peaks.
+#
+#
+#
+#
+#
+#
+#
+# Figure-of-merit to determine the goodness of fit, i.e., how well the peak model
+# fits the measured observations.
+#
+# This value (which is a single number) is oftenused to guide adjustments to the
+# fitting parameters in the peak fitting process.
+#
+#
+#
+# Metric used to determine the goodness of fit. Examples include:
+# - :math:`\Chi^2`, the standard deviation of the residuals
+# - reduced :math:`\Chi^2`:, :math:`\Chi^2`: per degree of freedom
+# - :math:`R^2`, the coefficient of determination
+#
+#
+#
+#
+#
+# Difference between the envelope and the data to be fitted.
+#
+#
+#
+#
+#
+#
diff --git a/contributed_definitions/nyaml/NXbackground.yaml b/contributed_definitions/nyaml/NXfit_background.yaml
similarity index 80%
rename from contributed_definitions/nyaml/NXbackground.yaml
rename to contributed_definitions/nyaml/NXfit_background.yaml
index d9edb4c285..1967cce4c2 100644
--- a/contributed_definitions/nyaml/NXbackground.yaml
+++ b/contributed_definitions/nyaml/NXfit_background.yaml
@@ -5,9 +5,10 @@ symbols:
doc: |
The symbols used in the schema to specify e.g. dimensions of arrays.
n_support: |
- Number of support points
+ Number of discretization points at which the functional form of the
+ background has been evaluated.
type: group
-NXbackground(NXobject):
+NXfit_background(NXobject):
label(NX_CHAR):
doc: |
Human-readable label which specifies which concept/entity
@@ -19,7 +20,7 @@ NXbackground(NXobject):
intensity/counts as a function of an independent variable.
Relevant details of the functional form shall be described through
- NXcollection.
+ background_parameters.
position(NX_NUMBER):
unit: NX_ANY
doc: |
@@ -32,15 +33,15 @@ NXbackground(NXobject):
In the case of an empirical description of the background,
this array holds the intensity/count values at each position.
dim: (n_support,)
- (NXcollection):
+ background_parameters(NXparameters):
doc: |
- In the case of an analytical description (or if description is other) this
- collection holds parameter of (and eventually) the functional form.
- For example in the case of Gaussians mu, sigma, cut-off values,
- and background intensity are relevant parameter.
+ In the case of an analytical description (or if description is other),
+ this holds parameter of the functional form.
+ For example in the case of Gaussians mu, sigma, and cut-off values are
+ relevant parameters.
# ++++++++++++++++++++++++++++++++++ SHA HASH ++++++++++++++++++++++++++++++++++
-# b830bece7ddf1d02e6d3a4e72574540c6c75a1ccd34aaec9cec2a6a0d7e1215e
+# ab225b7c9634039e078d5ba44500c59f05958c63b16b4e3beb5c171d47fe65b1
#
#
#
-#
+#
#
#
# The symbols used in the schema to specify e.g. dimensions of arrays.
#
#
#
-# Number of support points
+# Number of discretization points at which the functional form of the
+# background has been evaluated.
#
#
#
@@ -91,7 +93,7 @@ NXbackground(NXobject):
# intensity/counts as a function of an independent variable.
#
# Relevant details of the functional form shall be described through
-# NXcollection.
+# background_parameters.
#
#
#
@@ -112,12 +114,12 @@ NXbackground(NXobject):
#
#
#
-#
+#
#
-# In the case of an analytical description (or if description is other) this
-# collection holds parameter of (and eventually) the functional form.
-# For example in the case of Gaussians mu, sigma, cut-off values,
-# and background intensity are relevant parameter.
+# In the case of an analytical description (or if description is other),
+# this holds parameter of the functional form.
+# For example in the case of Gaussians mu, sigma, and cut-off values are
+# relevant parameters.
#
#
#
diff --git a/contributed_definitions/nyaml/NXfit_region.yaml b/contributed_definitions/nyaml/NXfit_region.yaml
deleted file mode 100644
index 303854e3e6..0000000000
--- a/contributed_definitions/nyaml/NXfit_region.yaml
+++ /dev/null
@@ -1,92 +0,0 @@
-category: base
-doc: |
- Description of region for peak fitting (i.e., in an NXpeak_model).
-
- Used for descibring a subpart of the abscissa (in 2D spectra) that is
- used for fitting.
-type: group
-NXfit_region(NXobject):
- label(NX_CHAR):
- doc: |
- Human-readable label which specifies which concept/entity
- the region represents/identifies.
- start(NX_NUMBER):
- unit: NX_ANY
- doc: |
- Minimal value of the defined region.
- stop(NX_NUMBER):
- unit: NX_ANY
- doc: |
- Minimal value of the defined region.
- (NXbackground):
- doc: |
- Fitted background (functional, position, and intensities).
- (NXcollection):
- doc: |
- In the case of an analytical description (or if peak_model is other) this
- collection holds parameter of (and eventually) the functional form.
- For example in the case of Gaussians mu, sigma, cut-off values,
- and background intensity are relevant parameter.
-
-# ++++++++++++++++++++++++++++++++++ SHA HASH ++++++++++++++++++++++++++++++++++
-# 40645fad714a7390543883c71b1c2d27ef4cf350cb98f2011197d9135249715c
-#
-#
-#
-#
-#
-# Description of region for peak fitting (i.e., in an NXpeak_model).
-#
-# Used for descibring a subpart of the abscissa (in 2D spectra) that is
-# used for fitting.
-#
-#
-#
-# Human-readable label which specifies which concept/entity
-# the region represents/identifies.
-#
-#
-#
-#
-# Minimal value of the defined region.
-#
-#
-#
-#
-# Minimal value of the defined region.
-#
-#
-#
-#
-# Fitted background (functional, position, and intensities).
-#
-#
-#
-#
-# In the case of an analytical description (or if peak_model is other) this
-# collection holds parameter of (and eventually) the functional form.
-# For example in the case of Gaussians mu, sigma, cut-off values,
-# and background intensity are relevant parameter.
-#
-#
-#
diff --git a/contributed_definitions/nyaml/NXpeak.yaml b/contributed_definitions/nyaml/NXpeak.yaml
index 7d13999811..b9f76bc5e2 100644
--- a/contributed_definitions/nyaml/NXpeak.yaml
+++ b/contributed_definitions/nyaml/NXpeak.yaml
@@ -1,12 +1,13 @@
category: base
doc: |
- Base class for describing spectral peaks, their functional form, and support values
+ Base class for describing a spectral peak, its functional form, and support values
(i.e., the discretization (points) at which the function has been evaluated).
symbols:
doc: |
The symbols used in the schema to specify e.g. dimensions of arrays.
n_support: |
- Number of support points.
+ Number of discretization points at which the functional form of the peak
+ has been evaluated.
type: group
NXpeak(NXobject):
label:
@@ -25,13 +26,13 @@ NXpeak(NXobject):
enumeration: [empirical, gaussian, lorentzian, voigt, other]
position(NX_NUMBER):
doc: |
- In the case of an empirical description of the peak and its shoulders,
+ In the case of an empirical description of the peak,
this array holds the position values for the independent variable.
unit: NX_ANY
dim: (n_support,)
intensity(NX_NUMBER):
doc: |
- In the case of an empirical description of the peak and its shoulders,
+ In the case of an empirical description of the peak,
this array holds the intensity/count values at each position.
unit: NX_ANY
dim: (n_support,)
diff --git a/contributed_definitions/nyaml/NXpeak_model.yaml b/contributed_definitions/nyaml/NXpeak_model.yaml
deleted file mode 100644
index 1ffaa60e76..0000000000
--- a/contributed_definitions/nyaml/NXpeak_model.yaml
+++ /dev/null
@@ -1,140 +0,0 @@
-category: base
-doc: |
- Peak fitting of a one-dimensional spectrum.
-symbols:
- doc: |
- The symbols used in the schema to specify e.g. dimensions of arrays.
- n_peaks: |
- Number of peaks.
-type: group
-NXpeak_model(NXprocess):
- region_REGION(NXfit_region):
- doc: |
- Subset of the abscisssa that is used for fitting.
- It is envisioned that regions are labeled as regions_0, regions_1, and so on.
- peak_PEAK(NXpeak):
- doc: |
- One spectral peak of the peak model.
- It is envisioned that peaks are labeled as peak_0, peak_1, and so on.
- background(NX_background):
- doc: |
- Description of the function used for background subtraction.
- envelope(NX_NUMBER):
- unit: NX_ANY
- doc: |
- Resulting envelope of all NXpeak instances.
-
- Should have the same dimension as the `position` axes of the individual peaks.
- figure_of_merit(NX_NUMBER):
- unit: NX_UNITLESS
- doc: |
- Figure-of-merit, e.g., :math:`\Chi^2`, or the standard deviation of the residuals,
- to determine the goodness of fit, i.e., how well the peak model fits the measured
- observations.
-
- This value (which is a single number) is oftenused to guide adjustments to the
- fitting parameters in the peak fitting process.
- fitting_method:
- doc: |
- Description of the method used to optimize the parameters during peak fitting.
- Examples:
- - least squares
- - non-linear least squares
- - Levenberg-Marquardt algorithm (damped least-squares)
- - linear regression
- - Bayesian linear regression
- relative_concentration(NX_FLOAT):
- unit: NX_ANY
- doc: |
- Atomic concentration of each species defined by one peak in the peak model.
-
-# ++++++++++++++++++++++++++++++++++ SHA HASH ++++++++++++++++++++++++++++++++++
-# ac6b6234e775a297a41f680a8ed708950292beff8778e4db26602578ecae71f0
-#
-#
-#
-#
-#
-#
-# The symbols used in the schema to specify e.g. dimensions of arrays.
-#
-#
-#
-# Number of peaks.
-#
-#
-#
-#
-# Peak fitting of a one-dimensional spectrum.
-#
-#
-#
-# Subset of the abscisssa that is used for fitting.
-# It is envisioned that regions are labeled as regions_0, regions_1, and so on.
-#
-#
-#
-#
-# One spectral peak of the peak model.
-# It is envisioned that peaks are labeled as peak_0, peak_1, and so on.
-#
-#
-#
-#
-# Description of the function used for background subtraction.
-#
-#
-#
-#
-# Resulting envelope of all NXpeak instances.
-#
-# Should have the same dimension as the `position` axes of the individual peaks.
-#
-#
-#
-#
-# Figure-of-merit, e.g., :math:`\Chi^2`, or the standard deviation of the residuals,
-# to determine the goodness of fit, i.e., how well the peak model fits the measured
-# observations.
-#
-# This value (which is a single number) is oftenused to guide adjustments to the
-# fitting parameters in the peak fitting process.
-#
-#
-#
-#
-# Description of the method used to optimize the parameters during peak fitting.
-# Examples:
-# - least squares
-# - non-linear least squares
-# - Levenberg-Marquardt algorithm (damped least-squares)
-# - linear regression
-# - Bayesian linear regression
-#
-#
-#
-#
-# Atomic concentration of each species defined by one peak in the peak model.
-#
-#
-#
From ebae306155c175b56e0621394b64ef7e83e4150e Mon Sep 17 00:00:00 2001
From: Lukas Pielsticker <50139597+lukaspie@users.noreply.github.com>
Date: Thu, 15 Feb 2024 15:05:37 +0100
Subject: [PATCH 30/67] change to NXcoordinate_system_set, use NXfit in NXxps
---
contributed_definitions/NXxps.nxdl.xml | 74 +++++++
contributed_definitions/nyaml/NXmpes.yaml | 40 ++++
contributed_definitions/nyaml/NXxps.yaml | 258 ++++++++--------------
3 files changed, 202 insertions(+), 170 deletions(-)
diff --git a/contributed_definitions/NXxps.nxdl.xml b/contributed_definitions/NXxps.nxdl.xml
index 0360ff5934..c159a60fa2 100644
--- a/contributed_definitions/NXxps.nxdl.xml
+++ b/contributed_definitions/NXxps.nxdl.xml
@@ -404,7 +404,11 @@
>>>>>>> 7178a95ca (remove NXtransformations from NXcoordinate_system)
+<<<<<<< HEAD
+=======
+
+>>>>>>> 5e7c2dec7 (change to NXcoordinate_system_set, use NXfit in NXxps)
Peak model for XPS fitting. Each `NXfit` instance shall be used for the description of
_one_ peak fit in _one_ XPS region. As an example, this could be used to describe the
@@ -414,17 +418,66 @@
.. _3.29: https://www.iso.org/obp/ui/en/#iso:std:iso:18115:-1:ed-3:v1:en:term:3.29
+<<<<<<< HEAD
Input data and results of the fit.
+=======
+
+
+ Description of one peak fit. This is meant to be used for a peak fit in
+ _one_ XPS region. As an eexample, this could be used to describe the
+ fitting of one measured C 1s spectrum.
+
+
+
+
+
+
+
+
+
+ Intensity/count values at each energy in the position field.
+
+ This concept is related to term `3.15`_ of the ISO 18115-1:2023 standard.
+
+ .. _3.15: https://www.iso.org/obp/ui/en/#iso:std:iso:18115:-1:ed-3:v1:en:term:3.15
+
+
+
+
+ Width of a peak at a defined fraction of the peak height.
+
+ Usually, this will be the Full Width at Half Maximum of the peak (FWHM).
+ For asymmetric peaks, convenient measures of peak width are the half-widths of
+ each side of the peak at half maximum intensity.
+
+ This concept is related to term `3.28`_ of the ISO 18115-1:2023 standard.
+
+ .. _3.28: https://www.iso.org/obp/ui/en/#iso:std:iso:18115:-1:ed-3:v1:en:term:3.28
+
+
+
+
+ Total area under the peak after background removal.
+
+ This concept is related to term `3.16`_ of the ISO 18115-1:2023 standard.
+
+ .. _3.16: https://www.iso.org/obp/ui/en/#iso:std:iso:18115:-1:ed-3:v1:en:term:3.16
+
+
+
+
+>>>>>>> 5e7c2dec7 (change to NXcoordinate_system_set, use NXfit in NXxps)
Dependent variable for this fit procedure.
This could be a link to entry/data/data.
+<<<<<<< HEAD
@@ -507,6 +560,9 @@
+=======
+
+>>>>>>> 5e7c2dec7 (change to NXcoordinate_system_set, use NXfit in NXxps)
@@ -539,9 +595,27 @@
+
+
+<<<<<<< HEAD
+=======
+
+
+
+
+
+
+
+
+ Atomic concentration of each species defined by one peak in the peak model.
+ This should be an array with the indices pointing to the individual peaks
+ (i.e, peak_0, peak_1, etc.)
+
+
+>>>>>>> 5e7c2dec7 (change to NXcoordinate_system_set, use NXfit in NXxps)
diff --git a/contributed_definitions/nyaml/NXmpes.yaml b/contributed_definitions/nyaml/NXmpes.yaml
index 7caa8b1460..9f8366f444 100644
--- a/contributed_definitions/nyaml/NXmpes.yaml
+++ b/contributed_definitions/nyaml/NXmpes.yaml
@@ -791,6 +791,15 @@ NXmpes(NXobject):
For example:
@energy_depends: 'entry/process/energy_calibration'
+<<<<<<< HEAD
+=======
+
+# ++++++++++++++++++++++++++++++++++ SHA HASH ++++++++++++++++++++++++++++++++++
+<<<<<<< HEAD
+<<<<<<< HEAD
+# 7f45ab08c78a105a15e2c6f5ddbcdcab4002929bf8d19e8ec2987bd507525680
+=======
+>>>>>>> 5e7c2dec7 (change to NXcoordinate_system_set, use NXfit in NXxps)
doc: |
The energy can be either stored as kinetic or as binding energy.
enumeration:
@@ -833,7 +842,13 @@ NXmpes(NXobject):
=======
# 7227f59755bd6f9d2f94518a5c47562f5f21dc4a1ba1c47a1633acb2a08e0b91
>>>>>>> 8c42628fe (remove NXtransformations from NXcoordinate_system)
+<<<<<<< HEAD
>>>>>>> 7178a95ca (remove NXtransformations from NXcoordinate_system)
+=======
+=======
+# e3d5958221798a09e18e91f457264204729d056cde70504cb02ea4b50b32ac1b
+>>>>>>> 05529f919 (change to NXcoordinate_system_set, use NXfit in NXxps)
+>>>>>>> 5e7c2dec7 (change to NXcoordinate_system_set, use NXfit in NXxps)
#
#
#
+#
+<<<<<<< HEAD
+# Description of coordinate system specific to the setup and the measurement
+# geometry.
+>>>>>>> 8c42628fe (remove NXtransformations from NXcoordinate_system)
+=======
+# Description of one or more coordinate systems that are specific to the setup
+# and the measurement geometry.
+>>>>>>> 05529f919 (change to NXcoordinate_system_set, use NXfit in NXxps)
+>>>>>>> 5e7c2dec7 (change to NXcoordinate_system_set, use NXfit in NXxps)
#
#
#
diff --git a/contributed_definitions/nyaml/NXxps.yaml b/contributed_definitions/nyaml/NXxps.yaml
index c15d457deb..fc6619c16a 100644
--- a/contributed_definitions/nyaml/NXxps.yaml
+++ b/contributed_definitions/nyaml/NXxps.yaml
@@ -242,52 +242,30 @@ NXxps(NXmpes):
spec: ISO 18115-1:2023
term: 3.29
url: https://www.iso.org/obp/ui/en/#iso:std:iso:18115:-1:ed-3:v1:en:term:3.29
- label:
- data(NXdata):
+ (NXfit):
doc: |
- Input data and results of the fit.
- input_dependent(NX_NUMBER):
- unit: NX_ANY
- doc: |
- Dependent variable for this fit procedure.
-
- This could be a link to entry/data/data.
- input_independent(NX_NUMBER):
- unit: NX_ANY
- doc: |
- Independent variable for this fit procedure.
-
- This could be a link to entry/data/energy.
- envelope(NX_NUMBER):
- residual(NX_NUMBER):
- exists: recommended
- peakPEAK(NXpeak):
+ Description of one peak fit. This is meant to be used for a peak fit in
+ _one_ XPS region. As an eexample, this could be used to describe the
+ fitting of one measured C 1s spectrum.
label:
- data(NXdata):
- position(NX_NUMBER):
+ region(NX_NUMBER):
+ unit: NX_ENERGY
+ peak_PEAK(NXpeak):
+ label:
+ lineshape:
+ position:
unit: NX_ENERGY
- doc: |
- This could be a link to entry/data/energy.
- intensity(NX_NUMBER):
+ intensity:
doc:
- |
- Intensity values of the fitted function at each energy in the position field.
+ Intensity/count values at each energy in the position field.
- |
xref:
spec: ISO 18115-1:2023
term: 3.15
url: https://www.iso.org/obp/ui/en/#iso:std:iso:18115:-1:ed-3:v1:en:term:3.15
- function(NXfit_function):
- exists: recommended
- description:
- formula:
+ width(NX_NUMBER):
exists: recommended
- area(NXfit_parameter):
- exists: optional
- doc: |
- Area of the peak.
- width(NXfit_parameter):
- exists: optional
doc:
- |
Width of a peak at a defined fraction of the peak height.
@@ -300,41 +278,27 @@ NXxps(NXmpes):
spec: ISO 18115-1:2023
term: 3.28
url: https://www.iso.org/obp/ui/en/#iso:std:iso:18115:-1:ed-3:v1:en:term:3.28
- value:
- unit: NX_ENERGY
- position(NXfit_parameter):
- exists: optional
- doc: |
- Position of the peak on the energy axis.
- value:
- unit: NX_ENERGY
- total_area:
- exists: recommended
+ total_area:
+ exists: recommended
+ doc:
+ - |
+ Total area under the peak after background removal.
+ - |
+ xref:
+ spec: ISO 18115-1:2023
+ term: 3.16
+ url: https://www.iso.org/obp/ui/en/#iso:std:iso:18115:-1:ed-3:v1:en:term:3.16
+ background_BACKGROUND(NXfit_background):
doc:
- |
Total area under the peak after background removal.
- |
xref:
spec: ISO 18115-1:2023
- term: 3.16
- url: https://www.iso.org/obp/ui/en/#iso:std:iso:18115:-1:ed-3:v1:en:term:3.16
- backgroundBACKGROUND(NXfit_background):
- doc:
- - |
- Functional form of the fitted XPS background.
- - |
- xref:
- spec: ISO 18115-1:2023
- term: 3.21
- url: https://www.iso.org/obp/ui/en/#iso:std:iso:18115:-1:ed-3:v1:en:term:3.21
- label:
- exists: recommended
- data(NXdata):
- position(NX_NUMBER):
- unit: NX_ENERGY
- intensity(NX_NUMBER):
- function(NXfit_function):
- exists: recommended
+ term: 3.21
+ url: https://www.iso.org/obp/ui/en/#iso:std:iso:18115:-1:ed-3:v1:en:term:3.21
+ label:
+ exists: recommended
description:
enumeration:
linear:
@@ -356,34 +320,26 @@ NXxps(NXmpes):
other:
doc: |
In case none of the enumeration items apply, description should be _other_
- and the functional form of the background should be given by the `formula`
- field.
- formula:
- exists: recommended
- global_fit_function(NXfit_function):
- exists: recommended
- description:
- exists: recommended
- formula:
+ and the functional form of the background should be given by NXcollection.
+ position:
+ unit: NX_ENERGY
+ intensity:
+ fitting_method:
exists: recommended
- error_function(NXfit_function):
- exists: recommended
- description:
+ envelope(NX_NUMBER):
exists: recommended
- formula:
+ figure_of_merit_METRIC(NX_NUMBER):
exists: recommended
- figure_of_meritMETRIC(NX_NUMBER):
- exists: recommended
- \@metric:
- relative_concentration(NX_FLOAT):
- unit: NX_ANY
- doc: |
- Atomic concentration of each species defined by one peak in the peak model.
- This should be an array with the indices pointing to the individual peaks
- (i.e, peak_0, peak_1, etc.)
+ \@metric:
+ relative_concentration(NX_FLOAT):
+ unit: NX_ANY
+ doc: |
+ Atomic concentration of each species defined by one peak in the peak model.
+ This should be an array with the indices pointing to the individual peaks
+ (i.e, peak_0, peak_1, etc.)
# ++++++++++++++++++++++++++++++++++ SHA HASH ++++++++++++++++++++++++++++++++++
-# 04421486bc5dffb01865fb8e056d77e5f5157304a3bc3ab9024c8ad160fe21e6
+# 2014f7027d3a4cee74004585b9831056092d2b06fbfb85b4d46641c5d7cf6390
#
#
#
+
+
+
+
+ The number of repetitions for the repeated parameters.
+
+
+
+
+ This describes a fit function to be used inside an NXfit instance.
+
+
+
+ This should be a python parsable function.
+ Here we should provide which keywords are available
+ and a BNF of valid grammar.
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/contributed_definitions/NXfit_repeated_parameter.nxdl.xml b/contributed_definitions/NXfit_repeated_parameter.nxdl.xml
new file mode 100644
index 0000000000..8debfa37ae
--- /dev/null
+++ b/contributed_definitions/NXfit_repeated_parameter.nxdl.xml
@@ -0,0 +1,66 @@
+
+
+
+
+
+
+
+ The number of parameter repetitions.
+
+
+
+
+ A repeated parameter for a fit function.
+ This would typically be the independent variable in a fit.
+
+
+
+ The name of the parameter.
+
+
+
+
+ A description of what this parameter represents.
+
+
+
+
+ A unit array associating a unit with each parameter.
+ The first element should be equal to values/@unit.
+ The values should be SI interpretable standard units
+ with common prefixes (e.g. mikro, nano etc.) or their
+ short-hand notation (e.g. nm, mm, kHz etc.).
+
+
+
+
+
+
+
+ The value of the parameter.
+
+
+
+
+
+
diff --git a/contributed_definitions/NXfit_single_parameter.nxdl.xml b/contributed_definitions/NXfit_single_parameter.nxdl.xml
new file mode 100644
index 0000000000..3d247ccdc1
--- /dev/null
+++ b/contributed_definitions/NXfit_single_parameter.nxdl.xml
@@ -0,0 +1,55 @@
+
+
+
+
+
+ A single parameter for a fit function.
+ This would typically be a variable that
+ is optimized in a fit.
+
+
+
+ The name of the parameter.
+
+
+
+
+ A description of what this parameter represents.
+
+
+
+
+ The value of the parameter.
+
+
+
+
+ The minimal value of the parameter.
+
+
+
+
+ The maximal value of the parameter.
+
+
+
diff --git a/contributed_definitions/nyaml/NXfit_function.yaml b/contributed_definitions/nyaml/NXfit_function.yaml
new file mode 100644
index 0000000000..a7d2454ca2
--- /dev/null
+++ b/contributed_definitions/nyaml/NXfit_function.yaml
@@ -0,0 +1,81 @@
+category: base
+doc: |
+ This describes a fit function to be used inside an NXfit instance.
+symbols:
+ n_repetitions: |
+ The number of repetitions for the repeated parameters.
+type: group
+NXfitfunction(NXobject):
+ formula(NX_CHAR):
+ doc: |
+ This should be a python parsable function.
+ Here we should provide which keywords are available
+ and a BNF of valid grammar.
+ (NXfit_single_parameter):
+ (NXfit_repeated_parameter):
+ parameter_units:
+ dimensions:
+ rank: 1
+ dim: [[1, n_repetitions]]
+ values(NX_NUMBER):
+ dimensions:
+ rank: 1
+ dim: [[1, n_repetitions]]
+
+# ++++++++++++++++++++++++++++++++++ SHA HASH ++++++++++++++++++++++++++++++++++
+# d83f7d658d8a45d2dc6c4c5cab91a69ab29f7b64eabebefed739a0bc5ffe4570
+#
+#
+#
+#
+#
+#
+#
+# The number of repetitions for the repeated parameters.
+#
+#
+#
+#
+# This describes a fit function to be used inside an NXfit instance.
+#
+#
+#
+# This should be a python parsable function.
+# Here we should provide which keywords are available
+# and a BNF of valid grammar.
+#
+#
+#
+#
+#
+#
+#
+#
+#
+#
+#
+#
+#
+#
+#
+#
diff --git a/contributed_definitions/nyaml/NXfit_repeated_parameter.yaml b/contributed_definitions/nyaml/NXfit_repeated_parameter.yaml
new file mode 100644
index 0000000000..2a931756b5
--- /dev/null
+++ b/contributed_definitions/nyaml/NXfit_repeated_parameter.yaml
@@ -0,0 +1,101 @@
+category: base
+doc: |
+ A repeated parameter for a fit function.
+ This would typically be the independent variable in a fit.
+symbols:
+ n_repetitions: |
+ The number of parameter repetitions.
+type: group
+NXfit_repeated_parameter(NXobject):
+ name(NX_CHAR):
+ doc: |
+ The name of the parameter.
+ description(NX_CHAR):
+ doc: |
+ A description of what this parameter represents.
+ parameter_units(NX_CHAR):
+ doc: |
+ A unit array associating a unit with each parameter.
+ The first element should be equal to values/@unit.
+ The values should be SI interpretable standard units
+ with common prefixes (e.g. mikro, nano etc.) or their
+ short-hand notation (e.g. nm, mm, kHz etc.).
+ dimensions:
+ rank: 1
+ dim: [[1, n_repetitions]]
+ values(NX_NUMBER):
+ unit: NX_ANY
+ doc: |
+ The value of the parameter.
+ dimensions:
+ rank: 1
+ dim: [[1, n_repetitions]]
+
+# ++++++++++++++++++++++++++++++++++ SHA HASH ++++++++++++++++++++++++++++++++++
+# 31c7e1de12aaeb0badc37be7cd26889bdd924167c58e591c8fd9aea2d6419dd3
+#
+#
+#
+#
+#
+#
+#
+# The number of parameter repetitions.
+#
+#
+#
+#
+# A repeated parameter for a fit function.
+# This would typically be the independent variable in a fit.
+#
+#
+#
+# The name of the parameter.
+#
+#
+#
+#
+# A description of what this parameter represents.
+#
+#
+#
+#
+# A unit array associating a unit with each parameter.
+# The first element should be equal to values/@unit.
+# The values should be SI interpretable standard units
+# with common prefixes (e.g. mikro, nano etc.) or their
+# short-hand notation (e.g. nm, mm, kHz etc.).
+#
+#
+#
+#
+#
+#
+#
+# The value of the parameter.
+#
+#
+#
+#
+#
+#
diff --git a/contributed_definitions/nyaml/NXfit_single_parameter.yaml b/contributed_definitions/nyaml/NXfit_single_parameter.yaml
new file mode 100644
index 0000000000..d7370eaf68
--- /dev/null
+++ b/contributed_definitions/nyaml/NXfit_single_parameter.yaml
@@ -0,0 +1,83 @@
+category: base
+doc: |
+ A single parameter for a fit function.
+ This would typically be a variable that
+ is optimized in a fit.
+type: group
+NXfit_single_parameter(NXobject):
+ name(NX_CHAR):
+ doc: |
+ The name of the parameter.
+ description(NX_CHAR):
+ doc: |
+ A description of what this parameter represents.
+ value(NX_NUMBER):
+ unit: NX_ANY
+ doc: |
+ The value of the parameter.
+ min_value(NX_NUMBER):
+ unit: NX_ANY
+ doc: |
+ The minimal value of the parameter.
+ max_value(NX_NUMBER):
+ unit: NX_ANY
+ doc: |
+ The maximal value of the parameter.
+
+# ++++++++++++++++++++++++++++++++++ SHA HASH ++++++++++++++++++++++++++++++++++
+# 8b3465bf8c95d77f2873598fbfb127a3d896568739ac89c8e84934bd851f1b81
+#
+#
+#
+#
+#
+# A single parameter for a fit function.
+# This would typically be a variable that
+# is optimized in a fit.
+#
+#
+#
+# The name of the parameter.
+#
+#
+#
+#
+# A description of what this parameter represents.
+#
+#
+#
+#
+# The value of the parameter.
+#
+#
+#
+#
+# The minimal value of the parameter.
+#
+#
+#
+#
+# The maximal value of the parameter.
+#
+#
+#
From 9bc7da83516778fdd2526fdd23e1481db14f8f8c Mon Sep 17 00:00:00 2001
From: Lukas Pielsticker <50139597+lukaspie@users.noreply.github.com>
Date: Thu, 15 Feb 2024 17:23:21 +0100
Subject: [PATCH 32/67] use NXfit_function for peaks and backgrounds
---
.../NXfit_background.nxdl.xml | 59 +++-----
.../NXfit_function.nxdl.xml | 7 +-
contributed_definitions/NXpeak.nxdl.xml | 82 +++++------
.../nyaml/NXfit_background.yaml | 103 +++++--------
.../nyaml/NXfit_function.yaml | 22 +--
contributed_definitions/nyaml/NXpeak.yaml | 138 ++++++++++++++----
6 files changed, 227 insertions(+), 184 deletions(-)
diff --git a/contributed_definitions/NXfit_background.nxdl.xml b/contributed_definitions/NXfit_background.nxdl.xml
index 0b2e73f5cb..edc1dc6475 100644
--- a/contributed_definitions/NXfit_background.nxdl.xml
+++ b/contributed_definitions/NXfit_background.nxdl.xml
@@ -26,15 +26,15 @@
The symbols used in the schema to specify e.g. dimensions of arrays.
-
+
- Number of discretization points at which the functional form of the
+ Number of discretization points at which the functional form of the
background has been evaluated.
- Description of background for an NXpeak_model.
+ Description of the background for an NXfit model.
@@ -42,40 +42,27 @@
the background represents/identifies.
-
-
- Is the background described analytically via a functional form
- or is it empirically defined via measured/reported
- intensity/counts as a function of an independent variable.
-
- Relevant details of the functional form shall be described through
- background_parameters.
-
-
-
-
- In the case of an empirical description of the background,
- this array holds the position values for the independent variable.
-
-
-
-
-
-
-
- In the case of an empirical description of the background,
- this array holds the intensity/count values at each position.
-
-
-
-
-
-
+
+
+
+ This axis holds the position values for the independent variable.
+
+
+
+
+
+
+
+ This array holds the intensity/count values at each position.
+
+
+
+
+
+
+
- In the case of an analytical description (or if description is other),
- this holds parameter of the functional form.
- For example in the case of Gaussians mu, sigma, and cut-off values are
- relevant parameters.
+ The functional form of the background.
diff --git a/contributed_definitions/NXfit_function.nxdl.xml b/contributed_definitions/NXfit_function.nxdl.xml
index 66b357c437..b91bef7119 100644
--- a/contributed_definitions/NXfit_function.nxdl.xml
+++ b/contributed_definitions/NXfit_function.nxdl.xml
@@ -21,7 +21,7 @@
#
# For further information, see http://www.nexusformat.org
-->
-
+
@@ -32,6 +32,11 @@
This describes a fit function to be used inside an NXfit instance.
+
+
+ Description of this fit function.
+
+
This should be a python parsable function.
diff --git a/contributed_definitions/NXpeak.nxdl.xml b/contributed_definitions/NXpeak.nxdl.xml
index 996c7e9113..9b905d834a 100644
--- a/contributed_definitions/NXpeak.nxdl.xml
+++ b/contributed_definitions/NXpeak.nxdl.xml
@@ -26,7 +26,7 @@
The symbols used in the schema to specify e.g. dimensions of arrays.
-
+
Number of discretization points at which the functional form of the peak
has been evaluated.
@@ -43,54 +43,40 @@
the peak represents/identifies.
-
-
- Is the peak described analytically via a functional form
- or is it empirically defined via measured/reported
- intensity/counts as a function of an independent variable?
-
- If the functional form is not empirical or Gaussians, users
- should enter other for the description and add relevant details
- in the NXcollection.
-
-
-
-
-
-
-
-
-
-
-
- Human-readable descritpion of the lineshape used for the peak if it does
- not fit into the enumeration given in `lineshape`.
-
-
-
-
- In the case of an empirical description of the peak,
- this array holds the position values for the independent variable.
-
-
-
-
-
-
-
- In the case of an empirical description of the peak,
- this array holds the intensity/count values at each position.
-
-
-
-
-
-
+
+
+
+ This axis holds the position values for the independent variable.
+
+
+
+
+
+
+
+ This array holds the intensity/count values at each position.
+
+
+
+
+
+
+
- In the case of an analytical description (or if description is other) this
- collection holds parameter of the functional form.
- For example in the case of Gaussians mu, sigma, and cut-off values are
- relevant parameters.
+ The functional form of the peak. This could be a Gaussian, Lorentzian,
+ Voigt, etc.
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/contributed_definitions/nyaml/NXfit_background.yaml b/contributed_definitions/nyaml/NXfit_background.yaml
index 1967cce4c2..e0d1695984 100644
--- a/contributed_definitions/nyaml/NXfit_background.yaml
+++ b/contributed_definitions/nyaml/NXfit_background.yaml
@@ -1,10 +1,10 @@
category: base
doc: |
- Description of background for an NXpeak_model.
+ Description of the background for an NXfit model.
symbols:
doc: |
The symbols used in the schema to specify e.g. dimensions of arrays.
- n_support: |
+ n_values: |
Number of discretization points at which the functional form of the
background has been evaluated.
type: group
@@ -13,35 +13,23 @@ NXfit_background(NXobject):
doc: |
Human-readable label which specifies which concept/entity
the background represents/identifies.
- description(NX_CHAR):
+ data(NXdata):
+ position(NX_NUMBER):
+ unit: NX_ANY
+ doc: |
+ This axis holds the position values for the independent variable.
+ dim: (n_values,)
+ intensity(NX_NUMBER):
+ unit: NX_ANY
+ doc: |
+ This array holds the intensity/count values at each position.
+ dim: (n_values,)
+ function(NXfit_function):
doc: |
- Is the background described analytically via a functional form
- or is it empirically defined via measured/reported
- intensity/counts as a function of an independent variable.
-
- Relevant details of the functional form shall be described through
- background_parameters.
- position(NX_NUMBER):
- unit: NX_ANY
- doc: |
- In the case of an empirical description of the background,
- this array holds the position values for the independent variable.
- dim: (n_support,)
- intensity(NX_NUMBER):
- unit: NX_ANY
- doc: |
- In the case of an empirical description of the background,
- this array holds the intensity/count values at each position.
- dim: (n_support,)
- background_parameters(NXparameters):
- doc: |
- In the case of an analytical description (or if description is other),
- this holds parameter of the functional form.
- For example in the case of Gaussians mu, sigma, and cut-off values are
- relevant parameters.
+ The functional form of the background.
# ++++++++++++++++++++++++++++++++++ SHA HASH ++++++++++++++++++++++++++++++++++
-# ab225b7c9634039e078d5ba44500c59f05958c63b16b4e3beb5c171d47fe65b1
+# b6f5a3c03e35dc263bed1eb13cee68861fe4c157834158d86fe6dc3921cfd442
#
#
#
-#
+#
#
#
#
@@ -58,6 +57,11 @@ NXfitfunction(NXobject):
#
# This describes a fit function to be used inside an NXfit instance.
#
+#
+#
+# Description of this fit function.
+#
+#
#
#
# This should be a python parsable function.
diff --git a/contributed_definitions/nyaml/NXpeak.yaml b/contributed_definitions/nyaml/NXpeak.yaml
index b9f76bc5e2..e7d8fc8493 100644
--- a/contributed_definitions/nyaml/NXpeak.yaml
+++ b/contributed_definitions/nyaml/NXpeak.yaml
@@ -5,7 +5,7 @@ doc: |
symbols:
doc: |
The symbols used in the schema to specify e.g. dimensions of arrays.
- n_support: |
+ n_values: |
Number of discretization points at which the functional form of the peak
has been evaluated.
type: group
@@ -14,31 +14,117 @@ NXpeak(NXobject):
doc: |
Human-readable label which specifies which concept/entity
the peak represents/identifies.
- lineshape:
+ data(NXdata):
+ position(NX_NUMBER):
+ unit: NX_ANY
+ doc: |
+ This axis holds the position values for the independent variable.
+ dim: (n_values,)
+ intensity(NX_NUMBER):
+ unit: NX_ANY
+ doc: |
+ This array holds the intensity/count values at each position.
+ dim: (n_values,)
+ function(NXfit_function):
doc: |
- Is the peak described analytically via a functional form
- or is it empirically defined via measured/reported
- intensity/counts as a function of an independent variable?
-
- If the functional form is not empirical or Gaussians, users
- should enter other for the description and add relevant details
- in the NXcollection.
- enumeration: [empirical, gaussian, lorentzian, voigt, other]
- position(NX_NUMBER):
- doc: |
- In the case of an empirical description of the peak,
- this array holds the position values for the independent variable.
- unit: NX_ANY
- dim: (n_support,)
- intensity(NX_NUMBER):
- doc: |
- In the case of an empirical description of the peak,
- this array holds the intensity/count values at each position.
+ The functional form of the peak. This could be a Gaussian, Lorentzian,
+ Voigt, etc.
+ (NXfit_repeated_parameter):
+ parameter_units:
+ dim: (n_values,)
+ values(NX_NUMBER):
+ dim: (n_values,)
+ total_area(NX_NUMBER):
unit: NX_ANY
- dim: (n_support,)
- (NXparameters):
doc: |
- In the case of an analytical description (or if description is other) this
- collection holds parameter of (and eventually) the functional form.
- For example in the case of Gaussians mu, sigma, cut-off values,
- and background intensity are relevant parameter.
+ Total area under the curve.
+
+# ++++++++++++++++++++++++++++++++++ SHA HASH ++++++++++++++++++++++++++++++++++
+# 815ff4497ec5dba04051269bb6adfbe6dd2bec94c55ee972ffe058bedf4053ce
+#
+#
+#
+#
+#
+#
+# The symbols used in the schema to specify e.g. dimensions of arrays.
+#
+#
+#
+# Number of discretization points at which the functional form of the peak
+# has been evaluated.
+#
+#
+#
+#
+# Base class for describing a spectral peak, its functional form, and support values
+# (i.e., the discretization (points) at which the function has been evaluated).
+#
+#
+#
+# Human-readable label which specifies which concept/entity
+# the peak represents/identifies.
+#
+#
+#
+#
+#
+# This axis holds the position values for the independent variable.
+#
+#
+#
+#
+#
+#
+#
+# This array holds the intensity/count values at each position.
+#
+#
+#
+#
+#
+#
+#
+#
+# The functional form of the peak. This could be a Gaussian, Lorentzian,
+# Voigt, etc.
+#
+#
+#
+#
+#
+#
+#
+#
+#
+#
+#
+#
+#
+#
+#
+#
+# Total area under the curve.
+#
+#
+#
From 8f3856a3fd62aa5c2988a0f4ec0cab3973d70473 Mon Sep 17 00:00:00 2001
From: Lukas Pielsticker <50139597+lukaspie@users.noreply.github.com>
Date: Thu, 15 Feb 2024 17:25:05 +0100
Subject: [PATCH 33/67] use NXdata in NXfit
---
contributed_definitions/NXfit.nxdl.xml | 127 ++++++-------
contributed_definitions/nyaml/NXfit.yaml | 225 ++++++++++-------------
2 files changed, 147 insertions(+), 205 deletions(-)
diff --git a/contributed_definitions/NXfit.nxdl.xml b/contributed_definitions/NXfit.nxdl.xml
index 1f1839d4b7..495f5f25a2 100644
--- a/contributed_definitions/NXfit.nxdl.xml
+++ b/contributed_definitions/NXfit.nxdl.xml
@@ -40,14 +40,44 @@
Human-readable label for this fit procedure.
-
+
- Subset of the independent axis for this fit procedure.
+ Input data and results of the fit.
-
-
-
-
+
+
+ Independent axis for this fit procedure.
+
+
+
+
+
+
+
+ Dependent axis for this fit procedure.
+
+
+
+
+
+
+
+ Resulting envelope of all NXpeak instances.
+ Should have the same dimension as the `position` axes of the individual peaks.
+
+
+
+
+
+
+
+ Difference between the envelope and the data to be fitted.
+
+
+
+
+
+
One spectral peak of the peak model.
@@ -55,8 +85,8 @@
- Total area under the curve. (can also be used for the total area minus any
- background values.)
+ Total area under the curve (can also be used for the total area minus any
+ background values).
@@ -64,7 +94,7 @@
Relative sensitivity for this peak, to be used for quantification in
an NXprocess.
- As an example, in X-ray spectroscopy could depend on the energy scale3
+ As an example, in X-ray spectroscopy could depend on the energy scale
(see position), the ionization cross section, and the element probed.
@@ -75,45 +105,9 @@
The relative area can simply be derived by dividing the total_area by the
total area of all peaks or by a more complicated method (e.g., by
additionally dividing by the relative sensitivity factors). Details shall
- be given in fitting_method
+ be given in fitting_method.
-
-
- Constraint on the minimum and maximum area of this peak.
-
-
-
-
-
- Link to a peak the area constraint depends on.
-
-
-
-
-
- Constraint on the minimum and maximum width of this peak.
-
-
-
-
-
- Link to a peak the width constraint depends on.
-
-
-
-
-
- Constraint on the minimum and maximum position of this peak on the abscissa.
-
-
-
-
-
- Link to a peak the position constraint depends on.
-
-
-
@@ -122,27 +116,22 @@
so on.
-
+
- Description of the method used to optimize the parameters during peak fitting.
- Examples:
- - least squares
- - non-linear least squares
- - Levenberg-Marquardt algorithm (damped least-squares)
- - linear regression
- - Bayesian linear regression
-
-
-
-
- Resulting envelope of all NXpeak instances.
-
- Should have the same dimension as the `position` axes of the individual peaks.
+ Function used to optimize the parameters during peak fitting.
-
-
-
-
+
+
+ Description of the method used to optimize the parameters during peak fitting.
+ Examples:
+ - least squares
+ - non-linear least squares
+ - Levenberg-Marquardt algorithm (damped least-squares)
+ - linear regression
+ - Bayesian linear regression
+
+
+
Figure-of-merit to determine the goodness of fit, i.e., how well the peak model
@@ -160,12 +149,4 @@
-
-
- Difference between the envelope and the data to be fitted.
-
-
-
-
-
diff --git a/contributed_definitions/nyaml/NXfit.yaml b/contributed_definitions/nyaml/NXfit.yaml
index e0b3ddbdac..e5e7a0d19e 100644
--- a/contributed_definitions/nyaml/NXfit.yaml
+++ b/contributed_definitions/nyaml/NXfit.yaml
@@ -11,11 +11,30 @@ NXfit(NXobject):
label:
doc: |
Human-readable label for this fit procedure.
- region(NX_NUMBER):
- unit: NX_ANY
+ data(NXdata):
doc: |
- Subset of the independent axis for this fit procedure.
- dim: (n_points,)
+ Input data and results of the fit.
+ input_dependent(NX_NUMBER):
+ unit: NX_ANY
+ doc: |
+ Independent axis for this fit procedure.
+ dim: (n_points,)
+ input_independent(NX_NUMBER):
+ unit: NX_ANY
+ doc: |
+ Dependent axis for this fit procedure.
+ dim: (n_points,)
+ envelope(NX_NUMBER):
+ unit: NX_ANY
+ doc: |
+ Resulting envelope of all NXpeak instances.
+ Should have the same dimension as the `position` axes of the individual peaks.
+ dim: (n_points,)
+ residual(NX_NUMBER):
+ unit: NX_ANY
+ doc: |
+ Difference between the envelope and the data to be fitted.
+ dim: (n_points,)
peak_PEAK(NXpeak):
doc: |
One spectral peak of the peak model.
@@ -23,15 +42,15 @@ NXfit(NXobject):
total_area(NX_NUMBER):
unit: NX_ANY
doc: |
- Total area under the curve. (can also be used for the total area minus any
- background values.)
+ Total area under the curve (can also be used for the total area minus any
+ background values).
relative_sensitivity_factor(NX_NUMBER):
unit: NX_UNITLESS
doc: |
Relative sensitivity for this peak, to be used for quantification in
an NXprocess.
- As an example, in X-ray spectroscopy could depend on the energy scale3
+ As an example, in X-ray spectroscopy could depend on the energy scale
(see position), the ionization cross section, and the element probed.
relative_area(NX_NUMBER):
unit: NX_ANY
@@ -41,58 +60,24 @@ NXfit(NXobject):
The relative area can simply be derived by dividing the total_area by the
total area of all peaks or by a more complicated method (e.g., by
additionally dividing by the relative sensitivity factors). Details shall
- be given in fitting_method
- area_constraint(NXparameters):
- doc: |
- Constraint on the minimum and maximum area of this peak.
- minimal_value(NX_NUMBER):
- unit: NX_ANY
- maximal_value(NX_NUMBER):
- unit: NX_ANY
- depends_on:
- doc: |
- Link to a peak the area constraint depends on.
- width_constraint(NXparameters):
- doc: |
- Constraint on the minimum and maximum width of this peak.
- minimal_value(NX_NUMBER):
- unit: NX_ANY
- maximal_value(NX_NUMBER):
- unit: NX_ANY
- depends_on:
- doc: |
- Link to a peak the width constraint depends on.
- position_constraint(NXparameters):
- doc: |
- Constraint on the minimum and maximum position of this peak on the abscissa.
- minimal_value(NX_NUMBER):
- unit: NX_ANY
- maximal_value(NX_NUMBER):
- unit: NX_ANY
- depends_on:
- doc: |
- Link to a peak the position constraint depends on.
+ be given in fitting_method.
background_BACKGROUND(NXfit_background):
doc: |
One fitted background (functional, position, and intensities) of the peak fit.
It is envisioned that peaks are labeled as background_0, background_1, and
so on.
- fitting_method:
- doc: |
- Description of the method used to optimize the parameters during peak fitting.
- Examples:
- - least squares
- - non-linear least squares
- - Levenberg-Marquardt algorithm (damped least-squares)
- - linear regression
- - Bayesian linear regression
- envelope(NX_NUMBER):
- unit: NX_ANY
+ fit_function(NXfit_function):
doc: |
- Resulting envelope of all NXpeak instances.
-
- Should have the same dimension as the `position` axes of the individual peaks.
- dim: (n_points,)
+ Function used to optimize the parameters during peak fitting.
+ description:
+ doc: |
+ Description of the method used to optimize the parameters during peak fitting.
+ Examples:
+ - least squares
+ - non-linear least squares
+ - Levenberg-Marquardt algorithm (damped least-squares)
+ - linear regression
+ - Bayesian linear regression
figure_of_merit_METRIC(NX_NUMBER):
unit: NX_UNITLESS
doc: |
@@ -107,14 +92,9 @@ NXfit(NXobject):
- :math:`\Chi^2`, the standard deviation of the residuals
- reduced :math:`\Chi^2`:, :math:`\Chi^2`: per degree of freedom
- :math:`R^2`, the coefficient of determination
- residual(NX_NUMBER):
- unit: NX_UNITLESS
- doc: |
- Difference between the envelope and the data to be fitted.
- dim: (n_points,)
# ++++++++++++++++++++++++++++++++++ SHA HASH ++++++++++++++++++++++++++++++++++
-# 332a87f3d66a159e0249e86266ae53783011b8e4384bb6bcd21ebb8bdcdb09cb
+# 288fe77153aab723ed39dd80b316c61aa6cfcc3355255a81614dcbda6bd5733e
#
#
#
+
+
+ Number of independent data axes to be fitted (for multidimensional fit.)
+
+
The number of parameter repetitions.
@@ -52,7 +57,7 @@
short-hand notation (e.g. nm, mm, kHz etc.).
-
+
@@ -60,7 +65,7 @@
The value of the parameter.
-
+
diff --git a/contributed_definitions/NXpeak.nxdl.xml b/contributed_definitions/NXpeak.nxdl.xml
index 9b905d834a..95427e31b3 100644
--- a/contributed_definitions/NXpeak.nxdl.xml
+++ b/contributed_definitions/NXpeak.nxdl.xml
@@ -32,6 +32,11 @@
has been evaluated.
+
+
+ Number of independent data axes to be fitted (for multidimensional fit.)
+
+
Base class for describing a spectral peak, its functional form, and support values
@@ -48,16 +53,16 @@
This axis holds the position values for the independent variable.
-
-
+
+
This array holds the intensity/count values at each position.
-
-
+
+
@@ -68,6 +73,7 @@
+<<<<<<< HEAD
@@ -75,6 +81,15 @@
+=======
+
+
+
+
+
+
+
+>>>>>>> 3dc34dd60 (make NXfit, NXpeak multi-dimensional)
diff --git a/contributed_definitions/nyaml/NXfit.yaml b/contributed_definitions/nyaml/NXfit.yaml
index 9bb2080223..fd7ccf7c12 100644
--- a/contributed_definitions/nyaml/NXfit.yaml
+++ b/contributed_definitions/nyaml/NXfit.yaml
@@ -6,6 +6,8 @@ symbols:
The symbols used in the schema to specify e.g. dimensions of arrays.
n_points: |
Number of discretization points inside the fitting region.
+ n_independent: |
+ Number of independent axes for this fit procedure.
type: group
NXfit(NXobject):
label:
@@ -25,20 +27,20 @@ NXfit(NXobject):
doc: |
Independent axis for this fit procedure.
dimensions:
- dim: [[1, n_points]]
+ dim: [[n_independent, n_points]]
envelope(NX_NUMBER):
unit: NX_ANY
doc: |
Resulting envelope of all NXpeak instances.
Should have the same dimension as the `position` axes of the individual peaks.
dimensions:
- dim: [[1, n_points]]
+ dim: [[n_independent, n_points]]
residual(NX_NUMBER):
unit: NX_ANY
doc: |
Difference between the envelope and the data to be fitted.
dimensions:
- dim: [[1, n_points]]
+ dim: [[n_independent, n_points]]
peakPEAK(NXpeak):
doc: |
One spectral peak of the peak model.
@@ -98,7 +100,7 @@ NXfit(NXobject):
- :math:`R^2`, the coefficient of determination
# ++++++++++++++++++++++++++++++++++ SHA HASH ++++++++++++++++++++++++++++++++++
-# 3d809910323b73fa6031b25ffa9ea14a685ca61427cb99e400b526f6eef86465
+# 7d9a2379ad4bcb14ba507b3b4583cc47597dc181f585e241f288a5a8c25f4079
#
#
#
#
#
+#
+#
+# Number of independent data axes to be fitted (for multidimensional fit.)
+#
+#
#
#
# The number of parameter repetitions.
@@ -87,7 +94,7 @@ NXfit_repeated_parameter(NXobject):
# short-hand notation (e.g. nm, mm, kHz etc.).
#
#
-#
+#
#
#
#
@@ -95,7 +102,7 @@ NXfit_repeated_parameter(NXobject):
# The value of the parameter.
#
#
-#
+#
#
#
#
diff --git a/contributed_definitions/nyaml/NXpeak.yaml b/contributed_definitions/nyaml/NXpeak.yaml
index 08d8c71507..5867cd8f42 100644
--- a/contributed_definitions/nyaml/NXpeak.yaml
+++ b/contributed_definitions/nyaml/NXpeak.yaml
@@ -8,6 +8,8 @@ symbols:
n_values: |
Number of discretization points at which the functional form of the peak
has been evaluated.
+ n_features: |
+ Number of independent data axes to be fitted (for multidimensional fit.)
type: group
NXpeak(NXobject):
label:
@@ -20,13 +22,13 @@ NXpeak(NXobject):
doc: |
This axis holds the position values for the independent variable.
dimensions:
- dim: [[1, n_values]]
+ dim: [[n_features, n_values]]
intensity(NX_NUMBER):
unit: NX_ANY
doc: |
This array holds the intensity/count values at each position.
dimensions:
- dim: [[1, n_values]]
+ dim: [[n_features, n_values]]
function(NXfit_function):
doc: |
The functional form of the peak. This could be a Gaussian, Lorentzian,
@@ -34,10 +36,10 @@ NXpeak(NXobject):
(NXfit_repeated_parameter):
parameter_units:
dimensions:
- dim: [[1, n_values]]
+ dim: [[n_features, n_values]]
values(NX_NUMBER):
dimensions:
- dim: [[1, n_values]]
+ dim: [[n_features, n_values]]
total_area(NX_NUMBER):
unit: NX_ANY
doc: |
@@ -79,6 +81,11 @@ NXpeak(NXobject):
# has been evaluated.
#
#
+#
+#
+# Number of independent data axes to be fitted (for multidimensional fit.)
+#
+#
#
#
# Base class for describing a spectral peak, its functional form, and support values
@@ -95,16 +102,16 @@ NXpeak(NXobject):
#
# This axis holds the position values for the independent variable.
#
-#
-#
+#
+#
#
#
#
#
# This array holds the intensity/count values at each position.
#
-#
-#
+#
+#
#
#
#
@@ -115,13 +122,13 @@ NXpeak(NXobject):
#
#
#
-#
-#
+#
+#
#
#
#
-#
-#
+#
+#
#
#
#
From 15d4c513b71934fa7685b9de657acf48c6937204 Mon Sep 17 00:00:00 2001
From: Lukas Pielsticker <50139597+lukaspie@users.noreply.github.com>
Date: Wed, 10 Apr 2024 14:22:11 +0200
Subject: [PATCH 44/67] redefine XPS coordinate system, small changes to XPS
peak fitting
---
contributed_definitions/NXfit.nxdl.xml | 2 +-
contributed_definitions/NXxps.nxdl.xml | 26 ++++++++++----
contributed_definitions/nyaml/NXfit.yaml | 6 ++--
contributed_definitions/nyaml/NXxps.yaml | 44 ++++++++++++++++++------
4 files changed, 57 insertions(+), 21 deletions(-)
diff --git a/contributed_definitions/NXfit.nxdl.xml b/contributed_definitions/NXfit.nxdl.xml
index 5906d49353..072e074407 100644
--- a/contributed_definitions/NXfit.nxdl.xml
+++ b/contributed_definitions/NXfit.nxdl.xml
@@ -137,7 +137,7 @@
-
+
Figure-of-merit to determine the goodness of fit, i.e., how well the peak model
fits the measured observations.
diff --git a/contributed_definitions/NXxps.nxdl.xml b/contributed_definitions/NXxps.nxdl.xml
index 13d70c7d3e..77d30cedd0 100644
--- a/contributed_definitions/NXxps.nxdl.xml
+++ b/contributed_definitions/NXxps.nxdl.xml
@@ -396,7 +396,8 @@
=======
- Should be a link to the XPS base coordinate system, e.g.
+ This could either point to the beam coordinate system (.) or to another transformation
+ that transforms from the beam coordinate system to the XPS base coordinate system at
/entry/instrument/xps_coordinate_system.
@@ -456,7 +457,6 @@
-
@@ -475,8 +475,13 @@
-
-
+
+
+
+ Area of the peak.
+
+
+
Width of a peak at a defined fraction of the peak height.
@@ -488,7 +493,14 @@
.. _3.28: https://www.iso.org/obp/ui/en/#iso:std:iso:18115:-1:ed-3:v1:en:term:3.28
-
+
+
+
+
+ Position of the peak on the energy axis.
+
+
+
@@ -676,14 +688,14 @@
-
+
>>>>>>> c47edfd66 (use new peak fitting in NXxps)
-
+
diff --git a/contributed_definitions/nyaml/NXfit.yaml b/contributed_definitions/nyaml/NXfit.yaml
index fd7ccf7c12..628a13a546 100644
--- a/contributed_definitions/nyaml/NXfit.yaml
+++ b/contributed_definitions/nyaml/NXfit.yaml
@@ -84,7 +84,7 @@ NXfit(NXobject):
- Levenberg-Marquardt algorithm (damped least-squares)
- linear regression
- Bayesian linear regression
- figure_of_merit_METRIC(NX_NUMBER):
+ figure_of_meritMETRIC(NX_NUMBER):
unit: NX_UNITLESS
doc: |
Figure-of-merit to determine the goodness of fit, i.e., how well the peak model
@@ -100,7 +100,7 @@ NXfit(NXobject):
- :math:`R^2`, the coefficient of determination
# ++++++++++++++++++++++++++++++++++ SHA HASH ++++++++++++++++++++++++++++++++++
-# 7d9a2379ad4bcb14ba507b3b4583cc47597dc181f585e241f288a5a8c25f4079
+# cf6ee20338952c6682c954044c19c61bbb845dc7a200722d6ba5285c7d5b39fd
#
#
#
- A single parameter for a fit function.
+ A parameter for a fit function.
This would typically be a variable that
is optimized in a fit.
diff --git a/contributed_definitions/NXfit_repeated_parameter.nxdl.xml b/contributed_definitions/NXfit_repeated_parameter.nxdl.xml
deleted file mode 100644
index 30a94ca2fa..0000000000
--- a/contributed_definitions/NXfit_repeated_parameter.nxdl.xml
+++ /dev/null
@@ -1,73 +0,0 @@
-
-
-
-
-
-
-
- Number of independent data axes to be fitted (for multidimensional fit.)
-
-
-
-
- The number of parameter repetitions.
-
-
-
-
- A repeated parameter for a fit function.
- This would typically be the independent variable in a fit.
-
-
-
- The name of the parameter.
-
-
-
-
- A description of what this parameter represents.
-
-
-
-
- A unit array associating a unit with each parameter.
- The first element should be equal to values/@unit.
- The values should be SI interpretable standard units
- with common prefixes (e.g. micro, nano etc.) or their
- short-hand notation (e.g. nm, mm, kHz etc.).
-
-
-
-
-
-
-
-
- The value of the parameter.
-
-
-
-
-
-
-
diff --git a/contributed_definitions/nyaml/NXfit_function.yaml b/contributed_definitions/nyaml/NXfit_function.yaml
index bafd6c4c4a..af78bdef96 100644
--- a/contributed_definitions/nyaml/NXfit_function.yaml
+++ b/contributed_definitions/nyaml/NXfit_function.yaml
@@ -14,15 +14,10 @@ NXfit_function(NXobject):
This should be a python parsable function.
Here we should provide which keywords are available
and a BNF of valid grammar.
- (NXfit_single_parameter):
- (NXfit_repeated_parameter):
- parameter_units:
- dim: (n_repetitions,)
- values(NX_NUMBER):
- dim: (n_repetitions,)
+ (NXfit_parameter):
# ++++++++++++++++++++++++++++++++++ SHA HASH ++++++++++++++++++++++++++++++++++
-# 4ec712368140064f42f1a4a85f2a0f78c0bcf426f66bd79bc7489a25ba1feb96
+# 591fe709aafff712c070d9763389795e7aa7e7672eb2dd4cf9f0dac453c73b01
#
#
#
#
#
-# A single parameter for a fit function.
+# A parameter for a fit function.
# This would typically be a variable that
# is optimized in a fit.
#
diff --git a/contributed_definitions/nyaml/NXfit_repeated_parameter.yaml b/contributed_definitions/nyaml/NXfit_repeated_parameter.yaml
deleted file mode 100644
index ef0162b1c3..0000000000
--- a/contributed_definitions/nyaml/NXfit_repeated_parameter.yaml
+++ /dev/null
@@ -1,110 +0,0 @@
-category: base
-doc: |
- A repeated parameter for a fit function.
- This would typically be the independent variable in a fit.
-symbols:
- n_features: |
- Number of independent data axes to be fitted (for multidimensional fit.)
- n_repetitions: |
- The number of parameter repetitions.
-type: group
-NXfit_repeated_parameter(NXobject):
- name(NX_CHAR):
- doc: |
- The name of the parameter.
- description(NX_CHAR):
- doc: |
- A description of what this parameter represents.
- parameter_units(NX_CHAR):
- doc: |
- A unit array associating a unit with each parameter.
- The first element should be equal to values/@unit.
- The values should be SI interpretable standard units
- with common prefixes (e.g. micro, nano etc.) or their
- short-hand notation (e.g. nm, mm, kHz etc.).
- dimensions:
- rank: 2
- dim: [[1, n_features], [2, n_repetitions]]
- values(NX_NUMBER):
- unit: NX_ANY
- doc: |
- The value of the parameter.
- dimensions:
- rank: 2
- dim: [[1, n_features], [2, n_repetitions]]
-
-# ++++++++++++++++++++++++++++++++++ SHA HASH ++++++++++++++++++++++++++++++++++
-# c76fa7187e3daac2e28e64715cba39c85e2274da7ac40bdedbbb8f518c27bfc1
-#
-#
-#
-#
-#
-#
-#
-# Number of independent data axes to be fitted (for multidimensional fit.)
-#
-#
-#
-#
-# The number of parameter repetitions.
-#
-#
-#
-#
-# A repeated parameter for a fit function.
-# This would typically be the independent variable in a fit.
-#
-#
-#
-# The name of the parameter.
-#
-#
-#
-#
-# A description of what this parameter represents.
-#
-#
-#
-#
-# A unit array associating a unit with each parameter.
-# The first element should be equal to values/@unit.
-# The values should be SI interpretable standard units
-# with common prefixes (e.g. micro, nano etc.) or their
-# short-hand notation (e.g. nm, mm, kHz etc.).
-#
-#
-#
-#
-#
-#
-#
-#
-# The value of the parameter.
-#
-#
-#
-#
-#
-#
-#
From 4eab35186709b8e097536ae4932ca7044b855f04 Mon Sep 17 00:00:00 2001
From: Lukas Pielsticker <50139597+lukaspie@users.noreply.github.com>
Date: Wed, 22 May 2024 11:21:33 +0200
Subject: [PATCH 52/67] fix dimensions in NXpeak and NXfit_background
---
.../NXfit_background.nxdl.xml | 38 +++++-----
.../NXfit_function.nxdl.xml | 23 +++---
.../NXfit_parameter.nxdl.xml | 9 ++-
contributed_definitions/NXpeak.nxdl.xml | 34 +++++----
.../nyaml/NXfit_background.yaml | 74 +++++++++++--------
.../nyaml/NXfit_function.yaml | 44 +++++------
.../nyaml/NXfit_parameter.yaml | 20 ++---
contributed_definitions/nyaml/NXpeak.yaml | 64 +++++++++-------
8 files changed, 171 insertions(+), 135 deletions(-)
diff --git a/contributed_definitions/NXfit_background.nxdl.xml b/contributed_definitions/NXfit_background.nxdl.xml
index 124ca83194..5b45fa81e4 100644
--- a/contributed_definitions/NXfit_background.nxdl.xml
+++ b/contributed_definitions/NXfit_background.nxdl.xml
@@ -26,16 +26,10 @@
The symbols used in the schema to specify e.g. dimensions of arrays.
-
+
- Number of discretization points at which the functional form of the
- background has been evaluated.
-
-
-
-
- Number of dependent variables to be fitted (for multidimensional/multivariate
- fit.)
+ Rank of the dependent and independent data arrays (for
+ multidimensional/multivariate fit.)
@@ -51,20 +45,30 @@
- This axis holds the position values for the independent variable.
+ Position values along one or more data dimensions (to hold the
+ values for the independent variable).
-
-
+
+
+ The ``position`` field must have the same rank (``dimRank``)
+ as the ``intensity`` field. Each individual dimension of ``position``
+ must have the same number of points as the corresponding dimension in
+ the ``intensity`` field.
+
- This array holds the intensity/count values of the fitted background at each
- position.
+ This array holds the intensity/count values of the fitted background
+ at each position.
-
-
-
+
+
+ The ``intensity`` field must have the same rank (``dimRank``)
+ as the ``intensity`` field. Each individual dimension of ``position``
+ must have the same number of points as the corresponding dimension in
+ the ``position`` field.
+
diff --git a/contributed_definitions/NXfit_function.nxdl.xml b/contributed_definitions/NXfit_function.nxdl.xml
index f955349922..8e257ebf80 100644
--- a/contributed_definitions/NXfit_function.nxdl.xml
+++ b/contributed_definitions/NXfit_function.nxdl.xml
@@ -22,25 +22,24 @@
# For further information, see http://www.nexusformat.org
-->
-
-
-
- The number of repetitions for the repeated parameters.
-
-
-
- This describes a fit function to be used inside an NXfit instance.
+ This describes a fit function that is used to fit data to any functional form.
+
+ A fit function is used to describe a set of data :math:`y_k, k = 1 ... M`, which are collected as a function
+ of one or more independent variables :math:`x` at the points :math:`x_k`. The fit function :math:`f` describes
+ these data in an approximative way as :math:`y_k ≈ f(a_0, . . . a_n, x_k)`, where math:`a_i, i = 0 . . . n` are
+ the _fit parameters_ (which are stored in ``NXfit_parameters``).
- Description of this fit function.
+ Human-readable description of this fit function.
-
+
- This should be a python parsable function.
- Here we should provide which keywords are available
+ Mathematical formula of the function, taking into account the ``NXfit_parameters``.
+
+ This should be a python parsable function. Here we should provide which keywords are available
and a BNF of valid grammar.
diff --git a/contributed_definitions/NXfit_parameter.nxdl.xml b/contributed_definitions/NXfit_parameter.nxdl.xml
index 6356532bc3..f8762232f5 100644
--- a/contributed_definitions/NXfit_parameter.nxdl.xml
+++ b/contributed_definitions/NXfit_parameter.nxdl.xml
@@ -21,7 +21,7 @@
#
# For further information, see http://www.nexusformat.org
-->
-
+
A parameter for a fit function.
This would typically be a variable that
@@ -39,17 +39,18 @@
- The value of the parameter.
+ The value of the parameter. After fitting, this would store the
+ optimized value.
- The minimal value of the parameter.
+ The minimal value of the parameter, to be used as a constraint during fitting.
- The maximal value of the parameter.
+ The maximal value of the parameter, to be used as a constraint during fitting.
diff --git a/contributed_definitions/NXpeak.nxdl.xml b/contributed_definitions/NXpeak.nxdl.xml
index 76c0096803..cbb2adcf6b 100644
--- a/contributed_definitions/NXpeak.nxdl.xml
+++ b/contributed_definitions/NXpeak.nxdl.xml
@@ -26,16 +26,10 @@
The symbols used in the schema to specify e.g. dimensions of arrays.
-
+
- Number of discretization points at which the functional form of the peak
- has been evaluated.
-
-
-
-
- Number of dependent variables to be fitted (for multidimensional/multivariate
- fit.)
+ Rank of the dependent and independent data arrays (for
+ multidimensional/multivariate fit.)
@@ -52,19 +46,29 @@
- This axis holds the position values for the independent variable.
+ Position values along one or more data dimensions (to hold the
+ values for the independent variable).
-
-
+
+
+ The ``position`` field must have the same rank (``dimRank``)
+ as the ``intensity`` field. Each individual dimension of ``position``
+ must have the same number of points as the corresponding dimension in
+ the ``intensity`` field.
+
This array holds the intensity/count values of the fitted peak at each position.
-
-
-
+
+
+ The ``intensity`` field must have the same rank (``dimRank``)
+ as the ``intensity`` field. Each individual dimension of ``position``
+ must have the same number of points as the corresponding dimension in
+ the ``position`` field.
+
diff --git a/contributed_definitions/nyaml/NXfit_background.yaml b/contributed_definitions/nyaml/NXfit_background.yaml
index 280644795c..f988a8bfc6 100644
--- a/contributed_definitions/nyaml/NXfit_background.yaml
+++ b/contributed_definitions/nyaml/NXfit_background.yaml
@@ -4,12 +4,9 @@ doc: |
symbols:
doc: |
The symbols used in the schema to specify e.g. dimensions of arrays.
- n_points: |
- Number of discretization points at which the functional form of the
- background has been evaluated.
- n_dependent: |
- Number of dependent variables to be fitted (for multidimensional/multivariate
- fit.)
+ dimRank: |
+ Rank of the dependent and independent data arrays (for
+ multidimensional/multivariate fit.)
type: group
NXfit_background(NXobject):
label(NX_CHAR):
@@ -20,24 +17,35 @@ NXfit_background(NXobject):
position(NX_NUMBER):
unit: NX_ANY
doc: |
- This axis holds the position values for the independent variable.
+ Position values along one or more data dimensions (to hold the
+ values for the independent variable).
dimensions:
- rank: 1
- dim: [[1, n_points]]
+ rank: dimRank
+ doc: |
+ The ``position`` field must have the same rank (``dimRank``)
+ as the ``intensity`` field. Each individual dimension of ``position``
+ must have the same number of points as the corresponding dimension in
+ the ``intensity`` field.
+ dim: []
intensity(NX_NUMBER):
unit: NX_ANY
doc: |
- This array holds the intensity/count values of the fitted background at each
- position.
+ This array holds the intensity/count values of the fitted background
+ at each position.
dimensions:
- rank: 2
- dim: [[1, n_points], [2, n_dependent]]
+ rank: dimRank
+ doc: |
+ The ``intensity`` field must have the same rank (``dimRank``)
+ as the ``intensity`` field. Each individual dimension of ``position``
+ must have the same number of points as the corresponding dimension in
+ the ``position`` field.
+ dim: []
function(NXfit_function):
doc: |
The functional form of the background.
# ++++++++++++++++++++++++++++++++++ SHA HASH ++++++++++++++++++++++++++++++++++
-# 40a4baea832789983182312a5fa9e93729d6d09a5b424b65a4277a932dcc8a0d
+# f2aa053cf2efec41fdae311ac6df33ac71072aeb03ff3d640b641c1e8b1f2be6
#
#
#
#
-#
-#
-#
-# The number of repetitions for the repeated parameters.
-#
-#
-#
#
-# This describes a fit function to be used inside an NXfit instance.
+# This describes a fit function that is used to fit data to any functional form.
+#
+# A fit function is used to describe a set of data :math:`y_k, k = 1 ... M`, which are collected as a function
+# of one or more independent variables :math:`x` at the points :math:`x_k`. The fit function :math:`f` describes
+# these data in an approximative way as :math:`y_k ≈ f(a_0, . . . a_n, x_k)`, where math:`a_i, i = 0 . . . n` are
+# the _fit parameters_ (which are stored in ``NXfit_parameters``).
#
#
#
-# Description of this fit function.
+# Human-readable description of this fit function.
#
#
-#
+#
#
-# This should be a python parsable function.
-# Here we should provide which keywords are available
+# Mathematical formula of the function, taking into account the ``NXfit_parameters``.
+#
+# This should be a python parsable function. Here we should provide which keywords are available
# and a BNF of valid grammar.
#
#
diff --git a/contributed_definitions/nyaml/NXfit_parameter.yaml b/contributed_definitions/nyaml/NXfit_parameter.yaml
index 1c3b0260a5..313e5a3cd0 100644
--- a/contributed_definitions/nyaml/NXfit_parameter.yaml
+++ b/contributed_definitions/nyaml/NXfit_parameter.yaml
@@ -4,7 +4,7 @@ doc: |
This would typically be a variable that
is optimized in a fit.
type: group
-NXfit_single_parameter(NXobject):
+NXfit_parameter(NXobject):
name(NX_CHAR):
doc: |
The name of the parameter.
@@ -14,18 +14,19 @@ NXfit_single_parameter(NXobject):
value(NX_NUMBER):
unit: NX_ANY
doc: |
- The value of the parameter.
+ The value of the parameter. After fitting, this would store the
+ optimized value.
min_value(NX_NUMBER):
unit: NX_ANY
doc: |
- The minimal value of the parameter.
+ The minimal value of the parameter, to be used as a constraint during fitting.
max_value(NX_NUMBER):
unit: NX_ANY
doc: |
- The maximal value of the parameter.
+ The maximal value of the parameter, to be used as a constraint during fitting.
# ++++++++++++++++++++++++++++++++++ SHA HASH ++++++++++++++++++++++++++++++++++
-# 67576446846777764015abe86269743cd6e0ae7d6685f4307d982e13a1d1c0b8
+# 86b45dd6443b276fa8997b0d758a2262339c05b2ef70429d700ec583802a8e9b
#
#
#
-#
+#
#
# A parameter for a fit function.
# This would typically be a variable that
@@ -67,17 +68,18 @@ NXfit_single_parameter(NXobject):
#
#
#
-# The value of the parameter.
+# The value of the parameter. After fitting, this would store the
+# optimized value.
#
#
#
#
-# The minimal value of the parameter.
+# The minimal value of the parameter, to be used as a constraint during fitting.
#
#
#
#
-# The maximal value of the parameter.
+# The maximal value of the parameter, to be used as a constraint during fitting.
#
#
#
diff --git a/contributed_definitions/nyaml/NXpeak.yaml b/contributed_definitions/nyaml/NXpeak.yaml
index f9ecf8c5d6..a92d61feeb 100644
--- a/contributed_definitions/nyaml/NXpeak.yaml
+++ b/contributed_definitions/nyaml/NXpeak.yaml
@@ -5,12 +5,9 @@ doc: |
symbols:
doc: |
The symbols used in the schema to specify e.g. dimensions of arrays.
- n_points: |
- Number of discretization points at which the functional form of the peak
- has been evaluated.
- n_dependent: |
- Number of dependent variables to be fitted (for multidimensional/multivariate
- fit.)
+ dimRank: |
+ Rank of the dependent and independent data arrays (for
+ multidimensional/multivariate fit.)
type: group
NXpeak(NXobject):
label:
@@ -21,17 +18,28 @@ NXpeak(NXobject):
position(NX_NUMBER):
unit: NX_ANY
doc: |
- This axis holds the position values for the independent variable.
+ Position values along one or more data dimensions (to hold the
+ values for the independent variable).
dimensions:
- rank: 1
- dim: [[1, n_points]]
+ rank: dimRank
+ doc: |
+ The ``position`` field must have the same rank (``dimRank``)
+ as the ``intensity`` field. Each individual dimension of ``position``
+ must have the same number of points as the corresponding dimension in
+ the ``intensity`` field.
+ dim: []
intensity(NX_NUMBER):
unit: NX_ANY
doc: |
This array holds the intensity/count values of the fitted peak at each position.
dimensions:
- rank: 2
- dim: [[1, n_points], [2, n_dependent]]
+ rank: dimRank
+ doc: |
+ The ``intensity`` field must have the same rank (``dimRank``)
+ as the ``intensity`` field. Each individual dimension of ``position``
+ must have the same number of points as the corresponding dimension in
+ the ``position`` field.
+ dim: []
function(NXfit_function):
doc: |
The functional form of the peak. This could be a Gaussian, Lorentzian,
@@ -71,16 +79,10 @@ NXpeak(NXobject):
#
# The symbols used in the schema to specify e.g. dimensions of arrays.
#
-#
+#
#
-# Number of discretization points at which the functional form of the peak
-# has been evaluated.
-#
-#
-#
-#
-# Number of dependent variables to be fitted (for multidimensional/multivariate
-# fit.)
+# Rank of the dependent and independent data arrays (for
+# multidimensional/multivariate fit.)
#
#
#
@@ -97,19 +99,29 @@ NXpeak(NXobject):
#
#
#
-# This axis holds the position values for the independent variable.
+# Position values along one or more data dimensions (to hold the
+# values for the independent variable).
#
-#
-#
+#
+#
+# The ``position`` field must have the same rank (``dimRank``)
+# as the ``intensity`` field. Each individual dimension of ``position``
+# must have the same number of points as the corresponding dimension in
+# the ``intensity`` field.
+#
#
#
#
#
# This array holds the intensity/count values of the fitted peak at each position.
#
-#
-#
-#
+#
+#
+# The ``intensity`` field must have the same rank (``dimRank``)
+# as the ``intensity`` field. Each individual dimension of ``position``
+# must have the same number of points as the corresponding dimension in
+# the ``position`` field.
+#
#
#
#
From f9304ba343dbf87a1a62fa52c40469c2a4597f6f Mon Sep 17 00:00:00 2001
From: Lukas Pielsticker <50139597+lukaspie@users.noreply.github.com>
Date: Wed, 22 May 2024 11:33:39 +0200
Subject: [PATCH 53/67] use globlal_fit and error_function in NXfit, fix
dimensions
---
contributed_definitions/NXfit.nxdl.xml | 101 ++++++++----
contributed_definitions/nyaml/NXfit.yaml | 191 ++++++++++++++++-------
2 files changed, 205 insertions(+), 87 deletions(-)
diff --git a/contributed_definitions/NXfit.nxdl.xml b/contributed_definitions/NXfit.nxdl.xml
index 6d79b137da..ab0e4f86ba 100644
--- a/contributed_definitions/NXfit.nxdl.xml
+++ b/contributed_definitions/NXfit.nxdl.xml
@@ -26,15 +26,10 @@
The symbols used in the schema to specify e.g. dimensions of arrays.
-
+
- Number of discretization points inside the fitting region.
-
-
-
-
- Number of dependent variables to be fitted (for multidimensional/multivariate
- fit.)
+ Rank of the dependent and independent data arrays (for
+ multidimensional/multivariate fit.)
@@ -52,45 +47,64 @@
- Dependent axis for this fit procedure.
+ Position values along one or more data dimensions (to hold the
+ values for the independent variable for this fit procedure).
-
-
+
+
+ The ``input_dependent`` field must have the same rank (``dimRank``)
+ as the ``input_independent`` field. Each individual dimension of ``input_dependent``
+ must have the same number of points as the corresponding dimension in
+ the ``input_independent`` field.
+
- Independent axis for this fit procedure.
+ Independent input axis for this fit procedure.
-
-
-
+
+
+ The ``input_independent`` field must have the same rank (``dimRank``)
+ as the ``input_dependent`` field. Each individual dimension of ``input_independent``
+ must have the same number of points as the corresponding dimension in
+ the ``input_dependent`` field.
+
- Resulting envelope of all NXpeak instances.
- Should have the same dimension as the `position` axes of the individual peaks.
+ Resulting envelope of applying the `global_fit_function` with its parameter to the data stored
+ in `input_independent`.
-
-
-
+
+
+ The ``envelope`` field must have the same rank (``dimRank``)
+ as the ``input_independent`` field. Each individual dimension of ``envelope``
+ must have the same number of points as the corresponding dimension in
+ the ``input_independent`` field.
+
- Difference between the envelope and the data to be fitted.
+ Difference between the envelope and the `input_independent` data to be fitted.
-
-
-
+
+
+ The ``residual`` field must have the same rank (``dimRank``)
+ as the ``input_independent`` field. Each individual dimension of ``residual``
+ must have the same number of points as the corresponding dimension in
+ the ``input_independent`` field.
+
- One spectral peak of the peak model.
- It is envisioned that peaks are labeled as peak_0, peak_1, and so on.
+ One peak of the peak model.
+ If there is no characteristic name for each peak component, is envisioned that peaks
+ are labeled as peak_0, peak_1, and so on.
@@ -114,18 +128,32 @@
The relative area can simply be derived by dividing the total_area by the
total area of all peaks or by a more complicated method (e.g., by
additionally dividing by the relative sensitivity factors). Details shall
- be given in fitting_method.
+ be given in `global_fit_function`.
- One fitted background (functional, position, and intensities) of the peak fit.
- It is envisioned that peaks are labeled as background_0, background_1, and
- so on.
+ One fitted background (functional form, position, and intensities) of the peak fit.
+ If there is no characteristic name for each peak component, it is envisioned that backgrounds are labeled
+ as background_0, background_1, and so on.
-
+
+
+ Function used to describe the overall fit to the data, taking into account the parameters of the
+ individual `NXpeak` and `NXfit_background` components.
+
+
+
+ Oftentimes, if the peaks and fit backgrounds are defined independently (i.e, with their own
+ parameter sets), the resulting global fit is a of the form
+ :math:`model = peak_1(p_1) + peak2(p_2) + backgr(p_3).`, where each :math:`p_x` describes the
+ set of parameters for one peak/background.
+
+
+
+
Function used to optimize the parameters during peak fitting.
@@ -140,6 +168,17 @@
- Bayesian linear regression
+
+
+ For the optimization, the formula is any optimization process on the `global_fit_function` given above.
+ As an example, for a linear least squared algorithm on independent components, the formula of the error_function
+ would be :math:`LLS(peak_1(p_1) + peak2(p_2) + backgr(p_3))`, where each :math:`p_x` describes the set
+ of parameters for one peak/background.
+
+ It is however also possible to supply more involved formulas. For example, in the case of constrained fits, the derivatives
+ of parameters.
+
+
diff --git a/contributed_definitions/nyaml/NXfit.yaml b/contributed_definitions/nyaml/NXfit.yaml
index 50fe447068..e02ccf0c5e 100644
--- a/contributed_definitions/nyaml/NXfit.yaml
+++ b/contributed_definitions/nyaml/NXfit.yaml
@@ -4,11 +4,9 @@ doc: |
symbols:
doc: |
The symbols used in the schema to specify e.g. dimensions of arrays.
- n_points: |
- Number of discretization points inside the fitting region.
- n_dependent: |
- Number of dependent variables to be fitted (for multidimensional/multivariate
- fit.)
+ dimRank: |
+ Rank of the dependent and independent data arrays (for
+ multidimensional/multivariate fit.)
type: group
NXfit(NXobject):
label:
@@ -20,35 +18,58 @@ NXfit(NXobject):
input_dependent(NX_NUMBER):
unit: NX_ANY
doc: |
- Dependent axis for this fit procedure.
+ Position values along one or more data dimensions (to hold the
+ values for the independent variable for this fit procedure).
dimensions:
- dim: [[1, n_points]]
+ rank: dimRank
+ doc: |
+ The ``input_dependent`` field must have the same rank (``dimRank``)
+ as the ``input_independent`` field. Each individual dimension of ``input_dependent``
+ must have the same number of points as the corresponding dimension in
+ the ``input_independent`` field.
+ dim: []
input_independent(NX_NUMBER):
unit: NX_ANY
doc: |
- Independent axis for this fit procedure.
+ Independent input axis for this fit procedure.
dimensions:
- rank: 2
- dim: [[1, n_points], [2, n_dependent]]
+ rank: dimRank
+ doc: |
+ The ``input_independent`` field must have the same rank (``dimRank``)
+ as the ``input_dependent`` field. Each individual dimension of ``input_independent``
+ must have the same number of points as the corresponding dimension in
+ the ``input_dependent`` field.
+ dim: []
envelope(NX_NUMBER):
unit: NX_ANY
doc: |
- Resulting envelope of all NXpeak instances.
- Should have the same dimension as the `position` axes of the individual peaks.
+ Resulting envelope of applying the `global_fit_function` with its parameter to the data stored
+ in `input_independent`.
dimensions:
- rank: 2
- dim: [[1, n_points], [2, n_dependent]]
+ rank: dimRank
+ doc: |
+ The ``envelope`` field must have the same rank (``dimRank``)
+ as the ``input_independent`` field. Each individual dimension of ``envelope``
+ must have the same number of points as the corresponding dimension in
+ the ``input_independent`` field.
+ dim: []
residual(NX_NUMBER):
unit: NX_ANY
doc: |
- Difference between the envelope and the data to be fitted.
+ Difference between the envelope and the `input_independent` data to be fitted.
dimensions:
- rank: 2
- dim: [[1, n_points], [2, n_dependent]]
+ rank: dimRank
+ doc: |
+ The ``residual`` field must have the same rank (``dimRank``)
+ as the ``input_independent`` field. Each individual dimension of ``residual``
+ must have the same number of points as the corresponding dimension in
+ the ``input_independent`` field.
+ dim: []
peakPEAK(NXpeak):
doc: |
- One spectral peak of the peak model.
- It is envisioned that peaks are labeled as peak_0, peak_1, and so on.
+ One peak of the peak model.
+ If there is no characteristic name for each peak component, is envisioned that peaks
+ are labeled as peak_0, peak_1, and so on.
total_area(NX_NUMBER):
unit: NX_ANY
doc: |
@@ -70,13 +91,23 @@ NXfit(NXobject):
The relative area can simply be derived by dividing the total_area by the
total area of all peaks or by a more complicated method (e.g., by
additionally dividing by the relative sensitivity factors). Details shall
- be given in fitting_method.
+ be given in `global_fit_function`.
backgroundBACKGROUND(NXfit_background):
doc: |
- One fitted background (functional, position, and intensities) of the peak fit.
- It is envisioned that peaks are labeled as background_0, background_1, and
- so on.
- fit_function(NXfit_function):
+ One fitted background (functional form, position, and intensities) of the peak fit.
+ If there is no characteristic name for each peak component, it is envisioned that backgrounds are labeled
+ as background_0, background_1, and so on.
+ global_fit_function(NXfit_function):
+ doc: |
+ Function used to describe the overall fit to the data, taking into account the parameters of the
+ individual `NXpeak` and `NXfit_background` components.
+ formula:
+ doc: |
+ Oftentimes, if the peaks and fit backgrounds are defined independently (i.e, with their own
+ parameter sets), the resulting global fit is a of the form
+ :math:`model = peak_1(p_1) + peak2(p_2) + backgr(p_3).`, where each :math:`p_x` describes the
+ set of parameters for one peak/background.
+ error_function(NXfit_function):
doc: |
Function used to optimize the parameters during peak fitting.
description:
@@ -88,6 +119,15 @@ NXfit(NXobject):
- Levenberg-Marquardt algorithm (damped least-squares)
- linear regression
- Bayesian linear regression
+ formula:
+ doc: |
+ For the optimization, the formula is any optimization process on the `global_fit_function` given above.
+ As an example, for a linear least squared algorithm on independent components, the formula of the error_function
+ would be :math:`LLS(peak_1(p_1) + peak2(p_2) + backgr(p_3))`, where each :math:`p_x` describes the set
+ of parameters for one peak/background.
+
+ It is however also possible to supply more involved formulas. For example, in the case of constrained fits, the derivatives
+ of parameters.
figure_of_meritMETRIC(NX_NUMBER):
unit: NX_UNITLESS
doc: |
@@ -104,7 +144,7 @@ NXfit(NXobject):
- :math:`R^2`, the coefficient of determination
# ++++++++++++++++++++++++++++++++++ SHA HASH ++++++++++++++++++++++++++++++++++
-# 74119a4cf342af4aea0a177a26d393893e54835ba084cf58ec07ea350b2dcf62
+# efe45ef3f375376f83d16f78f5b4604c83b192e56a3282c3938697a5287b2c2d
#
#
#
-
+
The symbols used in the schema to specify e.g. dimensions of arrays.
diff --git a/contributed_definitions/NXxps.nxdl.xml b/contributed_definitions/NXxps.nxdl.xml
index d4c0765cc1..8aee37f954 100644
--- a/contributed_definitions/NXxps.nxdl.xml
+++ b/contributed_definitions/NXxps.nxdl.xml
@@ -405,11 +405,15 @@
>>>>>>> 7178a95ca (remove NXtransformations from NXcoordinate_system)
+<<<<<<< HEAD
<<<<<<< HEAD
=======
>>>>>>> 5e7c2dec7 (change to NXcoordinate_system_set, use NXfit in NXxps)
+=======
+
+>>>>>>> 248a9c0ff (NXfit extends NXprocess)
Peak model for XPS fitting. Each `NXfit` instance shall be used for the description of
_one_ peak fit in _one_ XPS region. As an example, this could be used to describe the
@@ -419,6 +423,7 @@
.. _3.29: https://www.iso.org/obp/ui/en/#iso:std:iso:18115:-1:ed-3:v1:en:term:3.29
+<<<<<<< HEAD
<<<<<<< HEAD
@@ -428,89 +433,49 @@
=======
+=======
+
+
+>>>>>>> 248a9c0ff (NXfit extends NXprocess)
- Description of one peak fit. This is meant to be used for a peak fit in
- _one_ XPS region. As an example, this could be used to describe the
- fitting of one measured C 1s spectrum.
+ Input data and results of the fit.
-
-
+
- Input data and results of the fit.
+ Dependent variable for this fit procedure.
+
+ This could be a link to entry/data/data.
-
-
- Dependent variable for this fit procedure.
-
- This could be a link to entry/data/data.
-
-
-
+
+
+
+ Independent variable for this fit procedure.
+
+ This could be a link to entry/data/energy.
+
+
+
+
+
+
+
+
+
- Independent variable for this fit procedure.
-
This could be a link to entry/data/energy.
-
-
-
-
-
-
-
-
- This could be a link to entry/data/energy.
-
-
-
-
- Intensity values of the fitted function at each energy in the position field.
-
- This concept is related to term `3.15`_ of the ISO 18115-1:2023 standard.
-
- .. _3.15: https://www.iso.org/obp/ui/en/#iso:std:iso:18115:-1:ed-3:v1:en:term:3.15
-
-
-
-
-
-
-
- Area of the peak.
-
-
-
-
- Width of a peak at a defined fraction of the peak height.
-
- Usually, this will be the Full Width at Half Maximum of the peak (FWHM).
- For asymmetric peaks, convenient measures of peak width are the half-widths of
- each side of the peak at half maximum intensity.
-
- This concept is related to term `3.28`_ of the ISO 18115-1:2023 standard.
-
- .. _3.28: https://www.iso.org/obp/ui/en/#iso:std:iso:18115:-1:ed-3:v1:en:term:3.28
-
-
-
-
-
- Position of the peak on the energy axis.
-
-
-
-
-
+
- Total area under the peak after background removal.
+ Intensity values of the fitted function at each energy in the position field.
- This concept is related to term `3.16`_ of the ISO 18115-1:2023 standard.
+ This concept is related to term `3.15`_ of the ISO 18115-1:2023 standard.
- .. _3.16: https://www.iso.org/obp/ui/en/#iso:std:iso:18115:-1:ed-3:v1:en:term:3.16
+ .. _3.15: https://www.iso.org/obp/ui/en/#iso:std:iso:18115:-1:ed-3:v1:en:term:3.15
+<<<<<<< HEAD
<<<<<<< HEAD
>>>>>>> 5e7c2dec7 (change to NXcoordinate_system_set, use NXfit in NXxps)
@@ -554,11 +519,15 @@
+=======
+
+>>>>>>> 248a9c0ff (NXfit extends NXprocess)
Area of the peak.
+<<<<<<< HEAD
@@ -652,54 +621,38 @@
+=======
+>>>>>>> 248a9c0ff (NXfit extends NXprocess)
-
-
-
-
-
- Linear background, i.e., a simple straight line from the minimal to
- the maximal abscissa value.
-
-
-
-
- Shirley background. In the Shirley background, the background intensity at any
- given binding energy is proportional to the intensity of the total peak area
- above the background in the lower binding energy peak range (i.e., the
- background goes up in proportion to the total number of photoelectrons below its
- binding energy position).
-
-
-
-
- Tougaard background (or Tougaard universal cross-section approach) which is a
- methodology for integrating the intensity of the background at a given binding
- energy from the spectral intensities to higher kinetic energies
-
-
-
-
- In case none of the enumeration items apply, description should be _other_
- and the functional form of the background should be given by the `formula`
- field.
-
-
-
-
-
+
+
+ Width of a peak at a defined fraction of the peak height.
+
+ Usually, this will be the Full Width at Half Maximum of the peak (FWHM).
+ For asymmetric peaks, convenient measures of peak width are the half-widths of
+ each side of the peak at half maximum intensity.
+
+ This concept is related to term `3.28`_ of the ISO 18115-1:2023 standard.
+
+ .. _3.28: https://www.iso.org/obp/ui/en/#iso:std:iso:18115:-1:ed-3:v1:en:term:3.28
+
+
+
+
+
+ Position of the peak on the energy axis.
+
+
>>>>>>> c47edfd66 (use new peak fitting in NXxps)
-
-
-
-
-
+
- Atomic concentration of each species defined by one peak in the peak model.
- This should be an array with the indices pointing to the individual peaks
- (i.e, peak_0, peak_1, etc.)
+ Total area under the peak after background removal.
+
+ This concept is related to term `3.16`_ of the ISO 18115-1:2023 standard.
+
+ .. _3.16: https://www.iso.org/obp/ui/en/#iso:std:iso:18115:-1:ed-3:v1:en:term:3.16
>>>>>>> 5e7c2dec7 (change to NXcoordinate_system_set, use NXfit in NXxps)
diff --git a/contributed_definitions/nyaml/NXfit.yaml b/contributed_definitions/nyaml/NXfit.yaml
index 589e1508a7..cae8de1e8e 100644
--- a/contributed_definitions/nyaml/NXfit.yaml
+++ b/contributed_definitions/nyaml/NXfit.yaml
@@ -8,7 +8,7 @@ symbols:
Rank of the dependent and independent data arrays (for
multidimensional/multivariate fit.)
type: group
-NXfit(NXobject):
+NXfit(NXprocess):
label:
doc: |
Human-readable label for this fit procedure.
@@ -143,7 +143,7 @@ NXfit(NXobject):
- :math:`R^2`, the coefficient of determination
# ++++++++++++++++++++++++++++++++++ SHA HASH ++++++++++++++++++++++++++++++++++
-# 5c7eeb273752d19d2601bbf4be890683bf58eaa5bea2bb57e474e1dc0f0f3b84
+# fcf92e26824bac53c43854728f890e890bbbbb7f6f10e102a632304056ac91fd
#
#
#
-#
+#
#
#
# The symbols used in the schema to specify e.g. dimensions of arrays.
diff --git a/contributed_definitions/nyaml/NXxps.yaml b/contributed_definitions/nyaml/NXxps.yaml
index e27e6aec40..0afab7a31d 100644
--- a/contributed_definitions/nyaml/NXxps.yaml
+++ b/contributed_definitions/nyaml/NXxps.yaml
@@ -242,137 +242,142 @@ NXxps(NXmpes):
spec: ISO 18115-1:2023
term: 3.29
url: https://www.iso.org/obp/ui/en/#iso:std:iso:18115:-1:ed-3:v1:en:term:3.29
- (NXfit):
+ label:
+ data(NXdata):
doc: |
- Description of one peak fit. This is meant to be used for a peak fit in
- _one_ XPS region. As an example, this could be used to describe the
- fitting of one measured C 1s spectrum.
+ Input data and results of the fit.
+ input_dependent(NX_NUMBER):
+ unit: NX_ANY
+ doc: |
+ Dependent variable for this fit procedure.
+
+ This could be a link to entry/data/data.
+ input_independent(NX_NUMBER):
+ unit: NX_ANY
+ doc: |
+ Independent variable for this fit procedure.
+
+ This could be a link to entry/data/energy.
+ envelope(NX_NUMBER):
+ residual(NX_NUMBER):
+ exists: recommended
+ peakPEAK(NXpeak):
label:
data(NXdata):
- doc: |
- Input data and results of the fit.
- input_dependent(NX_NUMBER):
- unit: NX_ANY
+ position(NX_NUMBER):
+ unit: NX_ENERGY
doc: |
- Dependent variable for this fit procedure.
-
- This could be a link to entry/data/data.
- input_independent(NX_NUMBER):
- unit: NX_ANY
- doc: |
- Independent variable for this fit procedure.
-
This could be a link to entry/data/energy.
- envelope(NX_NUMBER):
- residual(NX_NUMBER):
- exists: recommended
- peakPEAK(NXpeak):
- label:
- data(NXdata):
- position(NX_NUMBER):
- unit: NX_ENERGY
- doc: |
- This could be a link to entry/data/energy.
- intensity(NX_NUMBER):
- doc:
- - |
- Intensity values of the fitted function at each energy in the position field.
- - |
- xref:
- spec: ISO 18115-1:2023
- term: 3.15
- url: https://www.iso.org/obp/ui/en/#iso:std:iso:18115:-1:ed-3:v1:en:term:3.15
- function(NXfit_function):
- formula:
- exists: recommended
- area(NXfit_single_parameter):
- exists: optional
- doc: |
- Area of the peak.
- width(NXfit_single_parameter):
- exists: optional
- doc:
- - |
- Width of a peak at a defined fraction of the peak height.
- - |
- Usually, this will be the Full Width at Half Maximum of the peak (FWHM).
- For asymmetric peaks, convenient measures of peak width are the half-widths of
- each side of the peak at half maximum intensity.
- - |
- xref:
- spec: ISO 18115-1:2023
- term: 3.28
- url: https://www.iso.org/obp/ui/en/#iso:std:iso:18115:-1:ed-3:v1:en:term:3.28
- value:
- unit: NX_ENERGY
- position(NXfit_single_parameter):
- exists: optional
- doc: |
- Position of the peak on the energy axis.
- value:
- unit: NX_ENERGY
- total_area:
+ intensity(NX_NUMBER):
+ doc:
+ - |
+ Intensity values of the fitted function at each energy in the position field.
+ - |
+ xref:
+ spec: ISO 18115-1:2023
+ term: 3.15
+ url: https://www.iso.org/obp/ui/en/#iso:std:iso:18115:-1:ed-3:v1:en:term:3.15
+ function(NXfit_function):
+ formula:
exists: recommended
+ area(NXfit_parameter):
+ exists: optional
+ doc: |
+ Area of the peak.
+ width(NXfit_parameter):
+ exists: optional
doc:
- |
- Total area under the peak after background removal.
+ Width of a peak at a defined fraction of the peak height.
+ - |
+ Usually, this will be the Full Width at Half Maximum of the peak (FWHM).
+ For asymmetric peaks, convenient measures of peak width are the half-widths of
+ each side of the peak at half maximum intensity.
- |
xref:
spec: ISO 18115-1:2023
- term: 3.16
- url: https://www.iso.org/obp/ui/en/#iso:std:iso:18115:-1:ed-3:v1:en:term:3.16
- backgroundBACKGROUND(NXfit_background):
+ term: 3.28
+ url: https://www.iso.org/obp/ui/en/#iso:std:iso:18115:-1:ed-3:v1:en:term:3.28
+ value:
+ unit: NX_ENERGY
+ position(NXfit_parameter):
+ exists: optional
+ doc: |
+ Position of the peak on the energy axis.
+ value:
+ unit: NX_ENERGY
+ total_area:
+ exists: recommended
doc:
- |
Total area under the peak after background removal.
- |
xref:
spec: ISO 18115-1:2023
- term: 3.21
- url: https://www.iso.org/obp/ui/en/#iso:std:iso:18115:-1:ed-3:v1:en:term:3.21
- label:
+ term: 3.16
+ url: https://www.iso.org/obp/ui/en/#iso:std:iso:18115:-1:ed-3:v1:en:term:3.16
+ backgroundBACKGROUND(NXfit_background):
+ doc:
+ - |
+ Functional form of the fitted XPS background.
+ - |
+ xref:
+ spec: ISO 18115-1:2023
+ term: 3.21
+ url: https://www.iso.org/obp/ui/en/#iso:std:iso:18115:-1:ed-3:v1:en:term:3.21
+ label:
+ exists: recommended
+ data(NXdata):
+ position(NX_NUMBER):
+ unit: NX_ENERGY
+ intensity(NX_NUMBER):
+ function(NXfit_function):
+ description:
+ enumeration:
+ linear:
+ doc: |
+ Linear background, i.e., a simple straight line from the minimal to
+ the maximal abscissa value.
+ Shirley:
+ doc: |
+ Shirley background. In the Shirley background, the background intensity at any
+ given binding energy is proportional to the intensity of the total peak area
+ above the background in the lower binding energy peak range (i.e., the
+ background goes up in proportion to the total number of photoelectrons below its
+ binding energy position).
+ Tougaard:
+ doc: |
+ Tougaard background (or Tougaard universal cross-section approach) which is a
+ methodology for integrating the intensity of the background at a given binding
+ energy from the spectral intensities to higher kinetic energies
+ other:
+ doc: |
+ In case none of the enumeration items apply, description should be _other_
+ and the functional form of the background should be given by the `formula`
+ field.
+ formula:
exists: recommended
- data(NXdata):
- position(NX_NUMBER):
- unit: NX_ENERGY
- intensity(NX_NUMBER):
- function(NXfit_function):
- description:
- enumeration:
- linear:
- doc: |
- Linear background, i.e., a simple straight line from the minimal to
- the maximal abscissa value.
- Shirley:
- doc: |
- Shirley background. In the Shirley background, the background intensity at any
- given binding energy is proportional to the intensity of the total peak area
- above the background in the lower binding energy peak range (i.e., the
- background goes up in proportion to the total number of photoelectrons below its
- binding energy position).
- Tougaard:
- doc: |
- Tougaard background (or Tougaard universal cross-section approach) which is a
- methodology for integrating the intensity of the background at a given binding
- energy from the spectral intensities to higher kinetic energies
- other:
- doc: |
- In case none of the enumeration items apply, description should be _other_
- and the functional form of the background should be given by the `formula`
- field.
- formula:
- exists: recommended
- fit_function(NXfit_function):
+ global_fit_function(NXfit_function):
+ exists: recommended
+ description:
exists: recommended
- figure_of_meritMETRIC(NX_NUMBER):
+ formula:
exists: recommended
- \@metric:
- relative_concentration(NX_FLOAT):
- unit: NX_ANY
- doc: |
- Atomic concentration of each species defined by one peak in the peak model.
- This should be an array with the indices pointing to the individual peaks
- (i.e, peak_0, peak_1, etc.)
+ error_function(NXfit_function):
+ exists: recommended
+ description:
+ exists: recommended
+ formula:
+ exists: recommended
+ figure_of_meritMETRIC(NX_NUMBER):
+ exists: recommended
+ \@metric:
+ relative_concentration(NX_FLOAT):
+ unit: NX_ANY
+ doc: |
+ Atomic concentration of each species defined by one peak in the peak model.
+ This should be an array with the indices pointing to the individual peaks
+ (i.e, peak_0, peak_1, etc.)
data(NXdata_mpes):
energy(NX_NUMBER):
\@energy_indices:
@@ -380,7 +385,7 @@ NXxps(NXmpes):
exists: recommended
# ++++++++++++++++++++++++++++++++++ SHA HASH ++++++++++++++++++++++++++++++++++
-# 40681e40574a11857f079de5eeb412534479c9ca24bd17b6712a3ad92be1e355
+# f4f5cfeb93f60f8c98404b4a15674f0e4ba09ec0366115467a3af99e1598a260
#
#
#
-#
-<<<<<<< HEAD
-# Description of coordinate system specific to the setup and the measurement
-# geometry.
->>>>>>> 8c42628fe (remove NXtransformations from NXcoordinate_system)
-=======
-# Description of one or more coordinate systems that are specific to the setup
-# and the measurement geometry.
->>>>>>> 05529f919 (change to NXcoordinate_system_set, use NXfit in NXxps)
->>>>>>> 5e7c2dec7 (change to NXcoordinate_system_set, use NXfit in NXxps)
#
#
#
diff --git a/contributed_definitions/nyaml/NXxps.yaml b/contributed_definitions/nyaml/NXxps.yaml
index ba9493c8e8..c15d457deb 100644
--- a/contributed_definitions/nyaml/NXxps.yaml
+++ b/contributed_definitions/nyaml/NXxps.yaml
@@ -278,6 +278,8 @@ NXxps(NXmpes):
term: 3.15
url: https://www.iso.org/obp/ui/en/#iso:std:iso:18115:-1:ed-3:v1:en:term:3.15
function(NXfit_function):
+ exists: recommended
+ description:
formula:
exists: recommended
area(NXfit_parameter):
@@ -332,6 +334,7 @@ NXxps(NXmpes):
unit: NX_ENERGY
intensity(NX_NUMBER):
function(NXfit_function):
+ exists: recommended
description:
enumeration:
linear:
@@ -378,14 +381,9 @@ NXxps(NXmpes):
Atomic concentration of each species defined by one peak in the peak model.
This should be an array with the indices pointing to the individual peaks
(i.e, peak_0, peak_1, etc.)
- data(NXdata_mpes):
- energy(NX_NUMBER):
- \@energy_indices:
- \@energy_depends:
- exists: recommended
# ++++++++++++++++++++++++++++++++++ SHA HASH ++++++++++++++++++++++++++++++++++
-# 7d6778701f0b2bf5dd5529bec912685b19a2269fb0afef7ed8e142fef9449a0f
+# 04421486bc5dffb01865fb8e056d77e5f5157304a3bc3ab9024c8ad160fe21e6
#
#
#