Skip to content

Releases: nexpy/nexusformat

v2.0.0

10 Sep 19:43
8bee863

Choose a tag to compare

  • Adds functions to validate NeXus fields and groups against the NeXus base class and application definitions. The NeXus definitions are now distributed with the package, although alternative repositories can also be selected.
  • Adds functions to output a formatted version of the NeXus base class definitions.
  • Adds functions to serialize and deserialize NeXus objects for transmission and reconstruction across a network.
  • Adds a nxunits property to add unit attributes to fields.
  • Adds a nxtarget property to change the target of a NXlink object. If the link is external, the value can be a tuple containing the absolute path within the external file and its file path. In the case of hard links, the target attribute is removed from the parent when all links to it have been removed.
  • Allows a slab to be selected when creating a virtual dataset.
  • Allows the default attribute to be propagated through any base class in the hierarchy, not just NXentry and NXsubentry groups.
  • Changes the NXfield statistical methods to match the equivalent NumPy methods.
  • Updates the minimum supported Python version to 3.9.

What's Changed

New Contributors

Full Changelog: v1.0.8...v2.0.0

v2.0.0b7

12 Aug 17:01
e9930cb

Choose a tag to compare

v2.0.0b7 Pre-release
Pre-release
  • Updates the NeXus base class and application definitions in the package data.
  • Fixes a bug when changing the target of an external link using the nxtarget property.

v2.0.0b6

07 Aug 15:43
b80d0b2

Choose a tag to compare

v2.0.0b6 Pre-release
Pre-release
  • Enables the selection of a slab when creating a virtual field.

v2.0.0b5

28 Jul 16:16
0e3e676

Choose a tag to compare

v2.0.0b5 Pre-release
Pre-release
  • Adds serialize and deserialize functions to the NXfield, NXgroup, and NXlink classes to allow serialized versions of the file to be sent over network connections. The serialize function converts the NeXus objects to dictionaries, that may be saved to a file (e.g., with pickle.dump. The deserialize function is a class method that recreates the NeXus object after the dictionary has been reloaded (e.g., with pickle.load). For a complete NeXus file, this would be implemented by NXroot.deserialize(<serialized_root>).

v2.0.0b4

05 Jun 22:00
2b56a92

Choose a tag to compare

v2.0.0b4 Pre-release
Pre-release
  • Fixes a bug resolving the target path in external links.

v2.0.0b3

03 Jun 14:25
66a36cb

Choose a tag to compare

v2.0.0b3 Pre-release
Pre-release
  • Adds a nxunits property to NXfields to facilitate the reading and setting of field units.
  • Enables the target and/or filename of NXlinks to be changed using the nxtarget property setter. In the case of hard links, the target attribute is removed from the parent when all links to it have been removed.
  • Saves all targets as absolute paths in NeXus files, although the target may be initialized as a relative path. Absolute paths are required to ensure that the link parents can be identified when reading the file.
  • Adds NXgroup and NXfield functions to use the new validation module to return lists of valid groups, fields, and/or attributes allowed by the base class definitions. Deprecated values are removed from these lists by default.
  • Adds NXgroup and NXfield functions to return a list of enumerations for field and/or attribute values when defined by the base class definition.

v2.0.0b2

07 May 15:21
665e22d

Choose a tag to compare

v2.0.0b2 Pre-release
Pre-release
  • Enables the default attribute defining default NXdata groups to plot to propagate through all groups. Previously, only NXentry and NXsubentry groups were allowed.
  • Fixes the copying of groups containing external links.
  • Adds the NXgoniometer base class, which is used in NXRefine but not yet ratified by the NIAC.

v2.0.0b1

26 Apr 16:15
9f91ebe

Choose a tag to compare

v2.0.0b1 Pre-release
Pre-release
  • Adds validation module to check the contents of base classes and validate against application definitions.
  • All base class and application definition files are now included in the package, although the path to the definitions directory can be redefined either using nxsetconfig or setting the NX_DEFINITIONS environment variable.
  • Adds three new NXgroup methods, check, validate, and inspect, which produce colorized output.
    • The check function compares the contents of a group and its children to their base class definitions.
    • The validate function validates the contents of a NXentry group against an application definition.
    • The inspect function produces a formatted version of the base class XML file.
  • Adds a command-line script nxcheck to check or validate a NeXus file.
  • Adds a command-line script nxinspect to display a base class definition.
  • Changes the NXfield statistical methods to match the equivalent NumPy methods. For the old behavior, the NXfield should be wrapped in a NXdata group without specifying axes.
  • Updates requirement to use Python v3.9, now that v3.8 has reached its end-of-life phase.

v1.0.8

29 Mar 15:03
28d10ee

Choose a tag to compare

  • Add the target attribute when saving a soft link to a file.
  • Improves handling of keyword arguments when calling NumPy functions.

v1.0.7

26 Oct 19:45
60c2478

Choose a tag to compare

  • Allows soft links to use relative paths. For backward compatibility, relative paths with respect to the NXroot object are checked if a path is invalid.
  • Improves the compatibility of the written root attributes to the NeXus definitions.
  • Ensures that root attributes are written correctly when using nxopen as a context manager.
  • Adds a get function to the attribute dictionary.