Closed szymonmichalski closed 4 years ago
Thank you for response, I will use SDK then. I will close this issue now.
Hi @NiklasKroeger-AlliedVision , I would be happy to see VimbaPython on PyPI.
Can VimbaC library compiled as a shared library? if so potentially it can be shipped with VimbaPython on PyPI. Or can be build with Cython to call from Python?
Currently, we have to carry copies of each VimbaPython package in our python libraries. This means if you make updates here on VimbaPython, we have to realize that and manually update our copies too. Having VimbaPython on PyPI as is would already address this pain point. Wanted to bring it to your consideration.
VimbaC is actually already a shared library. It is provided as part of the Vimba SDK as VimbaC.dll
or libVimbaC.so
depending on your operating system. VimbaPython simply loads these shared libraries via ctypes
and calls the exposed functions from them as needed.
That said, the points I described above still stand and there are currently no concrete plans to package the needed shared libraries with VimbaPython and providing them as a single binary distribution. However I do have the topic in my backlog for our Python API and will continue to investigate what we can do to make the installation easier and quicker. For the time being I am afraid the process for you to get the newest version of VimbaPython is still to:
pip install -U <path/to/VimbaPython/that/was/distributed/with/new/Vimba/SDK>
Currently we are not planning to publish VimbaPython on PyPI. The reason for this is that VimbaPython is not really a library that can be used on it's own. In order to use it our VimbaC library needs to be available and compatible Transport Layers need to be installed on the system. This means that the user has to also download our SDK Vimba from our website and install it. Providing VimbaPython on it's own would signal, that the user only has to run
pip install VimbaPython
and can immediately start using it. By instead distributing VimbaPython with our entire SDK (as we are doing now - VimbaPython is bundled in the Vimba installer) it is clear that the different APIs are part of an entire package.Additionally during startup VimbaPython checks the detected version of the VimbaC library to ensure, that it was loaded in a compatible version. This is important as our internal validation checks the SDK as one large package. It might happen, that components of VimbaC change slightly requiring an equivalent change in VimbaPython. By providing both in the same package it is easier to ensure only compatible versions are released together. Allowing users to install VimbaPython from PyPI could lead to cases, where an old version of VimbaC is installed on the users system and a new, possibly incompatible, version of VimbaPython is downloaded from PyPI.
These reasons lead to our decision to not publish VimbaPython via PyPI for the moment. However if good solutions for these problems are found we would be open to changing this decision.
Thank you for your interest in VimbaPython!