13 adding a field for catalog name for the control system and a catalog registration method new impl#16
Conversation
…SetpointIndexed into OAReadback/OASetpoint with optional index, add read_index/write_index to EpicsConfigRW, and replace string-based static catalog entries with typed EpicsStaticCatalogEntry objects. Add EpicsCatalog dynamic catalog (key = PV spec string) and EpicsStaticCatalog with structured per-entry signal configs; remove _epics_pv_builder module by inlining its logic into EpicsCatalog.
|
There are 17 files modified + 36 files modified in pyaml ! However i did a small check on BESSY2 example reading an orbit: sr = Accelerator.load("BESSY2Orbit.yaml")
SR = sr.live
orbit = SR.get_bpms("BPM").positions
print(orbit.get())Here is what i get ? [[3285.8356434 3285.8356434]
[3285.8356434 3285.8356434]
[3285.8356434 3285.8356434]
[3285.8356434 3285.8356434]
[3285.8356434 3285.8356434]
[3285.8356434 3285.8356434]
...Here is what i expect: [[ 3.28583564e+03 0.00000000e+00]
[ 2.19512518e+03 0.00000000e+00]
[ 1.12020909e+04 0.00000000e+00]
[ 1.75602034e+04 0.00000000e+00]
[ 9.97247501e+03 0.00000000e+00]
[-1.08780425e+03 0.00000000e+00]
[-6.43913112e+02 0.00000000e+00]
... |
|
How do you simulate the live? |
I realize it's a substantial PR, but since it’s a major architectural change, it’s difficult to break it down into smaller updates, they wouldn't make much sense in isolation as the pyaml branch (187-adding-catalogs-section-in-the-pyaml-configuration-file-new-implementation) requires the full implementation to be functional. The main parts of this update are:
|
|
It is important to try to cut in smaller task otherwise it is too difficult even impossible to review.
For examples, you have them in pyam/examples (including the soleil ones) with README that explain how to run them. |
|
I made the BESSY2 example working. |
There was a problem hiding this comment.
Handle error here when the get_value() return a float and and index is present.
Thank you very much for this contribution. I agree with you, but I would like to postpone these optimizations until we have fully functional catalogs, at least for the BPMs. |
There was a problem hiding this comment.
is hasattr() needed ?
hasattr is a slow call.
There was a problem hiding this comment.
You're right, it was completely unnecessary, except for the specific error message. I've removed it.
|
print in epcis.py: get_SP_RB() method. It seems that unattached signal are created ?!!! |
|
I patched |
|
I committed a first implementation of aggregator (it supports only read or readback for the moment) but it should be however compatible with the rest. |
|
For me it is stilll unclear how Catalog works and why unattached signal are constructed as shown above ? |
…ontrol-system-and-a-catalog-registration-method-new-impl
Update live tune integration configs for current PyAML tune API
Add EPICS catalog tests for dynamic and static resolution Removing useless imports
Add coverage for catalog config, EPICS/Tango lookups, indexed devices, and get_device error paths.
Summary
This PR adapts
pyaml-cs-oato the new PyAML API and adds catalog support to resolve EPICS and Tango devices from PyAML keys.Main Changes
catalogfield to theOphydAsyncControlSystemconfigurationindex,read_index, andwrite_indexCloses #13
Impact
This branch makes
pyaml-cs-oaeasier to integrate with PyAML's new resolution mechanisms while covering both scalar and vector signals, including partial access to array values.Dependency
The related PyAML developments are available in branch
187-adding-catalogs-section-in-the-pyaml-configuration-file-new-implementation(PR #234).