12-bit Pixel Format using Python Harvester
I have been trying to interface to the MityCam-C50000 using python and the harvesters library, and have been having trouble getting 12-bit data. When requesting the data from the payload component, I get an Attribute error stating: 'NoneType' object has no attribute 'data'. This happens when the PixelFormat.value is set equal to either 'Mono12p' or 'BayerBG12p'. If the PixelFormat.value is set to either 'Mono8' or 'BayerBG8', the program works as expected. I've attached an HTML document which was generated using pydoc which I have been using to understand the way the harvester module is setup.
Thank you for your support.
I was looking at this page, which has an example, but it looks like it was for 8 bit as well....
When time permits, we'll look at testing with 12 bit mode here with python + harversters.
It looks like the version of havesters you are using doesn't appear to support the Mono12p and Bayer12p (according to the list of supported formats in the data section on the HTML page).
It might be worth asking the question with the harvester developer, they may not support the "packed" formats. Mono12p and Mono12 are packed differently, according to the Pixel Format Naming Convention documents.
The packed formats don't appear on the HTML page (which I'm unsure why that is) but they are listed in pfnc.py . I have tried including 'from harvesters.util.pfnc import mono_packed_location_formats' at the beginning of the script but it still gives me the same attribute error.
You might post to the chat/gitter room or open a ticket on the github site
for the harverster stuff:
The project owner is very good about supporting this stuff. I suspect this
is likely a problem in the harvester layer.
On Tue, Jul 9, 2019 at 4:03 PM <email@example.com> wrote: