Skip to content
GitLab
Explore
Sign in
Register
Primary navigation
Search or go to…
Project
Superflat_scripts
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Iterations
Wiki
Requirements
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Locked files
Build
Pipelines
Jobs
Pipeline schedules
Test cases
Artifacts
Deploy
Releases
Package registry
Container registry
Model registry
Operate
Environments
Terraform modules
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Code review analytics
Issue analytics
Insights
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
GitLab community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
OPTIQUE
LEAPS
Superflat_scripts
Commits
887dc48b
Commit
887dc48b
authored
Sep 26, 2023
by
Francois POLACK
Browse files
Options
Downloads
Patches
Plain Diff
fix: Nexus_save: Add the measurement entry in the root default path
as defined in the standard
parent
de5e78db
Branches
Branches containing commit
No related tags found
No related merge requests found
Changes
1
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
heightmap.py
+5
-2
5 additions, 2 deletions
heightmap.py
with
5 additions
and
2 deletions
heightmap.py
+
5
−
2
View file @
887dc48b
...
@@ -693,7 +693,7 @@ class HeightMap(object):
...
@@ -693,7 +693,7 @@ class HeightMap(object):
#Create the measurement NXentry as complying to NXmetrology definition
#Create the measurement NXentry as complying to NXmetrology definition
entry
=
NXentry
(
detrended
,
rawdata
,
sample
,
instrument
,
name
=
'
measurement1
'
)
entry
=
NXentry
(
detrended
,
rawdata
,
sample
,
instrument
,
name
=
'
measurement1
'
)
entry
.
definition
=
NXattr
(
'
NXmetrology
'
)
entry
.
definition
=
NXattr
(
'
NXmetrology
'
)
# add the data group as link to detrended group and set
it as
default
# add the data group as link to detrended group and set
the
default
path
entry
.
data
=
NXlink
(
detrended
)
entry
.
data
=
NXlink
(
detrended
)
entry
.
data
.
set_default
()
entry
.
data
.
set_default
()
# add a the source data to the process group as alink
# add a the source data to the process group as alink
...
@@ -713,7 +713,10 @@ class HeightMap(object):
...
@@ -713,7 +713,10 @@ class HeightMap(object):
# erase the old file if any and write the NeXus tree to the file
# erase the old file if any and write the NeXus tree to the file
if
Path
(
fname
).
exists
():
if
Path
(
fname
).
exists
():
Path
(
fname
).
unlink
()
Path
(
fname
).
unlink
()
entry
.
save
(
fname
)
#put the measurement entry in the default path
root
=
NXroot
(
entry
)
entry
.
set_default
()
root
.
save
(
fname
)
def
add_drawing
(
parent
,
filename
):
def
add_drawing
(
parent
,
filename
):
ext
=
Path
(
filename
).
suffix
ext
=
Path
(
filename
).
suffix
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment