Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Radiometric data on Lepton 3.5 #86

Open
Hrishikesh-Kalyanaraman opened this issue Aug 1, 2023 · 5 comments
Open

Radiometric data on Lepton 3.5 #86

Hrishikesh-Kalyanaraman opened this issue Aug 1, 2023 · 5 comments

Comments

@Hrishikesh-Kalyanaraman
Copy link

Hrishikesh-Kalyanaraman commented Aug 1, 2023

I am trying to get radiometric data from my lepton. I have successfully connected to my device and received a numpy array. However, I'm unsure what exactly this array means. It does not seem like it represents temperature data in micro kelvin like this issue mentions: #53 as when I try to get the largest value from my array, it is always 58744 regardless of other data.

How do i get radiometric data from the lepton?

to recreate error condition, get an image from the lepton 3.5 and print(np.max(image, 0)). 58744 is always in the same place in the array generated irrespective of temperature [ (1,7) where the first object is at (0,0)]

I have tried using the groupgets software, and the camera seems fine. I have also used opencv directly, and this is the output i get when i do it

@jveitchmichaelis
Copy link
Contributor

Hi,

Please provide a sample image. I would guess 58744 is some telemetry value but it's impossible to say without seeing any data. If you have TLinear mode on, the results should be in Kelvin / 100.

Thanks!

@Hrishikesh-Kalyanaraman
Copy link
Author

Hrishikesh-Kalyanaraman commented Aug 1, 2023

How would I turn tlinear mode on? Is it automatically turned on with flirpy?

My numpy array of the image is a 160×120 array, so im not sure how I can share it

@jveitchmichaelis
Copy link
Contributor

If you're using the Pure Thermal board then you should use their configuration tools. Flirpy doesn't offer any config for the Lepton at the moment.

You could save it with np.save for example?

@Hrishikesh-Kalyanaraman
Copy link
Author

Hrishikesh-Kalyanaraman commented Aug 2, 2023

It seems like you were right. I checked data by row, and the last 2 rows are radiometric data, which was screwing with my results. Thank you!

On the other hand, I seem to have an issue on Linux where the camera disconnects after I access it 10-12 times on Linux. I did not have this issue on Windows. I suspect it might be because Linux reads multiple video devices for some reason. My issue is the same as this one: #75

@jveitchmichaelis
Copy link
Contributor

jveitchmichaelis commented Aug 2, 2023

Unfortunately my answer would be the same - speak to PureThermal or OpenCV because the opening/closing of the camera is done via those libraries, not Flirpy. It's possible that we're not closing/releasing the camera properly so what you could try is writing your own code where you open and close the camera repeatedly and see if you can trigger this fault. You could also try playing with GroupGets' software and seeing if that has the same problem or not.

Flirpy should call camera.release() when you close the context (e.g. if using with Lepton() as camera or delete the object. That calls cv2.VideoCapture.release() underneath.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants