holoviz / param

Param: Make your Python code clearer and more reliable by declaring Parameters
https://param.holoviz.org
BSD 3-Clause "New" or "Revised" License
427 stars 73 forks source link

Restructuring #899

Closed VigneshVSV closed 9 months ago

VigneshVSV commented 9 months ago
MarcSkovMadsen commented 9 months ago

Hi @VigneshVSV

Looks interesting and massive. Why did you close the PR?

VigneshVSV commented 9 months ago

It was supposed to be merged to my forked version of main branch. Got assigned here by mistake.

I am also not up to date with your recent changes (which overlaps idealogically with some of my changes) since I worked on these changes about 6-8 months back. At some point, I might have to merge your changes to my own fork.

Nevertheless, the changes relate to my adaptation your repository for RPC applications for data acquisition in experimental physics/industrial automation. I have a subclass of Parameter called RemoteParameter & subclass of Parameterized called RemoteObject. Its not a part of my fork though, it lives in my own package called 'hololinked' (https://github.com/VigneshVSV/hololinked/tree/main/hololinked). I had some difficulties using your package as it is, except the main ideas and core logic/structure. One thing lead to another, and I had to make lot of changes.

Mainly, threading was necessary for dispatching events because instrument control requries thread safety. I added support for fget (which I think is what Dynamic parameter also does - so just a rearrangement of logic),

You can take a look at an example here if you are interested about how I use param in data-acquisition:

https://hololinked.readthedocs.io/en/latest/examples/server/spectrometer/index.html

P.S. - the readthedocs website is a work in progress & can be lacking.

VigneshVSV commented 9 months ago

Just FYI - anybody from holoviz who might be interested in data-acquisition/RPC and likes my project are welcome to contribute. Its relationship with param is quite foundational and provides more than a few elegant features which I am not yet done documenting. At least this is my view.

There is not a python based RPC out there which provides parameters on the network (at least I think so, including pyro and gRPC). I think this is similar how you model GUIs with param.

Of course, it can also be discussed how much my fork is diverging from holoviz and if there is a possibility to merge the differences.

MarcSkovMadsen commented 9 months ago

What do you mean by "Python with types"?

VigneshVSV commented 9 months ago

What do you mean by "Python with types"?

It just refers to type hints with the typing module. Sorry - as I said its supposed to be an internal merge to my fork so I didnt give elaborate descriptions.

I think when I forked it there were no type hints in the master/main branch. I still could not properly overload the __get__() with proper type hints.