sardana-nxsrecorder 3.20.0__py3-none-any.whl → 3.21.1__py3-none-any.whl
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- {sardana_nxsrecorder-3.20.0.dist-info → sardana_nxsrecorder-3.21.1.dist-info}/METADATA +2 -2
- sardana_nxsrecorder-3.21.1.dist-info/RECORD +6 -0
- sardananxsrecorder/__init__.py +1 -1
- sardananxsrecorder/nxsrecorder.py +13 -5
- sardana_nxsrecorder-3.20.0.dist-info/RECORD +0 -6
- {sardana_nxsrecorder-3.20.0.dist-info → sardana_nxsrecorder-3.21.1.dist-info}/WHEEL +0 -0
- {sardana_nxsrecorder-3.20.0.dist-info → sardana_nxsrecorder-3.21.1.dist-info}/top_level.txt +0 -0
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
Metadata-Version: 2.1
|
|
2
2
|
Name: sardana-nxsrecorder
|
|
3
|
-
Version: 3.
|
|
3
|
+
Version: 3.21.1
|
|
4
4
|
Summary: NeXus Sardana Scan Recorder
|
|
5
5
|
Home-page: https://github.com/nexdatas/sardana-nxs-filerecorder/
|
|
6
6
|
Author: Jan Kotanski
|
|
@@ -12,7 +12,6 @@ Classifier: Intended Audience :: Science/Research
|
|
|
12
12
|
Classifier: Topic :: Scientific/Engineering :: Physics
|
|
13
13
|
Classifier: Topic :: Software Development :: Libraries :: Python Modules
|
|
14
14
|
Classifier: License :: OSI Approved :: GNU General Public License v3 (GPLv3)
|
|
15
|
-
Classifier: Programming Language :: Python :: 2.7
|
|
16
15
|
Classifier: Programming Language :: Python :: 3
|
|
17
16
|
Classifier: Programming Language :: Python :: 3.4
|
|
18
17
|
Classifier: Programming Language :: Python :: 3.5
|
|
@@ -22,6 +21,7 @@ Classifier: Programming Language :: Python :: 3.8
|
|
|
22
21
|
Classifier: Programming Language :: Python :: 3.9
|
|
23
22
|
Classifier: Programming Language :: Python :: 3.10
|
|
24
23
|
Classifier: Programming Language :: Python :: 3.11
|
|
24
|
+
Classifier: Programming Language :: Python :: 3.12
|
|
25
25
|
Requires-Dist: lxml
|
|
26
26
|
Requires-Dist: numpy (>1.6.0)
|
|
27
27
|
|
|
@@ -0,0 +1,6 @@
|
|
|
1
|
+
sardananxsrecorder/__init__.py,sha256=oD-0m9QGVmtssbJ2KNAVtNlHgQc0-LN1W3acxQk15Cg,896
|
|
2
|
+
sardananxsrecorder/nxsrecorder.py,sha256=ywGXHnqP_-tOqOEtv_vMyciDjJXr5S0EAmjRpbcQCJA,53039
|
|
3
|
+
sardana_nxsrecorder-3.21.1.dist-info/METADATA,sha256=cpiIZsvcLBOkDLuyyglxUGqpLlR-4LYBS2L_YtxMwFU,7566
|
|
4
|
+
sardana_nxsrecorder-3.21.1.dist-info/WHEEL,sha256=2wepM1nk4DS4eFpYrW1TTqPcoGNfHhhO_i5m4cOimbo,92
|
|
5
|
+
sardana_nxsrecorder-3.21.1.dist-info/top_level.txt,sha256=YdD3m417i-jlYyQWgiizgZ8lQQcOjM8y-bmUHrGkfY4,19
|
|
6
|
+
sardana_nxsrecorder-3.21.1.dist-info/RECORD,,
|
sardananxsrecorder/__init__.py
CHANGED
|
@@ -22,6 +22,7 @@
|
|
|
22
22
|
|
|
23
23
|
import os
|
|
24
24
|
import re
|
|
25
|
+
import sys
|
|
25
26
|
|
|
26
27
|
import numpy
|
|
27
28
|
import json
|
|
@@ -961,7 +962,7 @@ class NXS_FileRecorder(BaseFileRecorder):
|
|
|
961
962
|
appendentry = not self.__setFileName(
|
|
962
963
|
self.__base_filename, not appendentry)
|
|
963
964
|
envRec = self.recordlist.getEnviron()
|
|
964
|
-
self.__vars["vars"]["serialno"] = envRec["serialno"] \
|
|
965
|
+
self.__vars["vars"]["serialno"] = ("_%05i" % envRec["serialno"]) \
|
|
965
966
|
if appendentry else ""
|
|
966
967
|
self.__vars["vars"]["scan_id"] = envRec["serialno"]
|
|
967
968
|
self.__vars["vars"]["scan_title"] = envRec["title"]
|
|
@@ -1129,7 +1130,10 @@ class NXS_FileRecorder(BaseFileRecorder):
|
|
|
1129
1130
|
tz = pytz.timezone(self.__timezone)
|
|
1130
1131
|
|
|
1131
1132
|
fmt = '%Y-%m-%dT%H:%M:%S.%f%z'
|
|
1132
|
-
|
|
1133
|
+
if sys.version_info > (3, 6):
|
|
1134
|
+
starttime = mtime.replace(tzinfo=tz)
|
|
1135
|
+
else:
|
|
1136
|
+
starttime = tz.localize(mtime)
|
|
1133
1137
|
return str(starttime.strftime(fmt))
|
|
1134
1138
|
|
|
1135
1139
|
def _endRecordList(self, recordlist):
|
|
@@ -1233,8 +1237,8 @@ class NXS_FileRecorder(BaseFileRecorder):
|
|
|
1233
1237
|
scanname, _ = os.path.splitext(bfname)
|
|
1234
1238
|
|
|
1235
1239
|
if appendentry is True:
|
|
1236
|
-
sid = self.
|
|
1237
|
-
sname = "%s::/%
|
|
1240
|
+
sid = self.__vars["vars"]["scan_id"]
|
|
1241
|
+
sname = "%s::/%s_%05i;%s_%05i" % (
|
|
1238
1242
|
scanname, entryname, sid, scanname, sid)
|
|
1239
1243
|
|
|
1240
1244
|
# auto grouping
|
|
@@ -1290,6 +1294,10 @@ class NXS_FileRecorder(BaseFileRecorder):
|
|
|
1290
1294
|
variables = self.__getConfVar("ConfigVariables", None, True)
|
|
1291
1295
|
if isinstance(variables, dict) and "entryname" in variables:
|
|
1292
1296
|
entryname = variables["entryname"]
|
|
1297
|
+
if appendentry is True:
|
|
1298
|
+
sid = self.__vars["vars"]["scan_id"]
|
|
1299
|
+
entryname = entryname + ("_%05i" % sid)
|
|
1300
|
+
sname = sname + ("_%05i" % sid)
|
|
1293
1301
|
|
|
1294
1302
|
mntname = scanname
|
|
1295
1303
|
if fdir in sm.keys() and sm[fdir]:
|
|
@@ -1304,7 +1312,7 @@ class NXS_FileRecorder(BaseFileRecorder):
|
|
|
1304
1312
|
fl = h5writer.open_file(mntfile, readonly=False)
|
|
1305
1313
|
rt = fl.root()
|
|
1306
1314
|
if sname not in rt.names():
|
|
1307
|
-
h5writer.link("%s:/%s" % (
|
|
1315
|
+
h5writer.link("%s:/%s" % (fname, entryname), rt, sname)
|
|
1308
1316
|
self.debug("Link '%s' in '%s' created " % (sname, mntname))
|
|
1309
1317
|
rt.close()
|
|
1310
1318
|
fl.close()
|
|
@@ -1,6 +0,0 @@
|
|
|
1
|
-
sardananxsrecorder/__init__.py,sha256=qCNV0aQdC8ohuF2JgGo7uBXYvYjAK526JuafDfEQMWY,896
|
|
2
|
-
sardananxsrecorder/nxsrecorder.py,sha256=xVjPC7eVFpuilKfExOvbTjKECOXH9USDJXIxQknVtHY,52738
|
|
3
|
-
sardana_nxsrecorder-3.20.0.dist-info/METADATA,sha256=Lsdfz2ISL5AcIPCehARWC0fVEtw8cu55YjfjTBLi2HE,7565
|
|
4
|
-
sardana_nxsrecorder-3.20.0.dist-info/WHEEL,sha256=2wepM1nk4DS4eFpYrW1TTqPcoGNfHhhO_i5m4cOimbo,92
|
|
5
|
-
sardana_nxsrecorder-3.20.0.dist-info/top_level.txt,sha256=YdD3m417i-jlYyQWgiizgZ8lQQcOjM8y-bmUHrGkfY4,19
|
|
6
|
-
sardana_nxsrecorder-3.20.0.dist-info/RECORD,,
|
|
File without changes
|
|
File without changes
|