apstrim 4.2.0__tar.gz → 4.2.1__tar.gz
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.
- {apstrim-4.2.0 → apstrim-4.2.1}/PKG-INFO +1 -1
- {apstrim-4.2.0 → apstrim-4.2.1}/apstrim/apstrim.py +1 -1
- {apstrim-4.2.0 → apstrim-4.2.1}/apstrim/view.py +7 -2
- apstrim-4.2.1/apstrim.aps +0 -0
- apstrim-4.2.1/apstrim_20251014_1257.aps +0 -0
- apstrim-4.2.1/apstrim_20251014_1325.aps +0 -0
- apstrim-4.2.1/apstrim_20251014_1411.aps +0 -0
- apstrim-4.2.1/apstrim_20251014_1429.aps +0 -0
- apstrim-4.2.1/apstrim_20251014_1431.aps +0 -0
- apstrim-4.2.1/apstrim_20251014_1437.aps +0 -0
- apstrim-4.2.1/apstrim_20251014_1438.aps +0 -0
- apstrim-4.2.1/apstrim_20251014_1439.aps +0 -0
- apstrim-4.2.1/cad_env/__init__.py +1 -0
- apstrim-4.2.1/cad_env/cad_env +1 -0
- apstrim-4.2.1/cad_env/screenlock_user.py +51 -0
- apstrim-4.2.1/cad_error/__init__.py +11 -0
- apstrim-4.2.1/cad_error/base.py +13 -0
- apstrim-4.2.1/cad_error/rhic_errors.py +1752 -0
- apstrim-4.2.1/cad_io/__init__.py +0 -0
- apstrim-4.2.1/cad_io/adoIf.py +1436 -0
- apstrim-4.2.1/cad_io/adoaccess.py +476 -0
- apstrim-4.2.1/cad_io/am.py +2483 -0
- apstrim-4.2.1/cad_io/ampy.py +758 -0
- apstrim-4.2.1/cad_io/cns.py +158 -0
- apstrim-4.2.1/cad_io/declarative_manager.py +1617 -0
- apstrim-4.2.1/cad_io/epicsAccess_caproto.py +216 -0
- apstrim-4.2.1/cad_io/liteAccess.py +664 -0
- apstrim-4.2.1/cad_io/liteCNS.py +33 -0
- apstrim-4.2.1/cad_io/notif.py +200 -0
- apstrim-4.2.1/cad_io/numpyAccess.py +31 -0
- apstrim-4.2.1/cad_io/project_url.py +20 -0
- apstrim-4.2.1/cad_io/rpc.py +900 -0
- apstrim-4.2.1/cad_io/setHistory.py +309 -0
- {apstrim-4.2.0 → apstrim-4.2.1}/pyproject.toml +1 -1
- {apstrim-4.2.0 → apstrim-4.2.1}/CHANGELOG.md +0 -0
- {apstrim-4.2.0 → apstrim-4.2.1}/LICENSE +0 -0
- {apstrim-4.2.0 → apstrim-4.2.1}/README.md +0 -0
- {apstrim-4.2.0 → apstrim-4.2.1}/apstrim/__init__.py +0 -0
- {apstrim-4.2.0 → apstrim-4.2.1}/apstrim/__main__.py +0 -0
- {apstrim-4.2.0 → apstrim-4.2.1}/apstrim/cad_pvaccess.py +0 -0
- {apstrim-4.2.0 → apstrim-4.2.1}/apstrim/helpTxtView.py +0 -0
- {apstrim-4.2.0 → apstrim-4.2.1}/apstrim/liteCNS.py +0 -0
- {apstrim-4.2.0 → apstrim-4.2.1}/apstrim/pubEPICS.py +0 -0
- {apstrim-4.2.0 → apstrim-4.2.1}/apstrim/scan.py +0 -0
- /apstrim-4.2.0/apstrim.aps → /apstrim-4.2.1/apstrim_20251014_1140.aps +0 -0
- {apstrim-4.2.0 → apstrim-4.2.1}/config/peaksim_pvp.py +0 -0
- {apstrim-4.2.0 → apstrim-4.2.1}/data/apstrim.aps +0 -0
- {apstrim-4.2.0 → apstrim-4.2.1}/data/apstrim_100Hz_10Items.aps +0 -0
- {apstrim-4.2.0 → apstrim-4.2.1}/data/apstrim_100Hz_oneItem.aps +0 -0
- {apstrim-4.2.0 → apstrim-4.2.1}/data/apstrim_am_simple_array_simple.test.sinM.aps +0 -0
- {apstrim-4.2.0 → apstrim-4.2.1}/docs/_config.yml +0 -0
- {apstrim-4.2.0 → apstrim-4.2.1}/docs/apstrim.html +0 -0
- {apstrim-4.2.0 → apstrim-4.2.1}/docs/apstrim_file_format.png +0 -0
- {apstrim-4.2.0 → apstrim-4.2.1}/docs/scan.html +0 -0
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
Metadata-Version: 2.4
|
|
2
2
|
Name: apstrim
|
|
3
|
-
Version: 4.2.
|
|
3
|
+
Version: 4.2.1
|
|
4
4
|
Summary: Logger and extractor of time-series data (e.g. EPICS PVs or liteServer LDOs).
|
|
5
5
|
Project-URL: Homepage, https://github.com/ASukhanov/apstrim
|
|
6
6
|
Project-URL: Bug Tracker, https://github.com/ASukhanov/apstrim/issues
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
"""Plot data from the apstrim-generated files."""
|
|
2
|
-
__version__ = 'v4.2.
|
|
2
|
+
__version__ = 'v4.2.1 2025-10-14'# fixing names of curves of sliced arrays
|
|
3
3
|
#TODO: Cellname did not change on plot after changing it in dataset options
|
|
4
4
|
#TODO: data acquisition stops when section is dumped to disk. Is writing really buffered?
|
|
5
5
|
#TODO: interactive works only for one file
|
|
@@ -678,7 +678,12 @@ def hsvToRgb(idx, maxColors, offset=2/3):
|
|
|
678
678
|
return list(pg.hsvColor((offset+idx/maxColors)%1.).getRgb())
|
|
679
679
|
|
|
680
680
|
for i,item in enumerate(items):
|
|
681
|
-
|
|
681
|
+
_slice = ''
|
|
682
|
+
it = item
|
|
683
|
+
if '[' in it:
|
|
684
|
+
it,_slice = it.rsplit('[',2)
|
|
685
|
+
_slice = '['+ _slice
|
|
686
|
+
cell = it.rsplit(':',1)[1] + _slice
|
|
682
687
|
lcolor = hsvToRgb(i, len(items))
|
|
683
688
|
C.curves[item] = CurveProperties(cell, 0, False, lcolor, 1, None,
|
|
684
689
|
DefaultSymbolSize)
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
from .screenlock_user import get_screenlock_user
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
../cad_env/cad_env/
|
|
@@ -0,0 +1,51 @@
|
|
|
1
|
+
import getpass
|
|
2
|
+
import os
|
|
3
|
+
import re
|
|
4
|
+
import subprocess as subp
|
|
5
|
+
from typing import Optional
|
|
6
|
+
|
|
7
|
+
SCREENLOCK_RE = re.compile(r"(\S+)\s+(\d+)")
|
|
8
|
+
|
|
9
|
+
_screenlock_last_read: int = 0
|
|
10
|
+
_screenlock_user: Optional[str] = None
|
|
11
|
+
|
|
12
|
+
|
|
13
|
+
def get_screenlock_user():
|
|
14
|
+
global _screenlock_last_read
|
|
15
|
+
global _screenlock_user
|
|
16
|
+
|
|
17
|
+
username = getpass.getuser()
|
|
18
|
+
proc = subp.run(
|
|
19
|
+
["/home/cfsd/sysadmin/bin/isGroup", "-q", username],
|
|
20
|
+
text=True,
|
|
21
|
+
stdout=subp.DEVNULL,
|
|
22
|
+
stderr=subp.DEVNULL,
|
|
23
|
+
)
|
|
24
|
+
if proc.returncode != 0:
|
|
25
|
+
_screenlock_last_read = 0
|
|
26
|
+
_screenlock_user = None
|
|
27
|
+
return None
|
|
28
|
+
|
|
29
|
+
filename = "/tmp/ScreenLockFile"
|
|
30
|
+
|
|
31
|
+
if not os.path.exists(filename):
|
|
32
|
+
_screenlock_last_read = 0
|
|
33
|
+
_screenlock_user = None
|
|
34
|
+
return None
|
|
35
|
+
|
|
36
|
+
stat = os.stat(filename)
|
|
37
|
+
if stat.st_mtime <= _screenlock_last_read:
|
|
38
|
+
# No update since last check
|
|
39
|
+
return _screenlock_user
|
|
40
|
+
|
|
41
|
+
with open(filename, "rt") as file:
|
|
42
|
+
content = file.read()
|
|
43
|
+
match = SCREENLOCK_RE.match(content)
|
|
44
|
+
if match:
|
|
45
|
+
username, _ = match.groups()
|
|
46
|
+
_screenlock_last_read = stat.st_mtime
|
|
47
|
+
_screenlock_user = username
|
|
48
|
+
else:
|
|
49
|
+
_screenlock_last_read = 0
|
|
50
|
+
_screenlock_user = None
|
|
51
|
+
return _screenlock_user
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
"""
|
|
2
|
+
This package is used to specify the error codes used within C-AD.
|
|
3
|
+
|
|
4
|
+
Error codes are split among various modules, which are logically grouped into Enums
|
|
5
|
+
within this package.
|
|
6
|
+
"""
|
|
7
|
+
|
|
8
|
+
from .base import CADError
|
|
9
|
+
from .rhic_errors import RhicError
|
|
10
|
+
|
|
11
|
+
__all__ = ["CADError", "RhicError"]
|