Author Topic: RPi/SBC/Topdon TC001/clone Tester request (Thermal Camera Redux v0.9.3) Github  (Read 14650 times)

0 Members and 1 Guest are viewing this topic.

Offline G28Topic starter

  • Regular Contributor
  • *
  • Posts: 74
  • Country: us
    • Thermal Camera Redux
UPDATE:

2024-01-27: Version 0.9.3 modifications have been pushed to github to optionally build with dynamic border layout.
2024-01-25: Version 0.9.2 modifications have been pushed to github to optionally lock out camera's colormap auto-ranging.
2024-01-18: Version 0.9.1 modifications have been pushed to github for weak and single threaded/single core hardware.

"Thermal Camera Redux" is being posted to Github. 

All future updates will be available there free, for personal, non-commercial use.

No Microsoft, Apple or similar app stores required.  :)

Vive la Open Source !!!

https://github.com/92es/Thermal-Camera-Redux



UPDATE: The Python script has been abandoned in favor of a port to C/C++ for optimization and threading concerns.

I have been modifying Les Wright's PyThermalCamera python script on Debian 11 and would like to know if there are any RaspPi/Topdon TC001 users out there that would like to test the potential RasbPi bug fixes and new features.

I think I may have fixed the Fullscreen transitioning issues in addition to the following additional mods.

- Added Fahrenheit temp displays and toggle key to switch between F and C
- Floating MIN/MAX temps no longer get written off screen past the display edges.
- Floating MIN/MAX temps don't overwrite HUD menu text (but the target dots will to retain X,Y location).
- Added MIN/MAX temp labels.
- Added Frames Per Second display to HUD menu.
- Added ability to cycle backwards in addition to forwards through the color maps for quicker access.
- Added some speed optimizations in the animation loop.
- Added ability to have more scale modes based on your display size.  Note: larger scales require more CPU cycles.
- Added Fullscreen to cycling scale modes when max scale is exceeded.
- Scaling in Fullscreen mode automatically transitions to scaled resize windows when appropriate.
- Added window manager borders for additional move/resize, show/hide controls.
- Added some toggle keys.
- Some various visual changes to enhance readability.
- Fixed some minor issues.

If anyone is interested in testing the modded script, please let me know through PM or post in this thread.

NOTE: Min temp does not overwrite HUD text, but the blue dot in the upper left corner is free to float over the HUD menu according to its target location.



NOTE: If the HUD menu is turned off, the text moves close to the dot but does not get written off the top of the screen.  It slides slightly lower than the dot to stay in view on screen.



Thanks much to Les Wright for doing the heavy lifting on the Python script.  I have been looking for a thermal camera solution that doesn't tie me to a smart phone app and a lot of $$$.
« Last Edit: January 29, 2024, 12:00:34 am by G28 »
 
The following users thanked this post: Amish Technician

Offline G28Topic starter

  • Regular Contributor
  • *
  • Posts: 74
  • Country: us
    • Thermal Camera Redux
Re: RasbPi and Topdon TC001 (guinea pig) Tester requested
« Reply #1 on: November 15, 2023, 06:22:37 am »
After making yesterday's post, I realized there were some intermittent bugs in the calculation of the Min/Max/Avg temps and respective screen locations.  You can see the Min temp is higher than the crosshair temp in the original picture.

Fixing those bugs in Python is resources prohibitive, so I ported the code to C/C++ to get more optimizations.  The C++ OpenCV libraries are multi-threaded versus the single threaded Python library.  Processor utilization has gone down and frame rates are native for the Topcon TC001 (even with the bug fixes).

Here are both of the frames (top=image, bottom=thermal).  The C++ library has twice as many color maps plus the initial map so @ 23 in total.

Will be adding some more features with the extra headroom and possibly some frame manipulations (image rotate/flips, single/dual frame display, frame swap, etc.).

The thermal frame appears to have its merit.

Python is now in the rear view mirror.

« Last Edit: November 15, 2023, 06:26:45 am by G28 »
 

Offline G28Topic starter

  • Regular Contributor
  • *
  • Posts: 74
  • Country: us
    • Thermal Camera Redux
Re: RasbPi and Topdon TC001 (guinea pig) Tester requested
« Reply #2 on: November 17, 2023, 06:29:44 am »
Another update. 
    Added a few extra display formats (see picts below) as well as a handful of interpolation methods.
    Scaled fonts to grow/shrink with image scaling.
    Added ability to disable all graphical overlays.
    Added another thread to parallel thermal data harvesting and image preparation.
    Added hot key to reset all configurations to default.
    Did some prerf profiling and optimizations from the perf results.
    Will probably add a user defaults config file.
    Will be adding data logging over time for graphed analysis.
    Found some v4l2 APIs that should allow application control of the camera's following User Controls.

    Does anyone know what APIs control emissivity settings of the TC001 ?

    Any other feature ideas ?

    Tracking temp with mouse or arrow keys to move center crosshair temp ?

Code: [Select]
User Controls:
                     brightness 0x00980900 (int)    : min=-64 max=64 step=1 default=0 value=0
                       contrast 0x00980901 (int)    : min=0 max=100 step=1 default=50 value=50
                     saturation 0x00980902 (int)    : min=0 max=100 step=1 default=64 value=64
                            hue 0x00980903 (int)    : min=-180 max=180 step=1 default=0 value=0
        white_balance_automatic 0x0098090c (bool)   : default=1 value=1
                          gamma 0x00980910 (int)    : min=100 max=500 step=1 default=300 value=300
           power_line_frequency 0x00980918 (menu)   : min=0 max=2 default=1 value=1
0: Disabled
1: 50 Hz
2: 60 Hz
      white_balance_temperature 0x0098091a (int)    : min=2800 max=6500 step=10 default=4600 value=4600 flags=inactive
                      sharpness 0x0098091b (int)    : min=0 max=100 step=1 default=50 value=50
         backlight_compensation 0x0098091c (int)    : min=0 max=1 step=1 default=0 value=0


Single Image Frame:


Single Thermal Frame:


Dual Horizontal Image / Thermal Frames:


Dual Vertical Image / Thermal Frames:
« Last Edit: November 17, 2023, 06:35:37 am by G28 »
 

Offline G28Topic starter

  • Regular Contributor
  • *
  • Posts: 74
  • Country: us
    • Thermal Camera Redux
Re: RasbPi and Topdon TC001 (guinea pig) Tester requested
« Reply #3 on: November 17, 2023, 09:51:11 am »
And another update. 

Here is a feature to monitor/log multiple user locations of interest at once (in addition to the existing monitoring points).

Add more monitoring points by clicking on the display.

This could be useful when doing bench work with the camera on a fixed stand and fixed work piece.

 

Offline G28Topic starter

  • Regular Contributor
  • *
  • Posts: 74
  • Country: us
    • Thermal Camera Redux
Re: RasbPi and Topdon TC001 (guinea pig) Tester requested
« Reply #4 on: November 20, 2023, 05:57:50 am »
Not much more to add other than some more threading and rendering profiling optimizations.

High/Low alarm snapshots and recordings will probably go in next.

Time to put it to good use.

 

Offline G28Topic starter

  • Regular Contributor
  • *
  • Posts: 74
  • Country: us
    • Thermal Camera Redux
Re: RasbPi and Topdon TC001 (guinea pig) Tester requested
« Reply #5 on: November 21, 2023, 06:58:14 am »
Today's new feature.

Added optional colormap scale (right side of the screen) and controls to lock/unlock colormap auto-ranging.

« Last Edit: November 21, 2023, 10:38:52 am by G28 »
 

Offline G28Topic starter

  • Regular Contributor
  • *
  • Posts: 74
  • Country: us
    • Thermal Camera Redux
Re: RasbPi and Topdon TC001 (guinea pig) Tester requested
« Reply #6 on: November 22, 2023, 09:58:14 am »
Added movable horizontal and vertical temperature rulers.


 

Offline ZigmundRat

  • Regular Contributor
  • *
  • Posts: 126
  • Country: us
Re: RasbPi and Topdon TC001 (guinea pig) Tester requested
« Reply #7 on: November 23, 2023, 05:15:11 pm »
Thanks for sharing this and posting the updates. Following with some interest  :popcorn:
 
The following users thanked this post: G28

Offline G28Topic starter

  • Regular Contributor
  • *
  • Posts: 74
  • Country: us
    • Thermal Camera Redux
Portrait and Landscape Rotations in 90 degree increments
« Reply #8 on: December 02, 2023, 06:33:51 pm »
Added Portrait and Landscape video rotations in 90 degree increments to all of the scaling and layout formats to compensate for the camera orientation (USB port location top/bottom/left/right) and cable management.

Window height/width ratios and graphics overlays adjust accordingly to current rotation.

Added 5 user defined color maps in addition to all of the OpenCV C++ stock color maps.

Added realtime crosshair temp tracking indicator ">" to the color map gradient bar along with a few distributed temps along the gradient scale for reference.

Portrait Rotations:



Landscape Rotations:

« Last Edit: December 02, 2023, 06:47:16 pm by G28 »
 

Offline G28Topic starter

  • Regular Contributor
  • *
  • Posts: 74
  • Country: us
    • Thermal Camera Redux
Twilight Color Map
« Reply #9 on: December 02, 2023, 06:53:11 pm »
FWIW, the "Twilight" color map does a great job of literally illuminating uninsulated walls.

 

Offline G28Topic starter

  • Regular Contributor
  • *
  • Posts: 74
  • Country: us
    • Thermal Camera Redux
Coming next ...
« Reply #10 on: December 02, 2023, 08:35:56 pm »
After using the camera, taking snapshots and videos, I still routinely have questions afterwards about the captured data. 

Since static images can't answer those questions (what is the temp gradient over there, what would it look like with a different colormap or interpolation method, etc.), it appears post processing analysis would address those questions.

Should be able to take stills and videos of the raw data frames and then offline, play them back through the app doing everything to the captured stills/streams as if they were live from the camera, recreating the exact thermal environment that existed when the stills/streams were captured.  It will allow one to recreate almost anything one forgot to do when it was live.

This offline post processing will facilitate examination of temps anywhere on the screen, switching between C/F, application of any color map, threshold, onscreen display, layout formats, scaling/fullscreen, interpolation method, blur setting, contrast setting, take composited snapshots, composited recordings with varied configurations, etc.

This feature is probably more important for documentation than pre-composited stills and videos.
« Last Edit: December 02, 2023, 08:52:44 pm by G28 »
 

Offline G28Topic starter

  • Regular Contributor
  • *
  • Posts: 74
  • Country: us
    • Thermal Camera Redux
Re: RasbPi and Topdon TC001 (guinea pig) Tester requested
« Reply #11 on: December 02, 2023, 11:09:52 pm »
Thanks for sharing this and posting the updates. Following with some interest  :popcorn:

If you have a Topdon TC001 or equivalent, you are welcome to try the app on Linux.
 

Offline G28Topic starter

  • Regular Contributor
  • *
  • Posts: 74
  • Country: us
    • Thermal Camera Redux
Re: RasbPi and Topdon TC001 (guinea pig) Tester requested
« Reply #12 on: December 04, 2023, 06:07:13 am »
Offline post processing of raw stills is up and running. 

Offline post processing of looped raw video clips will be next.

Can now go back and pull data not captured in the .png snapshots.
 

Offline Amish Technician

  • Contributor
  • Posts: 30
  • Country: gb
Re: RasbPi and Topdon TC001 (guinea pig) Tester requested
« Reply #13 on: December 05, 2023, 07:04:48 pm »
I'm also following with some interest, thanks for posting.

I have a Topdon TC001 and various RaspPi's and I'm interested in giving this a try. Where can I find it, is it on github or somewhere like that?
 
The following users thanked this post: 5U4GB, G28

Offline G28Topic starter

  • Regular Contributor
  • *
  • Posts: 74
  • Country: us
    • Thermal Camera Redux
Another update
« Reply #14 on: December 06, 2023, 03:19:26 am »
- Both offline raw still and video post processing is working, but the raw video could use some stream compression.
- Updated temp marker locations to be centered in the scaled/interpolated pixels vs the North West corner.
- Added left mouse button drag functionality to position the horizontal and vertical temp rulers.
- In honor of James Doohan locking himself into the pattern buffer in an infinite loop, I added "Freeze Frame" functionality to the live video camera feeds and offline raw video playback.  This allows one to change configuration options on the frozen frame (live or playback), analyze and take snapshots.


 

Offline G28Topic starter

  • Regular Contributor
  • *
  • Posts: 74
  • Country: us
    • Thermal Camera Redux
Re: RasbPi and Topdon TC001 (guinea pig) Tester requested
« Reply #15 on: December 06, 2023, 03:47:22 am »
I'm also following with some interest, thanks for posting.

I have a Topdon TC001 and various RaspPi's and I'm interested in giving this a try. Where can I find it, is it on github or somewhere like that?

PM Sent
 
The following users thanked this post: Amish Technician

Offline G28Topic starter

  • Regular Contributor
  • *
  • Posts: 74
  • Country: us
    • Thermal Camera Redux
Another Update
« Reply #16 on: December 07, 2023, 03:42:28 am »
Increased the number of colormaps to 37

Adding default startup configurations.

Added initial pass of optional Histogram Equalization filtering for monochrome colormaps. 

Somewhat underwhelming but may have some utility.    :-[



« Last Edit: December 07, 2023, 05:49:40 am by G28 »
 

Offline ZigmundRat

  • Regular Contributor
  • *
  • Posts: 126
  • Country: us
Re: RasbPi and Topdon TC001 (guinea pig) Tester requested
« Reply #17 on: December 07, 2023, 02:40:53 pm »
Don’t have one yet, but it’s on my short list :) Still following, I just don’t have the time or space at the moment (still settling in after moving house). Any suggestions for what the minimum platform would be? There are many rPi versions now.
« Last Edit: December 07, 2023, 02:47:23 pm by ZigmundRat »
 

Offline G28Topic starter

  • Regular Contributor
  • *
  • Posts: 74
  • Country: us
    • Thermal Camera Redux
Re: RasbPi and Topdon TC001 (guinea pig) Tester requested
« Reply #18 on: December 07, 2023, 06:52:43 pm »
Don’t have one yet, but it’s on my short list :) Still following, I just don’t have the time or space at the moment (still settling in after moving house). Any suggestions for what the minimum platform would be? There are many rPi versions now.

I am using it on a Debian 11 PC with a 14' USB cable and tripod.  No reason why you can't use a Linux PC/Laptop (or Linux VM Guest).  Sooner or later I will try it on a ProxMox Linux guest.

I don't have a RasbPi, but we may have a RasbPi guinea pig tester providing that feedback soon. 

It is built with OpenCV 4.5.1 (latest version is 4.8.0) and some of the features require minimum versions of OpenCV such as the Histogram Equalization API.

I will probably be adding 2D and maybe 3D plots soon if I can find/decide on a descent plotting library.  More features tend to require more CPU cycles. 

Could also dump the data in a suitable format for use with MATLAB/GNU Octave plotting.

Octave Example Plots:


P.S.

FWIW, the Topdon USA site had the TC001 for $195 a couple of weeks ago, but they appear to have jumped back to $230.
« Last Edit: December 07, 2023, 08:33:39 pm by G28 »
 

Offline ZigmundRat

  • Regular Contributor
  • *
  • Posts: 126
  • Country: us
Fair enough. I have plenty of laptops available. It would be neat if it were possible to get this running on a pico in some fashion. It will be interesting to see if it will run on a Pi 4, probably no problem on a Pi 5 but I don't have one yet. My goal is just to have something self-contained that doesn't need to be plugged in.
 

Offline G28Topic starter

  • Regular Contributor
  • *
  • Posts: 74
  • Country: us
    • Thermal Camera Redux
Fair enough. I have plenty of laptops available. It would be neat if it were possible to get this running on a pico in some fashion. It will be interesting to see if it will run on a Pi 4, probably no problem on a Pi 5 but I don't have one yet. My goal is just to have something self-contained that doesn't need to be plugged in.

You would still need a reasonable display.
 

Offline G28Topic starter

  • Regular Contributor
  • *
  • Posts: 74
  • Country: us
    • Thermal Camera Redux
Thermal Camera Redux - Feature Update
« Reply #21 on: December 08, 2023, 02:12:17 am »
Added an enhanced mode to the horizontal and vertical rulers.

In addition to displaying 7 vertical and horizontal temps that can be dragged around the screen, a hairline average temp reference horizontal and vertical (black) line has been added. 

In addition to that reference (black) line, another plot (white) line is added representing all of the temps (256 + 192) for the current row and column, on, above or below the average temp reference line.  This reference line is drawn centered under the '+' temp markers in the ruler.

This allows one to visually see relative spikes and dips relative to the average baseline along both rulers as they move around the screen.

« Last Edit: December 08, 2023, 03:00:34 am by G28 »
 

Offline ZigmundRat

  • Regular Contributor
  • *
  • Posts: 126
  • Country: us
The standard LCD display for the pi 3/4 is 800x480 (with HDMI an option). How does that resolution fit with the application? I’m afraid I’m not familiar with the original Python app either.

With the LCD, it’s under 10W with a pi3. I’m not sure how much the TC001 consumes, but I think this portable operation should be possible. A reasonably sized LiPo battery should provide 2 hours or more of continuous operation.
 

Offline G28Topic starter

  • Regular Contributor
  • *
  • Posts: 74
  • Country: us
    • Thermal Camera Redux
The standard LCD display for the pi 3/4 is 800x480 (with HDMI an option). How does that resolution fit with the application? I’m afraid I’m not familiar with the original Python app either.

With the LCD, it’s under 10W with a pi3. I’m not sure how much the TC001 consumes, but I think this portable operation should be possible. A reasonably sized LiPo battery should provide 2 hours or more of continuous operation.

Ya killing me !!!  Back to building a ship in a bottle.   ;D

I rebuilt with a max screen resolution of 800 x 480 and get a max scale factor of 2X.

Here is native resolution @ 1X scale.



Here is 2X scale with and without the onscreen display.



This one has some random user defined temp locations added.



The ruler's display with 7 x 7 temps would have to be paired down by at least half, maybe 4 x 4 temps or 3 x 3 temps.

The software could be configured to conditionally compile out features for paired down use cases.

Double wide and double high layout displays would have to be done in 1X scaling to fit 800x480.

I am running @ 2560x1600 and get up to 8X scale with that resolution.

Fonts could be scaled smaller, but you may need to get out your spectacles.
« Last Edit: December 08, 2023, 04:43:13 am by G28 »
 

Offline G28Topic starter

  • Regular Contributor
  • *
  • Posts: 74
  • Country: us
    • Thermal Camera Redux
Quote from: ZigmundRat
The standard LCD display for the pi 3/4 is 800x480 (with HDMI an option). How does that resolution fit with the application? I’m afraid I’m not familiar with the original Python app either.

With the LCD, it’s under 10W with a pi3. I’m not sure how much the TC001 consumes, but I think this portable operation should be possible. A reasonably sized LiPo battery should provide 2 hours or more of continuous operation.

I spent a little time fine tuning the font and marker scaling for 1X and 2X scale.  Need to get a smaller resolution monitor to test on, but it looks like the 7 x 7 rulers will work on both resolutions.

The images have the one of the new ruler modes.  The pictured mode shows current row temp plots relative to Min/Avg/Max temps.

Ruler modes now have:

    - Single moveable temp
    - 7 x 7 movable temps
    - 7 x 7 movable temps with Horizontal (current row) Min/AvgMax temp plots
    - 7 x 7 movable temps with Vertical (current column) Min/AvgMax temp plots
    - 7 x 7 movable temps with both Horizontal and Vertical (current row and column) Min/AvgMax temp plots


1X Scale:


2X Scale:
« Last Edit: December 08, 2023, 09:44:30 pm by G28 »
 

Offline ZigmundRat

  • Regular Contributor
  • *
  • Posts: 126
  • Country: us
That looks reasonable to me. Nice that the temp plots are movable. Do they toggle on/off as well?
I really need to get one of these to play with. I'd like to check for cold spots/heat leaks in the house, not to mention all the other typical uses. I'll go stuff one in my amazon cart.

I know you transitioned from Python to C/C++. What's the build environment? Basic configure/makefile stuff or under VSCode or ... ?
 

Offline G28Topic starter

  • Regular Contributor
  • *
  • Posts: 74
  • Country: us
    • Thermal Camera Redux
That looks reasonable to me. Nice that the temp plots are movable. Do they toggle on/off as well?
I really need to get one of these to play with. I'd like to check for cold spots/heat leaks in the house, not to mention all the other typical uses. I'll go stuff one in my amazon cart.

I know you transitioned from Python to C/C++. What's the build environment? Basic configure/makefile stuff or under VSCode or ... ?

I made some more refinements.  The horizontal ruler only has horizontal temps, the vertical ruler on has vertical temps.  Can pretty much do any configuration.  I am entertaining feature requests.  So far, I am adding what I would use.

There are 3 "onscreen" display modes (not to be confused with scaling and layout modes).

    - Menu + Graphics + Video
    - Graphics + Video
    - Video only

You can also adjust the "Threshold" setting until the Min/Max temps appear or disappear.  This was one of the base options in the Python script.

Right now the 'o' key starts and cycles through all of the ruler configurations.  The right mouse button kicks it out of ruler mode and back into user defined temp location mode.  The app currently works in those 2 mutually exclusive modes because of the shared left mouse button usage.

I hate making Makefiles and cmake is overkill.  Right now the code is contained in a single ".cpp" file.  The single g++ line has a CFLAGS and a DEFAULT_FLAGS line broken out to define default startup configuration options and specific platform flags.  All is in a single bash script.

It was built on OpenCV 4.5.1.  Latest version is 4.8.0.  Some of the OpenCV APIs require minimum versions.

It also requires the pthread library.

I experimented with CUDA optimizations, but NVIDIA CUDA is not required for the build and was removed from the build script.

Here is the build script:

Code: [Select]
#!/bin/bash

# Build Thermal Camera Redux

rm ./redux

# Change build flags based on your hardware
CFLAGS='-mavx2 -msse4.2 -msse4.1 -malign-double -march=skylake'

# Setup default startup configuration options

# ROTATION options:         0, 90, 180, 270
# USE_CELSIUS options:      0, 1
# DEFAULT_COLORMAP options: 0 - 36

# 800x480 is a max of 2X scale
#DEFAULT_FLAGS='-DDEFAULT_COLORMAP=4 -DROTATION=0 -DDISPLAY_WIDTH=800 -DDISPLAY_HEIGHT=480 -DUSE_CELSIUS=0'

DEFAULT_FLAGS='-DDEFAULT_COLORMAP=4 -DROTATION=0 -DDISPLAY_WIDTH=2560 -DDISPLAY_HEIGHT=1600 -DUSE_CELSIUS=0'

g++ -Wall -O3 ${DEFAULT_FLAGS} ${CFLAGS} -I/usr/include/opencv4 tc001.cpp -o redux -lpthread `pkg-config --cflags --libs opencv4`


Here are the usage and keybinding statement:

Code: [Select]
Thermal Camera Redux:
Ported and updated C/C++ app based on Les Wright's 21 June 2023 Python app
https://youtube.com/leslaboratory

A multi-threaded C/C++ app to read, parse, display thermal data from the Topdon TC001 Thermal camera
Rewritten with additional functionality, bug fixes, optimizations and offline post processing
Built with display 2560x1600, max:default scale 8:4, rotation 0, default Fahrenheit, 37 colormaps, Jet

Camera Usage:
./redux n (where 'n' is the number of the desired video camera)

Offline Usage:
./redux -f input.raw (where input.raw is a raw dump file from ./redux)

Key Bindings:

a z: [In|De]crease Blur
s x: Relative Min/Max temp display threshold delta from Avg temp
d c: Change interpolated window scale [camera native to fullscreen]
f v: [In|De]crease Contrast
g b: Cycle [for|back]wards through interpolation methods
j m: Cycle [for|back]wards through Color[m]aps
w  : Cycle through single/dual[horizontal/vertical] [w]indow layouts
G  : Toggle between fullscreen and current scaled window size
r  : Toggle [r]ecording (both .avi and offline .raw)
R  : Reset defaults
p  : Sna[p]shot (both .png and offline .raw)
h  : Cycle through overlayed screen data
t  : Toggle between Celsius and Fahrenheit
y  : Toggle Historgram filter (for gray scales)
8  : Rotate display 0, 90, 180, 270 degrees (Portrait and Landscape)
e  : Toggle Freeze Frame on/off
o  : Displays and cycles through 5 temp ruler modes
   : Keypad Up/Down/Left/Right/Center(5) moves rulers
   : Left mouse adds user temps or moves rulers
   : Right mouse removes user temps and disables ruler mode
?  : Misc stdout help information
q  : Quit

main(2868): Opening cameara /dev/video0


Here are some snapshots of the horizontal ruler.  It is obvious the hottest part of the flatscreen's electronics is on the right side.



« Last Edit: December 09, 2023, 07:56:39 am by G28 »
 

Offline G28Topic starter

  • Regular Contributor
  • *
  • Posts: 74
  • Country: us
    • Thermal Camera Redux
(Thermal Camera Redux) - Another ruler modification
« Reply #27 on: December 09, 2023, 10:34:36 pm »
Les's original Python script has a user adjustable threshold delta (in degrees Celsius) from the average screen temperature which determines if the Min/Max temps are shown or not.

I incorporated this user adjustable +/- threshold relative to the average temp into the ruler plots. 

The delta now also represents the current F/C unit selection.

    - If the row or column temp is within +/- threshold degrees from average, the temp plot will be white.
    - If the row/column temp is greater than threshold degrees, the plot will turn green.
    - If the row/column temp is less than threshold degrees, the line plot will turn red.

This gives another visual queue to the relative selected row or column temp plots and is adjustable from [0-N] degrees C/F.

« Last Edit: December 09, 2023, 10:38:25 pm by G28 »
 

Offline Amish Technician

  • Contributor
  • Posts: 30
  • Country: gb
Working very well on pi4 4GB

My modified build script:

Code: [Select]
#!/bin/bash

# Build Thermal Camera Redux

rm ./redux

# Change build flags based on your hardware
CFLAGS='-mcpu=cortex-a72 -ftree-vectorize -O3 -pipe -fomit-frame-pointer'

# Setup default startup configuration options

# ROTATION options:         0, 90, 180, 270
# USE_CELSIUS options:      0, 1
# DEFAULT_COLORMAP options: 0 - 36

DEFAULT_FLAGS='-DDEFAULT_COLORMAP=4 -DROTATION=0 -DDISPLAY_WIDTH=1920 -DDISPLAY_HEIGHT=1080 -DUSE_CELSIUS=1'

g++ -Wall -O3 ${DEFAULT_FLAGS} ${CFLAGS} -I/usr/include/opencv4 tc001.cpp -o redux -lpthread `pkg-config --cflags --libs opencv4`

./redux


Excellent work  :D  :-+
 
The following users thanked this post: ZigmundRat, G28

Offline G28Topic starter

  • Regular Contributor
  • *
  • Posts: 74
  • Country: us
    • Thermal Camera Redux
AT,

Thank you for testing on the RaspPi.  Glad to hear it works on the Pi4.

Just sent you an update with the latest changes. 

The new plotting rulers may take some more CPU cycles and there maybe some thread load balancing to be had to keep the FPS up.
 

Offline RO

  • Contributor
  • Posts: 45
  • Country: nl
I have picked up one of those Victor 256 usb dongle imagers which works perfectly with the Topdon TC001 app, and have a Pi Zero 2W available, and could eventually free up a Pi4B, wouldn't mind testing if it will work with you app/script. The Victor imager seems equivalent, not sure if there might be a different protocol.

Am a bit busy though so might take me a while to produce adequate feedback if it requires a lot of configuration.
 

Offline G28Topic starter

  • Regular Contributor
  • *
  • Posts: 74
  • Country: us
    • Thermal Camera Redux
I have picked up one of those Victor 256 usb dongle imagers which works perfectly with the Topdon TC001 app, and have a Pi Zero 2W available, and could eventually free up a Pi4B, wouldn't mind testing if it will work with you app/script. The Victor imager seems equivalent, not sure if there might be a different protocol.

Am a bit busy though so might take me a while to produce adequate feedback if it requires a lot of configuration.

You are more than welcome to test and provide feedback.  It appears there are a lot of clones of this device so the software may work on many of them.

Amish Technician has been generously testing and providing valuable feedback on a Pi4 and may be trying it on a Pi Zero 2 if/when he has time.   

I am not familiar with the Pi models so don't have any idea how it will do on a Pi Zero 2. 

Setup is pretty easy if you have the libraries installed, but someone will have to come up with the compile flags for the Pi Zero 2.

AT is reporting @ 50% CPU usage @ 5X scale for the double wide display (2560 x 960) with both rulers active (18 temps) for the current version on the Pi4 if that is of any hint.  Compared to the Python script, that is pretty good considering the additional functionality.  The Python script was single threaded and would peg out the thread on my i7-9700 just calculating the temps correctly.

Scaling and interpolation are CPU intensive.  Dragging is also CPU intensive, but it can run in jump-scroll mode (point and click).  Keeping that in mind, the features can be scalable (or avoided) based on the platform's processing power.

Just figured out how to add configurable transparencies at AT's request so the OSD menus now show the video underneath. 

Also made some optimizations over the last few days to speed up dragging and renders for weaker processors.

PM me if you want to figure out the Pi Zero 2 flags, or you can use the existing Pi4 flags if you free up your Pi4 or want to run it on a PC.

New Translucent OSD:


Other updates from AT's feedback:

- Added loss of camera connection recovery functionality.  If connection is lost, app goes into FreezeFrame mode displaying the last frame and an error message until connections are corrected.
- Reworked font and widget scaling so they plateau at given scaling levels.
- Added average temp indicator '-' to the color map gradient scale on right.  I use it more than the avg  temp in the OSD.
- Color coded average temp indicator '-' and crosshair temp indicator '>' on the gradient scale the same as the ruler plots using the configurable Threshold delta.
« Last Edit: December 13, 2023, 04:50:07 am by G28 »
 
The following users thanked this post: RO

Offline G28Topic starter

  • Regular Contributor
  • *
  • Posts: 74
  • Country: us
    • Thermal Camera Redux
(Thermal Camera Redux) - OSD Help
« Reply #32 on: December 16, 2023, 02:39:47 am »
Added optional translucent OSD keyboard and mouse usage help today.

Note: Video Blur is set in this image capture.

« Last Edit: December 17, 2023, 08:05:14 pm by G28 »
 
The following users thanked this post: ZigmundRat, BTI, Amish Technician

Offline G28Topic starter

  • Regular Contributor
  • *
  • Posts: 74
  • Country: us
    • Thermal Camera Redux
(Thermal Camera Redux) - FreezeFrame and Offline performance optimizations
« Reply #33 on: December 17, 2023, 07:51:17 pm »
Latest updates include significant performance optimizations in FreezeFrame and Offline modes.  This should enhance usability on weaker hardware.

Thanks to Amish Tech for testing on the RasbPi platforms and making valuable recommendations.

The following image shows automatic FreezeFrame mode when live camera communications are lost (e.g. cable disconnections).  Once errors are addressed, live feeds can resume by exiting FreezeFrame mode.

Note: Video Blur is set to 68 in this image capture.

When using live mode on weaker hardware, FreezeFrame mode can be manually entered which frees up significant resources for analyzing the captured frame with any of the app's more computationally intensive features.

« Last Edit: December 17, 2023, 08:15:50 pm by G28 »
 
The following users thanked this post: ZigmundRat, Amish Technician

Offline G28Topic starter

  • Regular Contributor
  • *
  • Posts: 74
  • Country: us
    • Thermal Camera Redux
Another minor update:

Made some refinements to the horizontal and vertical rulers as well as more thread balancing and optimizations to run better on SBC's.

 
The following users thanked this post: ZigmundRat, BTI, Amish Technician

Offline 5U4GB

  • Frequent Contributor
  • **
  • Posts: 391
  • Country: au
Is it Pi-specific or would it also work on alternatives like an Odroid?  I've got a TC001 that I usually use with the app via a U-adaptor for the USB-C port but it'd be nice to have an alternative way of driving it if they ever discontinue the app or the vendor goes away.
 

Offline G28Topic starter

  • Regular Contributor
  • *
  • Posts: 74
  • Country: us
    • Thermal Camera Redux
Is it Pi-specific or would it also work on alternatives like an Odroid?  I've got a TC001 that I usually use with the app via a U-adaptor for the USB-C port but it'd be nice to have an alternative way of driving it if they ever discontinue the app or the vendor goes away.

I am running the code on Debian 11 and Amish Technician is testing in various Rasb Pi models.

The app uses C/C++, pthreads and the opencv 4.51 library. 

If your platform is Linux based, it should probably work.
 

Offline Amish Technician

  • Contributor
  • Posts: 30
  • Country: gb
UPDATED: https://www.eevblog.com/forum/thermal-imaging/rasbpi-and-topdon-tc001-(guinea-pig)-tester-requested/25/#msg5270445

So far I have Thermal Camera Redux working on the following Pis with the 2023-12-05 release of Raspberry Pi OS desktop 64-bit (Debian 12 bookworm):

 :) RPi 2 Model B v1.2       BCM2837      ARMv8-A     (64/32-bit)   4× Cortex-A53 900 MHz   CFLAGS='-mcpu=cortex-a53 -pipe -fomit-frame-pointer'
 :) RPi 3 Model B v1.2       BCM2837B0  ARMv8-A     (64/32-bit)   4× Cortex-A53 1.4 GHz    CFLAGS='-mcpu=cortex-a53 -pipe -fomit-frame-pointer'
 :) RPi Zero 2 W                BCM2710A1  ARMv8-A     (64/32-bit)   4× Cortex-A53 1 GHz       CFLAGS='-mcpu=cortex-a53 -pipe -fomit-frame-pointer'
 :D RPi 4                             BCM2711       ARMv8-A    (64/32-bit)   4× Cortex-A72 1.8 GHz    CFLAGS='-mcpu=cortex-a72 -pipe -fomit-frame-pointer'
 ;D RPi 5                             BCM2712      ARMv8.2-A  (64/32-bit)   4× Cortex-A76 2.4 GHz    CFLAGS='-mcpu=cortex-a76 -pipe -fomit-frame-pointer'

Performance is very good on the pi4 at x4 scale, x5 slightly reduces the frame rate. It's especially good on pi5 up to x5, and still keeps the responsiveness and frame rate usable up to x7. It's very responsive on the others as well so long as you stay at 3x scale or lower, x4 is still usable with a frame rate ~20.

I'm still working on:

RPi Zero v1.3                    BCM2835    ARMv6Z    (32-bit)       1× ARM1176JZF-S 1 GHz   VFPv2; NEON not supported
RPi 2 Model B v1.1           BCM2836    ARMv7-A   (32-bit)       4× Cortex-A7 900 MHz        VFPv4 + NEON

I think I also have a RPi 3 Model B+ but I won't be going to it for a few week. I can't imagine the result will be any different than the non + version anyhow, or for the model A variants I don't have.
I also don't have any of the original variants but I believe they use the same ARM1176JZF-S as the first pi zero so they will most likely work the same, or not, we'll see how I get on when the libopencv-dev package finishes downloading and installing on Raspberry Pi OS (Legacy, 32-bit) 2023-12-05 which is taking an eternity at the moment.  :=\
« Last Edit: January 10, 2024, 02:58:49 am by Amish Technician »
 
The following users thanked this post: RO, G28

Offline Amish Technician

  • Contributor
  • Posts: 30
  • Country: gb
Working on Pi zero v1.3 !!! the lowest powered Pi I have, result!

At x1 scale with the default HUD I have a usable average of 11.7 frames per second, there is some delay but it feels completely smooth. It's like the flirs and others with the 7 or so FPS limit, only slightly better.

The CPU is only slightly warm to the touch after ~5 minutes so I'm tempted to see if some overclocking helps. I may have to do something to stabilise the power supply first though as it caused the Pi zero to reboot when I plugged the TC001 in, none of the other pi's had this issue using the same power supply.


Pi2 v1.1 testing will have to wait for another day  :=\
 
The following users thanked this post: ZigmundRat, G28, BTI

Offline G28Topic starter

  • Regular Contributor
  • *
  • Posts: 74
  • Country: us
    • Thermal Camera Redux
More thermal ruler refinements
« Reply #39 on: January 01, 2024, 04:58:03 pm »
First of all, I wish to extend a big thanks to Amish Tech for his extensive testing on so many Rasb Pi platforms.  :-+ :-+ :-+ :-+

Adding more refinements to the thermal rulers as a result of using them on my own thermal audits.

The original rulers used a proportional distribution method relative the screen's average temp as shown in the 1st image.

This works fine until there are extreme outliers that skew the plot of the non-outlier temps (e.g. a light bulb in frame when looking for cold spots).

To address this, an equal distribution mode with outlier clipping has been added.  This allows you to visually recognize the details such as the min temperature drop in the lower right hand corner that is compressed in the proportional plot. 

Modes are toggled in real time with a hot key so it is fast/easy to compare plots.


« Last Edit: January 01, 2024, 05:00:11 pm by G28 »
 
The following users thanked this post: BTI, Amish Technician

Offline G28Topic starter

  • Regular Contributor
  • *
  • Posts: 74
  • Country: us
    • Thermal Camera Redux
Running "Headless"
« Reply #40 on: January 03, 2024, 07:28:06 pm »
FWIW, the app can be run "headless" from a remote machine by using X11 forwarding.

https://goteleport.com/blog/x11-forwarding/

Use "ssh -X username@ipaddress" to log into your remote machine that is running an X Server. 

It will not work with runlevel=3 that does not start the X server.

The -X ssh session automatically sets the DISPLAY environment variable in the ssh session.

Use the "xhosts" command on your local machine to allow remote X clients to display on your local machine.

You can then run a test X app (via CLI on the remote machine) to validate display on the local machine (e.g. xeyes or xterm).

Then run the redux OpenCV app.

It runs faster over the network than running the full remote desktop (less pixels to push), but not as fast as running locally without the network overhead.

As long as you have the X Server running on both ends, you should be able to remotely run the app "headless".

Hope this helps those with networked SBC's with no attached displays.


« Last Edit: January 03, 2024, 08:13:14 pm by G28 »
 

Offline 5U4GB

  • Frequent Contributor
  • **
  • Posts: 391
  • Country: au
Re: Running "Headless"
« Reply #41 on: January 04, 2024, 01:45:32 am »
FWIW, the app can be run "headless" from a remote machine by using X11 forwarding.

For people using MobaTerm (my preferred SSH client), it's usable directly, just start MobaTerm's built-in X server, enable X forwarding in the MobaTerm settings window for that session/host, and you're done.  You may optionally need to enable X in the SSH config on the target system, but it's usually enabled by default.

Having said that, I've just tested it with an xterm so far, still getting round to setting up the TC001 stuff.
 
The following users thanked this post: Amish Technician

Offline G28Topic starter

  • Regular Contributor
  • *
  • Posts: 74
  • Country: us
    • Thermal Camera Redux
2 more ruler clipping modes
« Reply #42 on: January 04, 2024, 02:12:49 am »
Added 2 more ruler clipping modes.
  • Proportional - no clipping
  • Equal - outlier clipping
  • Below average clipping - focus on above average temps
  • Above average clipping - focus on below average temps

Proportional:


Equal - outlier clipping:


Below average clipping:


Above average clipping:
 
The following users thanked this post: ZigmundRat, Amish Technician

Offline G28Topic starter

  • Regular Contributor
  • *
  • Posts: 74
  • Country: us
    • Thermal Camera Redux
Added adjustable ruler thickness in range [ 1/5, 1/4, 1/3, 1/2 ] screen height to all ruler modes.

1/5 screen height:



1/2 screen height:

 
The following users thanked this post: ZigmundRat, Amish Technician

Offline G28Topic starter

  • Regular Contributor
  • *
  • Posts: 74
  • Country: us
    • Thermal Camera Redux
Added 1/1 ruler thickness mode.

In this mode, the plot is full screen and becomes decoupled from the cross-hair temp grid. 

The cross-hair temp grid still moves around the screen as the plot updates, but the plot's position remains fixed relative to the upper left hand corner of the screen, no longer positioned relative the moving cross-hair temp grid.

All of the other ruler modes are available in this full thickness mode.

« Last Edit: January 04, 2024, 05:35:10 am by G28 »
 
The following users thanked this post: ZigmundRat, Amish Technician

Offline G28Topic starter

  • Regular Contributor
  • *
  • Posts: 74
  • Country: us
    • Thermal Camera Redux
Minor Updates:
« Reply #45 on: January 07, 2024, 04:41:59 am »
Minor Updates:

- Added user selectable fonts.
- Optimized ruler drag scrolling to increase performance on slower hardware.
- Made visual improvements for 1X and 2X scale, low resolution displays.

Dual full ruler display mode:

 
The following users thanked this post: ZigmundRat, Amish Technician

Offline G28Topic starter

  • Regular Contributor
  • *
  • Posts: 74
  • Country: us
    • Thermal Camera Redux
"Thermal Camera Redux" is being posted to Github. 

All future updates will be available there free, for personal, non-commercial use.

No Microsoft or similar app stores required.  :)

https://github.com/92es/Thermal-Camera-Redux
 
The following users thanked this post: Fraser, ZigmundRat, 5U4GB, BTI, Amish Technician

Offline Amish Technician

  • Contributor
  • Posts: 30
  • Country: gb
Fantastic seeing the project on Github  :-+ very cool  8)

I've finally tested the RPi 2 Model B v1.1 with the same version I tried on all the others, and release 16 which I haven't tried on the others yet. Here is an updated list with my suggested scaling for stock CPU clock speeds and performance notes:


Tested with the 2023-12-05 release of Raspberry Pi OS desktop 64-bit (Debian 12 bookworm):

RPi 5                             BCM2712      ARMv8.2-A  (64/32-bit)   4× Cortex-A76 2.4 GHz     CFLAGS='-mcpu=cortex-a76 -pipe -fomit-frame-pointer'    5x Excellent   7x Very usable   
RPi 4 / 400                    BCM2711       ARMv8-A    (64/32-bit)   4× Cortex-A72 1.8 GHz     CFLAGS='-mcpu=cortex-a72 -pipe -fomit-frame-pointer'    4x Very good  5x Very usable   ### RPi 400 Untested, higher stock CPU clock may yield slightly better performance
RPi Zero 2 W                BCM2710A1  ARMv8-A     (64/32-bit)   4× Cortex-A53 1 GHz        CFLAGS='-mcpu=cortex-a53 -pipe -fomit-frame-pointer'   3x Very good  4x usable
RPi 3 Model B v1.2       BCM2837B0  ARMv8-A     (64/32-bit)   4× Cortex-A53 1.4 GHz     CFLAGS='-mcpu=cortex-a53 -pipe -fomit-frame-pointer'   3x Very good  4x usable
RPi 2 Model B v1.2       BCM2837      ARMv8-A     (64/32-bit)   4× Cortex-A53 900 MHz    CFLAGS='-mcpu=cortex-a53 -pipe -fomit-frame-pointer'   3x Very good  4x usable


Tested with the 2023-12-05 release of Raspberry Pi OS desktop Legacy 32-bit (Debian 12 bookworm):

RPi 2 Model B v1.1       BCM2836      ARMv7-A     (32-bit)       4× Cortex-A7 900 MHz          CFLAGS='-mcpu=Cortex-A7 -pipe -fomit-frame-pointer'            2x Good with default HUD, 3x Usable. Struggles with extra window layout.
RPi Zero v1.3                BCM2835      ARMv6Z      (32-bit)       1× ARM1176JZF-S 1 GHz     CFLAGS='-mcpu=ARM1176JZF-S -pipe -fomit-frame-pointer'   1x with default HUD 11.7 fps average, some delay but smooth.
RPi 1                             BCM2835      ARMv6Z      (32-bit)       1× ARM1176JZF-S 700MHz  CFLAGS='-mcpu=ARM1176JZF-S -pipe -fomit-frame-pointer'   ### Untested. Variants with 512MB of RAM are likely to work but expect a very low frame rate, YMMV with the 256MB variants.

Model A, +, and compute modules have also not been tested but are likely to work the same as their model B counterparts. None Raspberry Pi SBCs that run a linux desktop may also work.


I'll go through my collection of RPIs again at some point soon as I noticed some image artefacts ('banding') which changed depending on how demanding the options where that I enabled. I only noticed this on some of the slower models, I need to check this again because I didn't note which models were affected as I initially assumed it was caused by the sensor in my camera. I'll use the latest version as my testing is a few versions behind now.

I also want to try the RPi zero v1.3 again with the last release I have before multi-threading was added, version 4 I believe, to see if it helps performance.

When time allows I'm also interested in testing "headless" using X11 forwarding, I haven't' attempted this at all yet. I'm sure a headless RPi zeroW / 2W could be a neat setup for some applications, very compact and portable.

Thank you again G28 for all the improvements and updates.  :-+
« Last Edit: January 10, 2024, 02:52:31 am by Amish Technician »
 
The following users thanked this post: ZigmundRat, G28

Offline G28Topic starter

  • Regular Contributor
  • *
  • Posts: 74
  • Country: us
    • Thermal Camera Redux
...
Tested with the 2023-12-05 release of Raspberry Pi OS desktop 64-bit (Debian 12 bookworm):
...
Tested with the 2023-12-05 release of Raspberry Pi OS desktop Legacy 32-bit (Debian 12 bookworm):
,,,
I also want to try the RPi zero v1.3 again with the last release I have before multi-threading was added, version 4 I believe, to see if it helps performance.
...
I'll use the latest version as my testing is a few versions behind now.
...

FWIW, the last releases (github) should be faster than the 12/5 release with the global font, halo and anti-alias changes which impact the HUD, HELP, temp text and marker displays across the board. 

Ruler drags should also be faster with the elimination of halo rendering during drag scrolls.
« Last Edit: January 10, 2024, 05:47:43 am by G28 »
 
The following users thanked this post: Amish Technician

Offline cynfab

  • Regular Contributor
  • *
  • Posts: 175
  • Country: us
Great job, It compiled easily on my MacBook Pro running Linux Mint, and displays a great image from my P2 Pro.

Thanks
1977252-0
 
The following users thanked this post: G28, Amish Technician

Offline G28Topic starter

  • Regular Contributor
  • *
  • Posts: 74
  • Country: us
    • Thermal Camera Redux
Great job, It compiled easily on my MacBook Pro running Linux Mint, and displays a great image from my P2 Pro.

Thanks
(Attachment Link)

Great.  Please post or PM any issues that you may encounter so I can try to address them.
« Last Edit: January 10, 2024, 03:15:21 pm by G28 »
 

Offline G28Topic starter

  • Regular Contributor
  • *
  • Posts: 74
  • Country: us
    • Thermal Camera Redux
For those running Linux, you might be interested in the tuned-adm package.

It controls your PC's scheduling and thread frequency SpeedStep controls providing a lot of profile options.

I usually switch between "desktop" and "latency-performance". 

When regression testing with a long duration redirected stdin command script, "latency-performance" and unrestricted offline FPS (-fps 900), the "latency-performance" setting finishes the script [3-5]X faster.

It may also be useful for your general purpose Linux use and performance targeted projects.

Code: [Select]
Available profiles:
- accelerator-performance     - Throughput performance based tuning with disabled higher latency STOP states
- atomic-guest                - Optimize virtual guests based on the Atomic variant
- atomic-host                 - Optimize bare metal systems running the Atomic variant
- balanced                    - General non-specialized tuned profile
- cpu-partitioning            - Optimize for CPU partitioning
- default                     - Legacy default tuned profile
- desktop                     - Optimize for the desktop use-case
- desktop-powersave           - Optmize for the desktop use-case with power saving
- enterprise-storage          - Legacy profile for RHEL6, for RHEL7, please use throughput-performance profile
- hpc-compute                 - Optimize for HPC compute workloads
- intel-sst                   - Configure for Intel Speed Select Base Frequency
- laptop-ac-powersave         - Optimize for laptop with power savings
- laptop-battery-powersave    - Optimize laptop profile with more aggressive power saving
- latency-performance         - Optimize for deterministic performance at the cost of increased power consumption
- mssql                       - Optimize for MS SQL Server
- network-latency             - Optimize for deterministic performance at the cost of increased power consumption, focused on low latency network performance
- network-throughput          - Optimize for streaming network throughput, generally only necessary on older CPUs or 40G+ networks
- optimize-serial-console     - Optimize for serial console use.
- oracle                      - Optimize for Oracle RDBMS
- postgresql                  - Optimize for PostgreSQL server
- powersave                   - Optimize for low power consumption
- realtime                    - Optimize for realtime workloads
- realtime-virtual-guest      - Optimize for realtime workloads running within a KVM guest
- realtime-virtual-host       - Optimize for KVM guests running realtime workloads
- sap-hana                    - Optimize for SAP HANA
- sap-netweaver               - Optimize for SAP NetWeaver
- server-powersave            - Optimize for server power savings
- spectrumscale-ece           - Optimized for Spectrum Scale Erasure Code Edition Servers
- spindown-disk               - Optimize for power saving by spinning-down rotational disks
- throughput-performance      - Broadly applicable tuning that provides excellent performance across a variety of common server workloads
- virtual-guest               - Optimize for running inside a virtual guest
- virtual-host                - Optimize for running KVM guests
Current active profile: desktop
« Last Edit: January 10, 2024, 10:57:36 pm by G28 »
 
The following users thanked this post: cynfab, Amish Technician

Offline RO

  • Contributor
  • Posts: 45
  • Country: nl

So far I have Thermal Camera Redux working on the following Pis with the 2023-12-05 release of Raspberry Pi OS desktop 64-bit (Debian 12 bookworm):

 :) RPi 2 Model B v1.2       BCM2837      ARMv8-A     (64/32-bit)   4× Cortex-A53 900 MHz   CFLAGS='-mcpu=cortex-a53 -pipe -fomit-frame-pointer'
 :) RPi 3 Model B v1.2       BCM2837B0  ARMv8-A     (64/32-bit)   4× Cortex-A53 1.4 GHz    CFLAGS='-mcpu=cortex-a53 -pipe -fomit-frame-pointer'
 :) RPi Zero 2 W                BCM2710A1  ARMv8-A     (64/32-bit)   4× Cortex-A53 1 GHz       CFLAGS='-mcpu=cortex-a53 -pipe -fomit-frame-pointer'
 :D RPi 4                             BCM2711       ARMv8-A    (64/32-bit)   4× Cortex-A72 1.8 GHz    CFLAGS='-mcpu=cortex-a72 -pipe -fomit-frame-pointer'
 ;D RPi 5                             BCM2712      ARMv8.2-A  (64/32-bit)   4× Cortex-A76 2.4 GHz    CFLAGS='-mcpu=cortex-a76 -pipe -fomit-frame-pointer'

Performance is very good on the pi4 at x4 scale, x5 slightly reduces the frame rate. It's especially good on pi5 up to x5, and still keeps the responsiveness and frame rate usable up to x7. It's very responsive on the others as well so long as you stay at 3x scale or lower, x4 is still usable with a frame rate ~20.


Well done  :-+

I am trying to achieve the same on the RPi Zero 2 W
I have installed Raspberry Pi OS desktop 64-bit without trouble but keep running into errors when installing OpenCV

Do you have any advice on the install?
- Compiling the source on the Pi (cmake)
- Memory increased to plentifull with swapfile
- Have added the contrib modules
- Cmake on all 4 cores -j4

Would also be interested in your -D flags

Thanks!
 

Offline Amish Technician

  • Contributor
  • Posts: 30
  • Country: gb
The initial github release has noticeably improved performance on the RPi Zero v1.3 compared to the last version I tried on it, I saw FPS up to 16.9 with no HUD, 13.8 with the default HUD.
The early pre multi threading version does indeed perform much worse. I wonder if a single threaded version of the current release with the numerous performance tweaks and improvements would run better on the single core single thread CPU of the Pi Zero.

The optional flags are a very useful addition.  :-+

Arrow keys aren't doing anything for me, I tried with two different keyboard, both were laptop style without a num-pad however. I will try again with a full size keyboard.

RPi Zero v1.3
Launch times consistently repeatable within 0.1 seconds (repeated at least 3 times)
- Offline 11.6s to display key bindings in stdout, 13.7s to display image
- Online 12.3s to display key bindings in stdout, 16.0s to display image, or 15.0s with flag -scale 1

- FPS noticably improved at 1x, including with duel window layouts and rulers enabled, though dragging rulers reduces to ~1fps
- No image artifacts

Code: [Select]
main:thrm:img (0.05 : 0.41 : 0.54) scale 1 fps 13.9 read 3.25 rot 4.89 : [5.17 | 38.93 | 51.02] + 3.83 67.35 12.50 OFF ON
main:thrm:img (0.06 : 0.42 : 0.52) scale 1 fps 13.9 read 1.69 rot 4.40 : [5.08 | 35.54 | 43.41] + 3.30 58.31 11.61 OFF ON
main:thrm:img (0.06 : 0.43 : 0.51) scale 1 fps 13.8 read 1.67 rot 4.39 : [5.11 | 35.78 | 43.24] + 3.27 58.55 12.04 OFF ON
main:thrm:img (0.06 : 0.42 : 0.52) scale 1 fps 13.8 read 1.66 rot 4.42 : [4.78 | 35.58 | 43.40] + 3.29 58.58 11.89 OFF ON
main:thrm:img (0.06 : 0.43 : 0.51) scale 1 fps 13.8 read 1.69 rot 4.42 : [5.22 | 36.08 | 43.13] + 3.27 58.57 12.16 OFF ON
main:thrm:img (0.06 : 0.42 : 0.52) scale 1 fps 13.8 read 1.63 rot 4.43 : [4.66 | 34.81 | 42.98] + 3.28 57.85 11.58 OFF OFF
main:thrm:img (0.05 : 0.40 : 0.55) scale 1 fps 13.9 read 1.70 rot 4.24 : [3.49 | 30.29 | 41.10] + 3.32 53.89 9.47 OFF OFF
main:thrm:img (0.05 : 0.41 : 0.55) scale 1 fps 14.0 read 1.71 rot 4.28 : [3.46 | 30.39 | 40.62] + 3.32 53.62 9.68 OFF OFF
main:thrm:img (0.05 : 0.40 : 0.55) scale 1 fps 14.1 read 1.66 rot 4.20 : [3.44 | 30.15 | 40.97] + 3.32 53.97 9.68 OFF OFF
main:thrm:img (0.05 : 0.41 : 0.55) scale 1 fps 14.2 read 1.72 rot 4.21 : [3.47 | 30.24 | 40.82] + 3.34 53.62 9.46 OFF OFF
main:thrm:img (0.05 : 0.40 : 0.55) scale 1 fps 14.2 read 1.69 rot 4.19 : [3.47 | 30.09 | 40.83] + 3.36 53.84 9.65 OFF OFF
main:thrm:img (0.05 : 0.40 : 0.55) scale 1 fps 14.2 read 1.66 rot 4.24 : [3.44 | 30.14 | 40.86] + 3.32 53.89 9.71 OFF OFF
main:thrm:img (0.05 : 0.41 : 0.55) scale 1 fps 14.3 read 1.65 rot 4.24 : [3.47 | 30.22 | 40.92] + 3.30 53.76 9.54 OFF OFF
main:thrm:img (0.05 : 0.41 : 0.55) scale 1 fps 14.3 read 1.64 rot 4.26 : [3.36 | 30.20 | 40.77] + 3.33 53.98 9.88 OFF OFF
main:thrm:img (0.05 : 0.41 : 0.55) scale 1 fps 14.3 read 1.65 rot 4.27 : [3.38 | 30.20 | 40.80] + 3.31 53.83 9.73 OFF OFF
main:thrm:img (0.04 : 0.41 : 0.55) scale 1 fps 14.4 read 1.64 rot 4.30 : [3.19 | 30.20 | 40.91] + 3.31 54.06 9.83 OFF OFF
main:thrm:img (0.05 : 0.41 : 0.54) scale 1 fps 14.8 read 2.37 rot 6.12 : [4.93 | 44.59 | 59.25] + 4.76 78.19 14.18 OFF OFF
main:thrm:img (0.05 : 0.41 : 0.55) scale 1 fps 14.8 read 1.68 rot 4.24 : [3.39 | 30.16 | 40.64] + 3.29 53.63 9.69 OFF OFF
main:thrm:img (0.05 : 0.41 : 0.55) scale 1 fps 14.7 read 1.69 rot 4.29 : [3.46 | 30.54 | 41.22] + 3.35 54.13 9.55 OFF OFF
main:thrm:img (0.05 : 0.41 : 0.55) scale 1 fps 14.7 read 1.72 rot 4.24 : [3.36 | 30.05 | 40.66] + 3.30 53.43 9.46 OFF OFF
main:thrm:img (0.04 : 0.41 : 0.55) scale 1 fps 14.7 read 1.65 rot 4.27 : [3.21 | 30.27 | 40.75] + 3.35 53.92 9.82 OFF OFF
main:thrm:img (0.04 : 0.40 : 0.55) scale 1 fps 14.7 read 1.65 rot 4.21 : [3.35 | 30.19 | 41.03] + 3.30 53.90 9.57 OFF OFF
main:thrm:img (0.02 : 0.41 : 0.58) scale 1 fps 17.0 read 2.27 rot 5.79 : [1.28 | 33.17 | 46.69] + 4.47 63.29 12.13 OFF NO_DRAWINGS
main:thrm:img (0.00 : 0.41 : 0.59) scale 1 fps 16.9 read 1.68 rot 4.36 : [0.03 | 22.37 | 32.67] + 3.41 45.28 9.20 OFF NO_DRAWINGS
main:thrm:img (0.00 : 0.41 : 0.59) scale 1 fps 16.9 read 1.65 rot 4.46 : [0.02 | 22.35 | 32.73] + 3.40 45.00 8.87 OFF NO_DRAWINGS
main:thrm:img (0.00 : 0.41 : 0.59) scale 1 fps 16.9 read 1.68 rot 4.44 : [0.03 | 22.72 | 32.99] + 3.38 45.24 8.86 OFF NO_DRAWINGS
main:thrm:img (0.00 : 0.41 : 0.59) scale 1 fps 16.9 read 1.64 rot 4.44 : [0.02 | 22.54 | 32.68] + 3.40 44.98 8.90 OFF NO_DRAWINGS
main:thrm:img (0.00 : 0.41 : 0.59) scale 1 fps 16.9 read 1.66 rot 4.41 : [0.03 | 22.57 | 32.87] + 3.42 45.39 9.10 OFF NO_DRAWINGS
main:thrm:img (0.00 : 0.41 : 0.59) scale 1 fps 16.9 read 1.72 rot 4.39 : [0.03 | 22.43 | 32.75] + 3.41 45.04 8.88 OFF NO_DRAWINGS


RPi 2 v1.1
Launch times consistently repeatable within 0.1 seconds (repeated at least 3 times)
- Online 3.6s to display key bindings in stdout, 5.2s to display image.
For comparison 3.7s and 5.9 with release 16.

- At 2x scale shimmering horizontal bands, similar to a poorly tracking VHS tape
- At 1x perfect 25 FPS, bands still present but far less noticeable, shimmering much less.
I will try to work out the best way to send a recording of this, creating a gif to post here lost too much detail to be of any use and I suspect video hosting sites like youtube would do something similar when they trans-code it.

Code: [Select]
main:thrm:img (0.03 : 0.25 : 0.71) scale 2 fps 15.6 read 2.43 rot 2.53 : [2.15 | 16.93 | 47.82] + 2.05 52.91 3.04 OFF ON
main:thrm:img (0.03 : 0.26 : 0.71) scale 2 fps 15.7 read 1.01 rot 2.54 : [2.19 | 17.59 | 48.60] + 2.27 54.42 3.56 OFF ON
main:thrm:img (0.03 : 0.25 : 0.72) scale 2 fps 16.0 read 0.99 rot 2.53 : [2.06 | 16.76 | 47.45] + 1.99 52.51 3.07 OFF ON
main:thrm:img (0.03 : 0.25 : 0.72) scale 2 fps 16.1 read 0.99 rot 2.53 : [1.97 | 16.69 | 47.79] + 1.93 52.57 2.85 OFF ON
main:thrm:img (0.03 : 0.25 : 0.71) scale 2 fps 16.1 read 1.00 rot 2.54 : [2.15 | 17.18 | 48.20] + 2.00 53.21 3.01 OFF ON
main:thrm:img (0.03 : 0.25 : 0.72) scale 2 fps 16.2 read 0.98 rot 2.47 : [2.07 | 16.54 | 47.24] + 1.96 52.50 3.30 OFF ON
main:thrm:img (0.06 : 0.27 : 0.68) scale 2 fps 15.8 read 1.98 rot 4.92 : [7.77 | 37.31 | 95.40] + 3.86 106.14 6.88 BOTH ON
main:thrm:img (0.07 : 0.28 : 0.65) scale 2 fps 15.7 read 1.02 rot 2.57 : [5.45 | 21.20 | 49.90] + 1.94 55.98 4.15 BOTH ON
main:thrm:img (0.07 : 0.27 : 0.66) scale 2 fps 15.7 read 0.99 rot 2.51 : [5.35 | 20.41 | 49.19] + 2.02 55.26 4.05 BOTH ON
main:thrm:img (0.07 : 0.27 : 0.66) scale 2 fps 15.7 read 0.99 rot 2.48 : [5.24 | 20.57 | 49.31] + 1.99 55.09 3.80 BOTH ON
main:thrm:img (0.07 : 0.27 : 0.66) scale 2 fps 15.7 read 0.99 rot 2.58 : [5.32 | 20.55 | 49.67] + 1.96 55.77 4.13 BOTH ON
main:thrm:img (0.07 : 0.27 : 0.66) scale 2 fps 15.7 read 0.98 rot 2.54 : [5.34 | 20.70 | 50.25] + 1.95 56.16 3.97 BOTH ON
main:thrm:img (0.07 : 0.27 : 0.65) scale 1 fps 15.7 read 1.43 rot 2.50 : [5.32 | 20.10 | 47.98] + 1.95 53.81 3.89 BOTH ON
main:thrm:img (0.12 : 0.39 : 0.48) scale 1 fps 25.0 read 17.72 rot 2.39 : [4.50 | 14.59 | 17.89] + 1.20 21.53 2.44 BOTH ON
main:thrm:img (0.12 : 0.39 : 0.48) scale 1 fps 25.0 read 16.00 rot 2.34 : [4.45 | 14.10 | 17.25] + 1.07 20.76 2.44 BOTH ON
main:thrm:img (0.13 : 0.39 : 0.48) scale 1 fps 25.0 read 15.88 rot 2.28 : [4.74 | 14.52 | 17.61] + 1.06 20.99 2.32 BOTH ON
main:thrm:img (0.13 : 0.40 : 0.47) scale 1 fps 25.0 read 15.70 rot 2.25 : [4.79 | 14.65 | 17.30] + 1.09 20.89 2.51 BOTH ON
main:thrm:img (0.13 : 0.39 : 0.48) scale 1 fps 25.0 read 15.53 rot 2.30 : [4.83 | 14.49 | 17.52] + 1.13 21.22 2.57 BOTH ON
main:thrm:img (0.13 : 0.40 : 0.48) scale 1 fps 25.0 read 15.10 rot 2.36 : [4.67 | 14.76 | 17.74] + 1.12 21.35 2.50 BOTH ON
main:thrm:img (0.12 : 0.39 : 0.49) scale 1 fps 25.0 read 15.93 rot 2.31 : [4.41 | 14.06 | 17.46] + 1.07 20.75 2.21 BOTH ON
main:thrm:img (0.13 : 0.40 : 0.47) scale 1 fps 25.0 read 16.13 rot 2.24 : [4.72 | 14.61 | 17.26] + 1.09 20.72 2.37 BOTH ON
main:thrm:img (0.13 : 0.39 : 0.48) scale 1 fps 25.0 read 15.85 rot 2.27 : [4.56 | 14.25 | 17.52] + 1.08 20.88 2.28 BOTH ON
main:thrm:img (0.12 : 0.40 : 0.47) scale 1 fps 25.0 read 15.71 rot 2.30 : [4.61 | 14.86 | 17.42] + 1.07 21.08 2.59 BOTH ON
 

Offline Amish Technician

  • Contributor
  • Posts: 30
  • Country: gb
Well done  :-+

I am trying to achieve the same on the RPi Zero 2 W
I have installed Raspberry Pi OS desktop 64-bit without trouble but keep running into errors when installing OpenCV

Do you have any advice on the install?
- Compiling the source on the Pi (cmake)
- Memory increased to plentifull with swapfile
- Have added the contrib modules
- Cmake on all 4 cores -j4

Would also be interested in your -D flags

Thanks!

I installed the "libopencv-dev" package from the Debian stable repo

Code: [Select]
sudo apt install libopencv-dev
Here is my build script:

Code: [Select]
#!/bin/bash

# Build Thermal Camera Redux

echo "Building redux and test_driver ..."

rm ./redux

# RPi Zero 2 W     
CFLAGS='-mcpu=cortex-a53 -pipe -fomit-frame-pointer'

DEFAULT_FLAGS='-DDEFAULT_FONT=0 -DDEFAULT_COLORMAP=4 -DROTATION=0 -DDISPLAY_WIDTH=1920 -DDISPLAY_HEIGHT=1080 -DUSE_CELSIUS=1 -DHUD_ALPHA=0.4'

# Compile and link Redux Thermal Camera code
g++ -Wall -Wextra -O3 -ffast-math ${DEFAULT_FLAGS} ${CFLAGS} -DUSE_ASSERT=0 -I/usr/include/opencv4 tc001.cpp thread.cpp -o redux -lpthread `pkg-config --cflags --libs opencv4`

gcc -Wall test_driver.c -o test_driver

Hope this helps.

Sincerely,
Amish Tech.
 
The following users thanked this post: RO

Offline G28Topic starter

  • Regular Contributor
  • *
  • Posts: 74
  • Country: us
    • Thermal Camera Redux
Amish Tech,

Thanks for the detailed update.

RPi Zero v1.3:

- The 11.6s and 12.3s to printKeyBindings() is disturbing.  The only thing that is going on is argv parsing, a few variable declarations and opening either the camera or file.  I would guess the lag is opening the disk/device since neither invokes a data read until after printing the key bindings.  The initial GUI window creation is done next.  Loading from disk could also be an issue.  I assume you are starting the program from a SD card ?

I can add some startup timing stats to zero in on the worst offenders including the load from disk.

A single threaded -D flag is possible with some rework.  From the logs, the processing of the image sub-frame and thermal sub-frame are taking the lion's share of the time.  The 3rd thread is waiting idle most of the time.  On the PC, all 3 are pretty evenly loaded.  The 3rd column from the end shows that there is a significant amount of time waiting for threads to sync where a single thread would eliminate those waits.

The latest github release logs gives a more accurate picture of how long the camera reads actually take.  The "read n.nn" column looks fairly well.  Before, the read timing also included the waits on the camera's FPS rates.

RPi 2 v1.1:

Horizontal banding.  Have you tried using the "r" key to see if the banding shows up in the recorded .avi file ?  It might help isolate the problem if it shows up in the composited video/graphic image, or OpenCV's display.

If it doesn't show up in the .avi file, you might be able to use the Linux "peek" command to record a GIF file if peek is available on the Pi.

The 3rd last column waits appear more reasonable compared to the Zero 1.3, but it appears there is still some uneven thread loading with the image thread taking the longest.  I could swap some of the work loads between the thermal and image threads if the lag is in the rendering stages or dump some into the main thread.

I added some function pointers in the last release and was thinking about doing realtime smart thread loading by monitoring the thread stats and then swapping loads in realtime to balance the aggregate load based on hardware capabilities.

Also, the Zero 1.3 appear to take twice as long for OpenCV to show the prepared 1X frames vs the 2X frames on the Pi 2 v1.1, a factor of 4X slower considering the frame size delta.

How were the font and ruler displays at 1X and 2X ? 

Were they more or less legible than the December release ?

Was there any temp text-flickers ?

Thanks much.
 

Offline G28Topic starter

  • Regular Contributor
  • *
  • Posts: 74
  • Country: us
    • Thermal Camera Redux
Another idea for the RPi Zero v1.3. 

I could reduce the resolution of the ruler drag.  Right now it is plotting 256 landscape points and 192 portrait points.  During drag, I could half or quarter that resolution and then return to full resolution at the end of the drag.

What is the frame rate of dragging just 1 text temp and just the cross hair of text temps without the line plots ?  If they are reasonable, decreasing the resolution of the line plots during drag will help.
« Last Edit: January 12, 2024, 03:45:55 am by G28 »
 
The following users thanked this post: Amish Technician

Offline RO

  • Contributor
  • Posts: 45
  • Country: nl

I installed the "libopencv-dev" package from the Debian stable repo

Code: [Select]
sudo apt install libopencv-dev


Ah yes, I have been compiling opencv from the github as the repository is quite outdated and I read using apt might induce future problems when updating. (or if updating)

But thanks! that should get me started.
 
The following users thanked this post: Amish Technician

Offline Amish Technician

  • Contributor
  • Posts: 30
  • Country: gb
RPi Zero v1.3:

Yes the whole system runs from a micro sd card, I have two that I've been using for testing. The legacy 32bit Pi OS is on a slower class 4 16GB kingston card which I've used for the Zero v1.3 and 2 v1.1 while the rest of the 64bit models have been tested with a nearly new Samsung pro endurance 256GB U3 card. I'm going to have to borrow another one of those from another project and test again to eliminate the sd card differences. I have about a dozen cards for the RPIs now but still never have any spare  ::)

RPi2 v1.1

Recorded .avi file attached
« Last Edit: January 12, 2024, 04:39:12 pm by Amish Technician »
 

Offline G28Topic starter

  • Regular Contributor
  • *
  • Posts: 74
  • Country: us
    • Thermal Camera Redux
RPi Zero v1.3:

Yes the whole system runs from a micro sd card, I have two that I've been using for testing. The legacy 32bit Pi OS is on a slower class 4 16GB kingston card which I've used for the Zero v1.3 and 2 v1.1 while the rest of the 64bit models have been tested with a nearly new Samsung pro endurance 256GB U3 card. I'm going to have to borrow another one of those from another project and test again to eliminate the sd card differences. I have about a dozen cards for the RPIs now but still never have any spare  ::)

RPi2 v1.1

Recorded .avi file attached

Thanks for the feedback and .avi file.

PM's and test mods sent. 

The test mods also includes startup timing logs to see where the startup time is spent.

 
The following users thanked this post: Amish Technician

Offline Amish Technician

  • Contributor
  • Posts: 30
  • Country: gb
Note: I've just received the 'FAST_DRAG DRAW_SINGLE_THREAD' as I was about to post this message, thank you  :-+ Will provide feedback on it probably tomorrow.

I've cloned the slower SD card onto a faster card identical to the one I've used for 64bit models (purchased at the same time late last year so they shouldn't slow down due to wear). I overlooked the impact this could have as I'd incorrectly assumed the difference would be negligible for an app that's ~140KB compiled, but it appears to have improved things a bit, for RPi2 v1.1 especially.

RPi Zero v1.3

Launch times consistently repeatable within 0.1 seconds (repeated at least 3 times)
- Offline 11.8s to display key bindings in stdout, 13.9s to display image
- Online 12.1s to display key bindings in stdout, 15.8s to display image, or 15.0s with flag -scale 1


Online -scale 1
FPS taken after reset from at least 3 readings in stdout .
x1 double 10.9fps dragging single temperature point around with status hud disabled
x1 13.9fps dragging single temperature point around with status hud enabled
x1 double 10.3fps dragging both rulers around with status hud disabled
x1 double 9.7fps dragging both rulers around with status hud enabled
x1 14.6fps dragging both rulers around with status hud disabled
x1 13.7fps dragging both rulers around with status hud enabled
These fps figures for online are all far better than I had expected as they feel like ~2fps because all the frames come at once and then it freezes for ~0.5s, unless you drag slowely and then it's a relativly consistent stuttery update rate. Perhaps the best option for weaker CPUs is to disable dragging things and have it click to position only?

Code: [Select]
main:thrm:img (0.05 : 0.43 : 0.52) scale 1 fps 13.1 read 3.33 rot 4.62 : [5.28 | 41.61 | 50.19] + 3.45 64.33 10.68 ONE_TEMP ON
main:thrm:img (0.05 : 0.42 : 0.52) scale 1 fps 13.7 read 1.84 rot 4.64 : [4.79 | 40.38 | 49.89] + 3.44 63.13 9.80 ONE_TEMP ON
main:thrm:img (0.05 : 0.43 : 0.52) scale 1 fps 13.9 read 1.83 rot 4.70 : [4.56 | 40.57 | 49.78] + 3.47 63.18 9.93 ONE_TEMP ON
main:thrm:img (0.05 : 0.43 : 0.52) scale 1 fps 14.0 read 1.84 rot 4.70 : [5.08 | 41.38 | 50.12] + 3.53 63.91 10.26 ONE_TEMP ON
main:thrm:img (0.06 : 0.44 : 0.51) scale 1 fps 13.9 read 1.68 rot 4.35 : [5.02 | 39.31 | 45.38] + 3.32 60.68 11.98 ONE_TEMP ON
main:thrm:img (0.05 : 0.43 : 0.52) scale 1 fps 13.9 read 1.81 rot 4.60 : [4.95 | 40.03 | 48.16] + 3.41 62.18 10.61 ONE_TEMP ON
main:thrm:img (0.06 : 0.43 : 0.52) scale 1 fps 13.9 read 1.80 rot 4.61 : [5.43 | 40.83 | 49.13] + 3.42 63.03 10.47 CROSS_HAIR ON
main:thrm:img (0.06 : 0.43 : 0.51) scale 1 fps 14.0 read 1.76 rot 4.55 : [5.84 | 41.32 | 48.87] + 3.47 63.30 10.96 CROSS_HAIR ON
main:thrm:img (0.09 : 0.44 : 0.48) scale 1 fps 13.8 read 1.67 rot 4.28 : [8.55 | 42.88 | 46.98] + 3.35 64.33 14.00 CROSS_HAIR ON
main:thrm:img (0.09 : 0.44 : 0.46) scale 1 fps 13.7 read 1.67 rot 4.17 : [9.31 | 44.42 | 46.31] + 3.30 65.09 15.48 CROSS_HAIR ON
main:thrm:img (0.09 : 0.44 : 0.47) scale 1 fps 13.6 read 1.66 rot 4.20 : [9.23 | 43.75 | 46.95] + 3.32 64.76 14.49 CROSS_HAIR ON
main:thrm:img (0.09 : 0.44 : 0.47) scale 1 fps 13.5 read 1.70 rot 4.28 : [9.52 | 44.21 | 47.68] + 3.31 65.33 14.34 CROSS_HAIR ON
main:thrm:img (0.07 : 0.42 : 0.50) scale 1 fps 14.5 read 4.52 rot 11.03 : [18.08 | 103.35 | 122.09] + 8.76 160.16 29.30 BOTH OFF
main:thrm:img (0.06 : 0.41 : 0.53) scale 1 fps 14.6 read 1.85 rot 4.28 : [5.50 | 38.18 | 48.59] + 3.46 61.41 9.36 BOTH OFF
main:thrm:img (0.06 : 0.41 : 0.53) scale 1 fps 14.6 read 1.87 rot 4.35 : [5.59 | 38.12 | 48.81] + 3.55 61.37 9.02 BOTH OFF
main:thrm:img (0.09 : 0.42 : 0.49) scale 1 fps 14.3 read 1.71 rot 4.31 : [8.68 | 40.65 | 47.95] + 3.35 61.72 10.42 BOTH OFF
main:thrm:img (0.09 : 0.42 : 0.49) scale 1 fps 14.1 read 1.67 rot 4.30 : [8.96 | 40.30 | 47.53] + 3.32 61.36 10.50 BOTH OFF
main:thrm:img (0.09 : 0.42 : 0.49) scale 1 fps 13.9 read 1.64 rot 4.21 : [9.27 | 41.17 | 47.96] + 3.31 62.14 10.86 BOTH OFF
main:thrm:img (0.09 : 0.42 : 0.49) scale 1 fps 13.8 read 1.68 rot 4.30 : [9.30 | 41.16 | 48.57] + 3.31 62.14 10.26 BOTH OFF
main:thrm:img (0.10 : 0.42 : 0.49) scale 1 fps 13.7 read 1.68 rot 4.32 : [9.42 | 41.23 | 48.42] + 3.31 62.20 10.47 BOTH OFF
main:thrm:img (0.08 : 0.42 : 0.50) scale 1 fps 13.7 read 3.32 rot 8.41 : [15.62 | 81.51 | 96.40] + 6.34 122.57 19.82 BOTH ON
main:thrm:img (0.07 : 0.42 : 0.50) scale 1 fps 13.7 read 1.83 rot 4.62 : [7.71 | 44.56 | 52.72] + 3.39 66.32 10.21 BOTH ON
main:thrm:img (0.11 : 0.43 : 0.46) scale 1 fps 13.2 read 1.71 rot 4.18 : [11.41 | 46.35 | 49.19] + 3.30 67.33 14.85 BOTH ON
main:thrm:img (0.11 : 0.43 : 0.46) scale 1 fps 13.0 read 1.69 rot 4.22 : [11.35 | 46.59 | 49.52] + 3.29 67.61 14.80 BOTH ON
main:thrm:img (0.11 : 0.43 : 0.46) scale 1 fps 12.8 read 1.71 rot 4.17 : [12.02 | 46.76 | 49.12] + 3.32 67.66 15.23 BOTH ON
main:thrm:img (0.11 : 0.43 : 0.46) scale 1 fps 12.7 read 1.71 rot 4.21 : [11.78 | 46.52 | 49.90] + 3.29 67.66 14.47 BOTH ON
main:thrm:img (0.10 : 0.43 : 0.47) scale 1 fps 12.6 read 1.71 rot 4.36 : [11.45 | 46.94 | 50.85] + 3.29 68.30 14.15 BOTH ON
main:thrm:img (0.11 : 0.43 : 0.46) scale 1 fps 12.6 read 1.64 rot 4.15 : [11.50 | 46.91 | 49.80] + 3.28 67.89 14.81 BOTH ON
main:thrm:img (0.08 : 0.40 : 0.52) scale 1 fps 9.8 read 3.06 rot 9.34 : [18.04 | 89.49 | 118.02] + 9.33 148.03 20.67 BOTH ON
main:thrm:img (0.06 : 0.37 : 0.57) scale 1 fps 9.8 read 1.79 rot 5.68 : [7.95 | 51.21 | 77.99] + 6.53 92.41 7.89 BOTH ON
main:thrm:img (0.06 : 0.37 : 0.57) scale 1 fps 9.7 read 1.78 rot 5.89 : [7.85 | 50.80 | 76.93] + 6.40 91.53 8.20 BOTH ON
main:thrm:img (0.08 : 0.38 : 0.54) scale 1 fps 9.6 read 1.78 rot 5.79 : [11.33 | 54.31 | 78.60] + 6.48 94.96 9.87 BOTH ON
main:thrm:img (0.08 : 0.38 : 0.54) scale 1 fps 10.3 read 3.55 rot 10.56 : [23.73 | 105.71 | 150.38] + 12.62 183.92 20.92 BOTH OFF
main:thrm:img (0.05 : 0.37 : 0.58) scale 1 fps 10.3 read 1.75 rot 4.90 : [7.07 | 47.66 | 74.49] + 6.49 88.05 7.07 BOTH OFF
main:thrm:img (0.06 : 0.37 : 0.58) scale 1 fps 10.3 read 1.77 rot 4.98 : [7.11 | 46.90 | 73.32] + 6.49 87.57 7.75 BOTH OFF
main:thrm:img (0.06 : 0.37 : 0.57) scale 1 fps 10.9 read 3.41 rot 9.72 : [15.80 | 93.58 | 143.67] + 12.66 173.46 17.13 ONE_TEMP OFF
main:thrm:img (0.02 : 0.37 : 0.60) scale 1 fps 10.9 read 1.81 rot 4.79 : [2.63 | 43.04 | 69.94] + 6.49 83.31 6.88 ONE_TEMP OFF
main:thrm:img (0.02 : 0.37 : 0.61) scale 1 fps 10.9 read 1.76 rot 4.75 : [2.68 | 43.07 | 70.23] + 6.57 83.62 6.82 ONE_TEMP OFF
main:thrm:img (0.03 : 0.37 : 0.60) scale 1 fps 10.7 read 1.70 rot 4.88 : [3.48 | 42.75 | 67.94] + 6.39 82.84 8.51 ONE_TEMP OFF
main:thrm:img (0.04 : 0.37 : 0.59) scale 1 fps 10.5 read 1.74 rot 4.86 : [4.10 | 42.34 | 67.24] + 6.26 82.60 9.09 ONE_TEMP OFF
main:thrm:img (0.04 : 0.37 : 0.59) scale 1 fps 10.4 read 1.70 rot 4.69 : [4.11 | 41.92 | 67.28] + 6.28 83.00 9.43 ONE_TEMP OFF
main:thrm:img (0.04 : 0.38 : 0.59) scale 1 fps 10.3 read 1.87 rot 5.12 : [4.10 | 42.92 | 67.27] + 6.32 82.89 9.30 ONE_TEMP OFF


Offline -scale 1
FPS taken after reset from at least 3 readings in stdout.
x1 double 23.3fps dragging single temperature point around with status hud disabled
x1 24.9fps dragging single temperature point around with status hud disabled
x1 double 22.2fps dragging both rulers around with status hud disabled
x1 24.9fps dragging both rulers around with status hud disabled
x1 24.8fps dragging both rulers around with status hud enabled
Felt slightly less smooth at any given frame rate than I'd expect.

Code: [Select]
main:thrm:img (0.13 : 0.36 : 0.51) scale 2 fps 13.6 read 0.03 rot 3.71 : [7.07 | 19.23 | 27.78] + 11.62 47.35 7.95 OFF ON
main:thrm:img (0.14 : 0.35 : 0.51) scale 1 fps 25.0 read 0.01 rot 6.65 : [9.91 | 24.46 | 35.53] + 10.71 53.62 7.38 OFF ON
main:thrm:img (0.17 : 0.34 : 0.48) scale 1 fps 24.8 read 0.01 rot 3.88 : [5.88 | 11.53 | 16.30] + 2.99 21.64 2.35 ONE_TEMP ON
main:thrm:img (0.12 : 0.35 : 0.54) scale 1 fps 24.8 read 0.01 rot 4.00 : [3.40 | 10.17 | 15.63] + 3.03 20.43 1.76 ONE_TEMP OFF
main:thrm:img (0.14 : 0.31 : 0.56) scale 1 fps 24.9 read 0.01 rot 4.55 : [3.80 | 8.42 | 15.29] + 3.78 20.96 1.89 ONE_TEMP OFF
main:thrm:img (0.13 : 0.30 : 0.57) scale 1 fps 24.9 read 0.01 rot 3.86 : [2.96 | 6.71 | 12.57] + 3.16 17.46 1.72 ONE_TEMP OFF
main:thrm:img (0.13 : 0.30 : 0.56) scale 1 fps 24.9 read 0.01 rot 3.82 : [2.95 | 6.73 | 12.55] + 3.17 17.33 1.61 ONE_TEMP OFF
main:thrm:img (0.14 : 0.30 : 0.55) scale 1 fps 24.9 read 0.01 rot 3.76 : [3.22 | 6.85 | 12.48] + 3.03 16.96 1.46 ONE_TEMP OFF
main:thrm:img (0.15 : 0.31 : 0.54) scale 1 fps 24.9 read 0.01 rot 3.64 : [3.58 | 7.12 | 12.53] + 2.98 17.09 1.58 ONE_TEMP OFF
main:thrm:img (0.15 : 0.30 : 0.54) scale 1 fps 24.9 read 0.01 rot 3.62 : [3.51 | 7.00 | 12.48] + 2.97 16.87 1.41 ONE_TEMP OFF
main:thrm:img (0.15 : 0.30 : 0.54) scale 1 fps 24.9 read 0.01 rot 3.65 : [3.52 | 6.96 | 12.45] + 2.99 16.88 1.44 ONE_TEMP OFF
main:thrm:img (0.15 : 0.30 : 0.54) scale 1 fps 24.9 read 0.01 rot 3.65 : [3.58 | 7.08 | 12.58] + 2.99 17.04 1.47 ONE_TEMP OFF

main:thrm:img (0.11 : 0.40 : 0.49) scale 1 fps 22.5 read 0.02 rot 10.47 : [11.32 | 39.54 | 47.96] + 18.25 83.89 17.68 ONE_TEMP OFF
main:thrm:img (0.06 : 0.44 : 0.50) scale 1 fps 22.9 read 0.01 rot 6.03 : [1.91 | 14.90 | 16.89] + 6.00 29.37 6.48 ONE_TEMP OFF
main:thrm:img (0.06 : 0.44 : 0.50) scale 1 fps 23.1 read 0.01 rot 5.84 : [1.91 | 14.84 | 16.74] + 6.09 29.30 6.47 ONE_TEMP OFF
main:thrm:img (0.06 : 0.44 : 0.50) scale 1 fps 23.2 read 0.01 rot 5.91 : [1.94 | 14.84 | 16.78] + 6.04 29.26 6.44 ONE_TEMP OFF
main:thrm:img (0.06 : 0.45 : 0.50) scale 1 fps 23.2 read 0.01 rot 5.76 : [1.92 | 14.80 | 16.53] + 6.05 29.25 6.67 ONE_TEMP OFF
main:thrm:img (0.06 : 0.44 : 0.50) scale 1 fps 23.3 read 0.01 rot 5.90 : [1.94 | 14.71 | 16.61] + 6.11 29.28 6.56 ONE_TEMP OFF
main:thrm:img (0.06 : 0.44 : 0.50) scale 1 fps 23.3 read 0.01 rot 5.99 : [1.99 | 14.89 | 16.98] + 6.06 29.56 6.52 ONE_TEMP OFF
main:thrm:img (0.06 : 0.45 : 0.49) scale 1 fps 23.3 read 0.01 rot 5.98 : [1.96 | 15.25 | 16.77] + 6.13 29.75 6.84 ONE_TEMP OFF
main:thrm:img (0.06 : 0.44 : 0.50) scale 1 fps 23.3 read 0.01 rot 6.02 : [2.04 | 15.17 | 16.95] + 6.13 29.46 6.38 ONE_TEMP OFF
main:thrm:img (0.10 : 0.48 : 0.43) scale 1 fps 23.2 read 0.01 rot 4.55 : [3.28 | 16.16 | 14.45] + 5.96 29.70 7.59 ONE_TEMP OFF
main:thrm:img (0.10 : 0.48 : 0.42) scale 1 fps 23.0 read 0.01 rot 4.46 : [3.48 | 16.18 | 14.30] + 5.85 29.49 7.46 ONE_TEMP OFF
main:thrm:img (0.10 : 0.48 : 0.42) scale 1 fps 22.9 read 0.01 rot 4.49 : [3.46 | 16.18 | 14.28] + 5.87 29.62 7.56 ONE_TEMP OFF
main:thrm:img (0.10 : 0.48 : 0.42) scale 1 fps 22.8 read 0.01 rot 4.41 : [3.47 | 16.30 | 14.21] + 5.88 29.64 7.46 ONE_TEMP OFF
main:thrm:img (0.16 : 0.43 : 0.41) scale 1 fps 21.8 read 0.01 rot 12.01 : [19.20 | 51.34 | 48.92] + 14.81 86.32 20.18 BOTH OFF
main:thrm:img (0.14 : 0.42 : 0.44) scale 1 fps 22.1 read 0.01 rot 5.81 : [5.98 | 18.74 | 19.43] + 6.33 33.21 7.45 BOTH OFF
main:thrm:img (0.13 : 0.43 : 0.44) scale 1 fps 22.1 read 0.01 rot 5.62 : [5.92 | 18.87 | 19.31] + 6.27 33.11 7.54 BOTH OFF
main:thrm:img (0.13 : 0.43 : 0.44) scale 1 fps 22.2 read 0.01 rot 5.83 : [6.01 | 19.25 | 19.57] + 6.34 33.53 7.63 BOTH OFF
main:thrm:img (0.14 : 0.43 : 0.44) scale 1 fps 22.2 read 0.01 rot 5.61 : [5.98 | 19.00 | 19.24] + 6.32 33.27 7.71 BOTH OFF
main:thrm:img (0.13 : 0.43 : 0.44) scale 1 fps 22.2 read 0.01 rot 5.84 : [5.99 | 19.12 | 19.63] + 6.37 33.57 7.57 BOTH OFF

main:thrm:img (0.12 : 0.37 : 0.52) scale 1 fps 15.6 read 0.01 rot 3.80 : [5.03 | 15.92 | 22.45] + 8.74 39.00 7.81 BOTH ON
main:thrm:img (0.17 : 0.34 : 0.49) scale 1 fps 24.9 read 0.01 rot 4.95 : [7.30 | 14.22 | 20.35] + 4.04 27.33 2.94 BOTH OFF
main:thrm:img (0.16 : 0.33 : 0.52) scale 1 fps 24.9 read 0.01 rot 3.81 : [4.22 | 8.83 | 14.10] + 3.16 19.13 1.87 BOTH OFF
main:thrm:img (0.15 : 0.33 : 0.52) scale 1 fps 24.9 read 0.01 rot 3.92 : [4.15 | 8.99 | 14.40] + 3.22 19.46 1.85 BOTH OFF
main:thrm:img (0.15 : 0.33 : 0.52) scale 1 fps 24.9 read 0.01 rot 3.93 : [4.20 | 8.98 | 14.33] + 3.20 19.48 1.95 BOTH OFF

main:thrm:img (0.14 : 0.36 : 0.50) scale 1 fps 24.9 read 0.02 rot 7.59 : [9.46 | 24.14 | 33.35] + 6.45 44.45 4.65 BOTH ON
main:thrm:img (0.13 : 0.37 : 0.50) scale 1 fps 24.9 read 0.01 rot 4.10 : [4.49 | 12.77 | 17.38] + 3.11 22.71 2.22 BOTH ON
main:thrm:img (0.13 : 0.37 : 0.50) scale 1 fps 24.8 read 0.01 rot 4.12 : [4.48 | 12.88 | 17.47] + 3.10 22.85 2.28 BOTH ON
main:thrm:img (0.13 : 0.36 : 0.50) scale 1 fps 24.8 read 0.01 rot 4.10 : [4.56 | 12.61 | 17.38] + 3.11 22.59 2.10 BOTH ON
main:thrm:img (0.13 : 0.37 : 0.50) scale 1 fps 24.8 read 0.01 rot 4.02 : [4.57 | 12.78 | 17.29] + 3.10 22.65 2.25 BOTH ON


RPi 2 v1.1
Launch times consistently repeatable within 0.1 seconds (repeated at least 3 times)
- Online 2.9s to display key bindings in stdout, 4.1s to display image.
 

Offline G28Topic starter

  • Regular Contributor
  • *
  • Posts: 74
  • Country: us
    • Thermal Camera Redux

x1 double 10.9fps dragging single temperature point around with status hud disabled
x1 double 10.3fps dragging both rulers around with status hud disabled

Perhaps the best option for weaker CPUs is to disable dragging things and have it click to position only?

With only 0.6 fps delta between 1 temp and both rulers, FAST_DRAG probably isn't going to make much difference.  Still like to see the results of the 2 new compile flags.

Yep, will add -DNO_DRAG=1 to optionally disable drag scrolling, but even without it, it doesn't stop the user from using the click jump-scroll method.

... as they feel like ~2fps because all the frames come at once and then it freezes for ~0.5s, unless you drag slowly and then it's a relatively consistent stuttery update rate.

That is odd because waitKeyEx( 1ms ) is only supposed to block for a max of 1 millisecond and then get blocked waiting for the next frame read to finish.  It appears as if imshow()'s are being stacked/buffered inside the OpenCV library (like printing buffered instead flushing buffers after each print statement). 

I am doing mouse debouncing to minimize unnecessary processing because there is only 1 composited render per frame, but OpenCV allows multiple mouse events per frame.  I only act on the last mouse move because there are no "tween" frames at fixed rates.

FAST_DRAG may speed up that stuttery update behavior.

Felt slightly less smooth at any given frame rate than I'd expect.

On my i7-9700 PC in offline mode and FPS set to "-fps 60" or higher, drag scrolling feels smoother than at 25 FPS. 

Part of what you are experiencing is 25 FPS.

Question, did it feel smoother in older versions ? 

The newer versions uses nano-sleep to stabilize FPS instead of using waitKeyEx() which was very unpredictable/inconsistent (too much jitter) allowing FPS to wander and take a long time to reach steady state.

Update:  Just rechecked the code.  Nano-sleep is only used during Freeze Frame and Offline modes, not live camera modes.
« Last Edit: January 12, 2024, 10:17:48 pm by G28 »
 

Offline G28Topic starter

  • Regular Contributor
  • *
  • Posts: 74
  • Country: us
    • Thermal Camera Redux
-DNO_DRAG=1 added as an option to replace drag scrolling with jump scrolling for "CPU challenged" hardware.
 
The following users thanked this post: Amish Technician

Offline G28Topic starter

  • Regular Contributor
  • *
  • Posts: 74
  • Country: us
    • Thermal Camera Redux
FWIW, I had installed Pi Desktop into a VirtualBox guest to test with the PiOS without the actual hardware. 

I passed the Topdon TC001 through to the guest.  I could never get the camera to work in the proper pixel format.

The issue is that the VM is passing the camera through as Motion JPEG instead of its native 'YUYV' (YUYV 4:2:2) pixel format.  Motion JPEG is a lossy format, thus is useless to mine the thermal data.

 
The following users thanked this post: Amish Technician

Offline Amish Technician

  • Contributor
  • Posts: 30
  • Country: gb
Replacing drag scrolling with jump scrolling provides a better user experience on "CPU challenged hardware" while the camera is online  :-+ but isn't necessary in freeze frame or offline: The benefit of it is that it prevents the live image stuttering.

Seeing some improvement in fps from the single thread version, and the "CPU challenged" single core RPi zero and RPi1 need all the help they can get  ;D

RPi Zero v1.3 - No Drag

Online -scale 1
x1 double 9.7fps both rulers with status hud enabled
x1 double 11.8fps no hud
x1 17.1fps no hud
x1 14.0fps default hud
x1 14.9fps single temperature point with status hud disabled
x1 14.0fps both rulers with status hud disabled


Code: [Select]
Offline 2x
Startup timings: m 0.026, var 0.665, suo 0.357, pa 1.268, pkb 7.985, nw 1421.364, run 1.431, total 1433.096
Startup timings: m 0.025, var 0.797, suo 0.236, pa 1.211, pkb 7.455, nw 1412.152, run 1.495, total 1423.371 stdout keybindings 11.8s image 13.9s
Startup timings: m 0.023, var 0.852, suo 0.237, pa 1.353, pkb 8.662, nw 1426.547, run 1.357, total 1439.031 stdout keybindings 12.1s image 13.9s
Startup timings: m 0.028, var 0.654, suo 0.398, pa 1.318, pkb 8.508, nw 1393.718, run 1.364, total 1405.988 stdout keybindings 12.0s image 14.2s



Online -scale 1
Startup timings: m 0.029, var 0.655, suo 6.975, pa 368.359, pkb 0.804, nw 1818.635, run 1.530, total 2196.987
Startup timings: m 0.053, var 0.519, suo 0.322, pa 273.784, pkb 4.473, nw 1613.696, run 1.682, total 1894.529 stdout keybindings 12.4s
Startup timings: m 0.027, var 0.910, suo 0.329, pa 269.718, pkb 4.385, nw 1557.246, run 1.573, total 1834.188 stdout keybindings 12.0s image 14.9s
Startup timings: m 0.027, var 0.639, suo 0.365, pa 274.704, pkb 4.769, nw 1675.175, run 1.538, total 1957.217 stdout keybindings 12.0s image 14.9s

main:thrm:img (0.04 : 0.34 : 0.62) scale 1 fps 12.7 read 3.10 rot 4.22 : [2.54 | 24.31 | 44.11] + 3.31 58.98 11.56 OFF HUD : h 0.00 v 12.01
main:thrm:img (0.02 : 0.34 : 0.64) scale 1 fps 13.3 read 1.72 rot 4.25 : [1.68 | 24.27 | 46.36] + 3.39 60.32 10.57 HORIZ HUD : h 0.00 v 13.20
main:thrm:img (0.01 : 0.30 : 0.69) scale 1 fps 9.6 read 4.87 rot 12.08 : [3.06 | 75.43 | 174.40] + 13.71 214.56 26.45 BOTH OFF : h 0.01 v 53.86
main:thrm:img (0.00 : 0.28 : 0.72) scale 1 fps 9.6 read 1.66 rot 4.18 : [0.16 | 27.51 | 71.51] + 6.32 85.94 8.10 BOTH OFF : h 0.00 v 20.20
main:thrm:img (0.00 : 0.32 : 0.68) scale 1 fps 11.8 read 3.02 rot 8.22 : [0.19 | 49.77 | 107.67] + 11.59 133.07 13.81 ONE_TEMP NO_DRAWINGS : h 0.01 v 15.45
main:thrm:img (0.00 : 0.35 : 0.65) scale 1 fps 11.8 read 1.71 rot 4.54 : [0.03 | 27.66 | 51.39] + 6.52 65.53 7.61 ONE_TEMP NO_DRAWINGS : h 0.00 v 0.00
main:thrm:img (0.00 : 0.35 : 0.65) scale 1 fps 11.8 read 1.69 rot 4.55 : [0.03 | 27.60 | 51.35] + 6.54 65.59 7.69 ONE_TEMP NO_DRAWINGS : h 0.00 v 0.00
main:thrm:img (0.00 : 0.35 : 0.65) scale 1 fps 11.6 read 1.70 rot 4.36 : [0.03 | 29.54 | 54.39] + 6.76 70.23 9.08 ONE_TEMP NO_DRAWINGS : h 0.00 v 0.00
main:thrm:img (0.00 : 0.41 : 0.59) scale 1 fps 17.1 read 1.74 rot 4.66 : [0.11 | 24.27 | 34.74] + 3.65 47.65 9.26 ONE_TEMP NO_DRAWINGS : h 0.00 v 0.69
main:thrm:img (0.00 : 0.42 : 0.58) scale 1 fps 17.1 read 1.64 rot 4.45 : [0.04 | 23.04 | 32.18] + 3.49 44.46 8.79 ONE_TEMP NO_DRAWINGS : h 0.00 v 0.00
main:thrm:img (0.02 : 0.38 : 0.60) scale 1 fps 14.0 read 3.25 rot 8.55 : [2.14 | 47.28 | 74.53] + 6.73 101.24 19.97 ONE_TEMP HUD : h 0.01 v 11.82
main:thrm:img (0.03 : 0.35 : 0.62) scale 1 fps 14.0 read 1.65 rot 4.09 : [2.10 | 24.26 | 43.18] + 3.29 57.32 10.86 ONE_TEMP HUD : h 0.00 v 12.12
main:thrm:img (0.02 : 0.35 : 0.63) scale 1 fps 14.0 read 1.60 rot 4.17 : [1.59 | 24.10 | 43.13] + 3.32 57.30 10.85 ONE_TEMP HUD : h 0.00 v 11.95
main:thrm:img (0.01 : 0.36 : 0.64) scale 1 fps 15.1 read 2.23 rot 5.87 : [0.60 | 31.67 | 56.18] + 4.56 73.64 12.90 ONE_TEMP OFF : h 0.00 v 13.10
main:thrm:img (0.00 : 0.36 : 0.64) scale 1 fps 14.9 read 1.67 rot 4.24 : [0.04 | 22.81 | 40.35] + 3.36 53.35 9.64 ONE_TEMP OFF : h 0.00 v 9.52
main:thrm:img (0.00 : 0.36 : 0.64) scale 1 fps 15.0 read 1.64 rot 4.25 : [0.04 | 22.79 | 39.80] + 3.37 52.51 9.34 ONE_TEMP OFF : h 0.00 v 8.48
main:thrm:img (0.00 : 0.36 : 0.64) scale 1 fps 14.9 read 1.64 rot 4.23 : [0.03 | 22.74 | 40.53] + 3.36 53.11 9.22 ONE_TEMP OFF : h 0.00 v 9.33
main:thrm:img (0.00 : 0.36 : 0.64) scale 1 fps 14.9 read 1.66 rot 4.26 : [0.03 | 22.97 | 40.67] + 3.33 53.66 9.66 ONE_TEMP OFF : h 0.00 v 9.58
main:thrm:img (0.00 : 0.36 : 0.64) scale 1 fps 14.9 read 1.69 rot 4.21 : [0.04 | 22.05 | 39.93] + 3.38 53.18 9.87 ONE_TEMP OFF : h 0.00 v 9.26
main:thrm:img (0.00 : 0.36 : 0.64) scale 1 fps 14.9 read 1.62 rot 4.24 : [0.03 | 22.65 | 40.79] + 3.40 53.39 9.20 ONE_TEMP OFF : h 0.00 v 9.63
main:thrm:img (0.00 : 0.36 : 0.64) scale 1 fps 14.9 read 1.66 rot 4.31 : [0.03 | 22.53 | 40.05] + 3.36 53.18 9.77 ONE_TEMP OFF : h 0.00 v 9.13
main:thrm:img (0.00 : 0.36 : 0.64) scale 1 fps 14.9 read 1.66 rot 4.24 : [0.03 | 22.53 | 40.43] + 3.36 53.33 9.54 ONE_TEMP OFF : h 0.00 v 9.40
main:thrm:img (0.00 : 0.36 : 0.64) scale 1 fps 14.9 read 1.66 rot 4.31 : [0.03 | 22.64 | 40.01] + 3.35 52.69 9.33 ONE_TEMP OFF : h 0.00 v 8.58
main:thrm:img (0.00 : 0.36 : 0.64) scale 1 fps 14.9 read 1.63 rot 4.24 : [0.04 | 22.62 | 39.82] + 3.35 52.58 9.40 ONE_TEMP OFF : h 0.00 v 8.87
main:thrm:img (0.00 : 0.36 : 0.64) scale 1 fps 14.9 read 1.62 rot 4.30 : [0.04 | 22.73 | 39.71] + 3.38 52.65 9.55 ONE_TEMP OFF : h 0.00 v 8.42
main:thrm:img (0.00 : 0.36 : 0.64) scale 1 fps 14.9 read 1.59 rot 4.27 : [0.03 | 22.56 | 40.00] + 3.36 52.71 9.35 ONE_TEMP OFF : h 0.00 v 8.80
main:thrm:img (0.00 : 0.35 : 0.65) scale 1 fps 14.1 read 2.43 rot 6.20 : [0.29 | 34.64 | 65.38] + 5.01 84.29 13.90 BOTH OFF : h 0.00 v 18.60
main:thrm:img (0.00 : 0.34 : 0.66) scale 1 fps 14.0 read 1.65 rot 4.18 : [0.14 | 23.25 | 44.75] + 3.34 57.53 9.44 BOTH OFF : h 0.00 v 13.36
main:thrm:img (0.00 : 0.34 : 0.66) scale 1 fps 14.0 read 1.65 rot 4.14 : [0.14 | 23.26 | 44.72] + 3.32 57.53 9.49 BOTH OFF : h 0.00 v 13.29
main:thrm:img (0.00 : 0.34 : 0.65) scale 1 fps 14.0 read 1.62 rot 4.18 : [0.17 | 23.33 | 44.37] + 3.35 57.23 9.51 BOTH OFF : h 0.00 v 13.15


RPi Zero v1.3 - Fast drag draw single thread

Online -scale 1
x1 14.3fps dragging single temperature point around with status hud enabled (was 13.9)
x1 double 11.5fps dragging single temperature point around with status hud disabled (was 10.9)

Offline
x2 19.5fps dragging both rulers around with status hud disabled
x1 double 24.0fps dragging single temperature point around with status hud disabled (was 23.3)
x1 double 23.2fps dragging both rulers around with status hud disabled (was 22.2)

Code: [Select]
Offline 2x
Startup timings: m 0.029, var 0.753, suo 0.233, pa 1.179, pkb 17.813, nw 1426.867, run 1.407, total 1448.281 stdout keybindings 11.5s image 13.7s
Startup timings: m 0.110, var 0.619, suo 0.262, pa 1.135, pkb 9.373, nw 1411.900, run 1.241, total 1424.640  stdout keybindings 11.7s image 13.9s
Startup timings: m 0.027, var 0.682, suo 0.359, pa 1.199, pkb 8.709, nw 1422.815, run 1.308, total 1435.099  stdout keybindings 11.5s image 13.7s

Offline -scale 1
Startup timings: m 0.027, var 0.811, suo 0.326, pa 1.148, pkb 8.411, nw 1400.667, run 1.287, total 1412.677  stdout keybindings 11.5s image 13.7s
Startup timings: m 0.027, var 0.667, suo 0.405, pa 1.342, pkb 8.201, nw 1422.054, run 1.381, total 1434.077  stdout keybindings 11.7s image 13.7s
Startup timings: m 0.028, var 1.116, suo 0.342, pa 1.188, pkb 8.818, nw 1517.689, run 1.247, total 1530.428  stdout keybindings 11.5s image 13.6s

main:thrm:img (0.01 : 0.10 : 0.88) scale 1 fps 23.4 read 0.01 rot 4.54 : [0.34 | 2.30 | 20.21] + 4.57 29.16 4.38 BOTH HUD : h 0.00 v 13.68
main:thrm:img (0.01 : 0.21 : 0.78) scale 1 fps 21.4 read 0.01 rot 6.10 : [0.36 | 9.34 | 34.07] + 9.57 55.42 11.78 BOTH OFF : h 0.01 v 25.88
main:thrm:img (0.01 : 0.30 : 0.69) scale 1 fps 22.4 read 0.01 rot 4.14 : [0.16 | 6.66 | 15.48] + 6.23 28.62 6.91 BOTH OFF : h 0.00 v 10.23
main:thrm:img (0.01 : 0.31 : 0.68) scale 1 fps 22.8 read 0.01 rot 4.14 : [0.15 | 7.02 | 15.46] + 6.17 28.74 7.10 BOTH OFF : h 0.00 v 10.20
main:thrm:img (0.01 : 0.30 : 0.69) scale 1 fps 23.0 read 0.01 rot 4.05 : [0.15 | 6.72 | 15.47] + 6.20 28.74 7.07 BOTH OFF : h 0.00 v 10.28
main:thrm:img (0.01 : 0.31 : 0.69) scale 1 fps 23.1 read 0.01 rot 4.19 : [0.15 | 7.00 | 15.70] + 6.16 28.92 7.05 BOTH OFF : h 0.00 v 10.39
main:thrm:img (0.01 : 0.31 : 0.69) scale 1 fps 23.2 read 0.01 rot 4.12 : [0.15 | 6.87 | 15.50] + 6.26 28.73 6.97 BOTH OFF : h 0.00 v 10.24
main:thrm:img (0.01 : 0.31 : 0.68) scale 1 fps 23.2 read 0.01 rot 4.11 : [0.16 | 7.00 | 15.49] + 6.29 29.02 7.24 BOTH OFF : h 0.00 v 10.26
main:thrm:img (0.01 : 0.30 : 0.70) scale 1 fps 23.2 read 0.01 rot 4.13 : [0.16 | 6.54 | 15.31] + 6.16 28.57 7.11 BOTH OFF : h 0.00 v 10.07
main:thrm:img (0.01 : 0.20 : 0.80) scale 1 fps 22.9 read 0.01 rot 3.68 : [0.14 | 5.11 | 20.58] + 6.01 33.67 7.08 BOTH OFF : h 0.00 v 15.78
main:thrm:img (0.01 : 0.19 : 0.81) scale 1 fps 22.5 read 0.01 rot 3.65 : [0.15 | 5.09 | 21.69] + 5.96 34.84 7.19 BOTH OFF : h 0.00 v 16.96
main:thrm:img (0.01 : 0.19 : 0.81) scale 1 fps 22.2 read 0.01 rot 3.65 : [0.14 | 5.04 | 21.57] + 5.94 34.72 7.21 BOTH OFF : h 0.00 v 16.83
main:thrm:img (0.01 : 0.19 : 0.81) scale 1 fps 21.9 read 0.01 rot 3.63 : [0.15 | 5.06 | 21.66] + 5.91 35.01 7.44 BOTH OFF : h 0.00 v 16.95
main:thrm:img (0.00 : 0.26 : 0.74) scale 1 fps 21.9 read 0.01 rot 3.65 : [0.04 | 5.46 | 15.78] + 5.92 28.64 6.93 ONE_TEMP OFF : h 0.00 v 10.55
main:thrm:img (0.00 : 0.30 : 0.70) scale 1 fps 23.5 read 0.01 rot 4.42 : [0.09 | 7.06 | 16.68] + 7.06 31.63 7.90 ONE_TEMP OFF : h 0.00 v 10.71
main:thrm:img (0.00 : 0.33 : 0.67) scale 1 fps 23.8 read 0.01 rot 4.02 : [0.03 | 6.72 | 13.80] + 6.33 27.32 7.19 ONE_TEMP OFF : h 0.00 v 8.60
main:thrm:img (0.00 : 0.32 : 0.68) scale 1 fps 23.9 read 0.01 rot 4.07 : [0.02 | 6.44 | 13.74] + 6.30 27.18 7.14 ONE_TEMP OFF : h 0.00 v 8.50
main:thrm:img (0.00 : 0.31 : 0.69) scale 1 fps 24.0 read 0.01 rot 3.98 : [0.02 | 6.23 | 13.62] + 6.25 27.10 7.23 ONE_TEMP OFF : h 0.00 v 8.48
main:thrm:img (0.00 : 0.32 : 0.67) scale 1 fps 24.0 read 0.01 rot 4.05 : [0.02 | 6.64 | 13.82] + 6.43 27.37 7.13 ONE_TEMP OFF : h 0.00 v 8.57
main:thrm:img (0.00 : 0.28 : 0.72) scale 1 fps 23.8 read 0.01 rot 3.70 : [0.02 | 5.59 | 14.63] + 5.96 27.56 6.97 ONE_TEMP OFF : h 0.00 v 9.83
main:thrm:img (0.00 : 0.26 : 0.74) scale 1 fps 23.6 read 0.01 rot 3.66 : [0.02 | 5.17 | 14.92] + 5.95 27.79 6.92 ONE_TEMP OFF : h 0.00 v 10.18
main:thrm:img (0.00 : 0.26 : 0.74) scale 1 fps 23.4 read 0.01 rot 3.65 : [0.02 | 5.18 | 14.89] + 5.91 27.71 6.90 ONE_TEMP OFF : h 0.00 v 10.17

Online -scale 1
Startup timings: m 0.065, var 0.568, suo 7.085, pa 367.689, pkb 9.064, nw 1539.779, run 1.384, total 1925.634
Startup timings: m 0.027, var 0.842, suo 0.274, pa 277.592, pkb 4.654, nw 1654.386, run 1.602, total 1939.377  stdout keybindings 12.0s image 14.9s
Startup timings: m 0.028, var 0.836, suo 0.335, pa 269.684, pkb 12.028, nw 1573.312, run 1.387, total 1857.610 stdout keybindings 12.3s image 15.1s
Startup timings: m 0.026, var 0.617, suo 0.294, pa 276.846, pkb 4.553, nw 1580.950, run 1.593, total 1864.879  stdout keybindings 12.1s image 14.8s

main:thrm:img (0.01 : 0.37 : 0.62) scale 1 fps 16.6 read 4.34 rot 7.44 : [1.33 | 38.15 | 64.96] + 5.77 87.38 16.65 OFF NO_DRAWINGS : h 0.00 v 7.66
main:thrm:img (0.00 : 0.40 : 0.60) scale 1 fps 15.3 read 2.05 rot 4.75 : [0.03 | 26.32 | 39.40] + 3.68 54.84 11.76 OFF NO_DRAWINGS : h 0.00 v 0.00
main:thrm:img (0.00 : 0.40 : 0.60) scale 1 fps 14.8 read 2.22 rot 4.58 : [0.03 | 27.25 | 40.45] + 3.59 56.61 12.58 OFF NO_DRAWINGS : h 0.00 v 0.00
main:thrm:img (0.01 : 0.36 : 0.63) scale 1 fps 14.4 read 3.57 rot 8.37 : [1.78 | 46.01 | 81.64] + 6.57 107.97 19.75 CROSS_HAIR HUD : h 0.00 v 12.85
main:thrm:img (0.03 : 0.33 : 0.64) scale 1 fps 14.3 read 1.72 rot 4.24 : [2.29 | 24.50 | 48.57] + 3.39 62.17 10.21 BOTH HUD : h 0.00 v 13.19
main:thrm:img (0.00 : 0.33 : 0.66) scale 1 fps 14.5 read 1.74 rot 4.32 : [0.20 | 22.58 | 44.91] + 3.37 57.53 9.25 CROSS_HAIR OFF : h 0.00 v 10.62
main:thrm:img (0.00 : 0.37 : 0.63) scale 1 fps 16.8 read 2.50 rot 6.67 : [0.22 | 33.14 | 57.36] + 5.22 76.73 14.15 ONE_TEMP NO_DRAWINGS : h 0.00 v 6.43
main:thrm:img (0.00 : 0.39 : 0.61) scale 1 fps 16.8 read 1.64 rot 4.40 : [0.03 | 21.56 | 33.21] + 3.40 45.55 8.94 ONE_TEMP NO_DRAWINGS : h 0.00 v 0.00
thermalDataThread(4363) - exiting
imageDataThread(3942) - exiting

main:thrm:img (0.02 : 0.36 : 0.62) scale 1 fps 13.1 read 3.23 rot 4.30 : [1.66 | 27.27 | 47.63] + 3.43 61.38 10.33 ONE_TEMP HUD : h 0.00 v 12.54
main:thrm:img (0.02 : 0.36 : 0.62) scale 1 fps 13.9 read 1.82 rot 4.35 : [1.73 | 27.61 | 48.39] + 3.46 61.57 9.72 ONE_TEMP HUD : h 0.00 v 12.44
main:thrm:img (0.02 : 0.35 : 0.63) scale 1 fps 14.2 read 1.81 rot 4.27 : [1.59 | 27.24 | 48.18] + 3.43 61.20 9.58 ONE_TEMP HUD : h 0.00 v 12.60
main:thrm:img (0.02 : 0.35 : 0.63) scale 1 fps 14.3 read 1.79 rot 4.33 : [1.35 | 27.22 | 48.84] + 3.44 61.85 9.56 ONE_TEMP HUD : h 0.00 v 12.86
main:thrm:img (0.02 : 0.35 : 0.62) scale 1 fps 14.3 read 1.81 rot 4.30 : [1.81 | 27.14 | 48.14] + 3.41 61.28 9.73 ONE_TEMP HUD : h 0.00 v 12.70
main:thrm:img (0.02 : 0.35 : 0.63) scale 1 fps 14.3 read 1.71 rot 4.19 : [1.55 | 26.12 | 46.19] + 3.32 59.76 10.25 ONE_TEMP HUD : h 0.01 v 12.66
main:thrm:img (0.02 : 0.36 : 0.62) scale 1 fps 14.2 read 1.65 rot 4.12 : [1.46 | 25.54 | 44.65] + 3.26 58.62 10.71 ONE_TEMP HUD : h 0.00 v 12.28
main:thrm:img (0.00 : 0.34 : 0.66) scale 1 fps 11.4 read 3.66 rot 9.48 : [0.52 | 60.56 | 117.14] + 10.73 145.05 17.18 ONE_TEMP OFF : h 0.01 v 22.20
main:thrm:img (0.00 : 0.33 : 0.67) scale 1 fps 11.5 read 1.78 rot 4.94 : [0.03 | 32.77 | 68.02] + 6.77 81.57 6.77 ONE_TEMP OFF : h 0.00 v 11.72
main:thrm:img (0.00 : 0.32 : 0.68) scale 1 fps 11.5 read 1.73 rot 4.80 : [0.04 | 32.03 | 67.87] + 6.86 81.74 7.01 ONE_TEMP OFF : h 0.00 v 11.67
main:thrm:img (0.00 : 0.31 : 0.69) scale 1 fps 11.1 read 1.63 rot 5.18 : [0.03 | 30.02 | 65.95] + 6.37 81.38 9.06 ONE_TEMP OFF : h 0.00 v 12.01
main:thrm:img (0.00 : 0.30 : 0.70) scale 1 fps 10.8 read 1.67 rot 5.30 : [0.03 | 28.70 | 66.34] + 6.40 81.73 8.98 ONE_TEMP OFF : h 0.00 v 12.41
thermalDataThread(4363) - exiting
imageDataThread(3942) - exiting
« Last Edit: January 16, 2024, 04:21:15 pm by Amish Technician »
 
The following users thanked this post: G28

Offline Amish Technician

  • Contributor
  • Posts: 30
  • Country: gb
Yep, will add -DNO_DRAG=1 to optionally disable drag scrolling, but even without it, it doesn't stop the user from using the click jump-scroll method.

This is true and a fair point, I was more thinking of a users first impression of the user experience because it causes the live image to stutter.

FAST_DRAG may speed up that stuttery update behavior.

Felt slightly less smooth at any given frame rate than I'd expect.

Part of what you are experiencing is 25 FPS.

Question, did it feel smoother in older versions ? 

I haven't noted any reduction in performance compared to older versions no. I was drawing a comparison to other Pi models with better CPUs, they felt smoother while reporting similar fps, eg RPi zero offline 1x double dragging rulers at ~22fps vs doing the same on RPi 2/3 at a higher scale with the same or even slightly lower fps. I wonder if this is due to them having 4 CPU cores instead of 1.
 
The following users thanked this post: G28

Offline G28Topic starter

  • Regular Contributor
  • *
  • Posts: 74
  • Country: us
    • Thermal Camera Redux
The FAST_DRAG mods only apply to ruler plots.  The improvements in the single thread rendering of single temps warrant refactoring the other parts of the code for the single threaded hardware.

I can make a conditionally compiled hybrid jump/drag scroll version, but don't know if it will confuse users why drag works in one mode and not the other.  Guess that is what documentation is for.  :)

The startup stats are in milliseconds.  Getting to PKB is taking less than [10-20] milliseconds, so I have to attribute the majority of the 11-12 seconds to loading off the SD card and the app initializing global variables (e.g. additional colormaps) before calling main().  I can add a flush to stdout after the prints to see if they appear sooner, but I don't think I can do anything about the SD load speeds.  Maybe the Pi needs a ramdisk to load apps from.

« Last Edit: January 15, 2024, 03:25:28 am by G28 »
 
The following users thanked this post: Amish Technician

Offline 5U4GB

  • Frequent Contributor
  • **
  • Posts: 391
  • Country: au
Finally got a bit of time to play with it on an ODroid.  Some notes, and I'll provide longish dumps so others can see the expected output...

You need both the OpenCV dev tools and the V4L utilities to run it, and for the build CFLAGS using -march=native would be a lot easier than having to set device-specific options, so "CFLAGS='-march=native -pipe -fomit-frame-pointer'" is a one-size-fits-all entry:

Code: [Select]
# This will install ~500MB of gunk
sudo apt-get install libopencv-dev
./build_redux
sudo apt-get install v4l-utils

When you plug in the camera it'll turn up as a generic USB camera:

Code: [Select]
> lsusb
Bus 002 Device 002: ID 05e3:0620 Genesys Logic, Inc. USB3.1 Hub
Bus 002 Device 001: ID 1d6b:0003 Linux Foundation 3.0 root hub
-> Bus 001 Device 004: ID 0bda:5830 Realtek Semiconductor Corp. USB Camera
Bus 001 Device 002: ID 05e3:0610 Genesys Logic, Inc. Hub
Bus 001 Device 001: ID 1d6b:0002 Linux Foundation 2.0 root hub

On the ODroid it required a reboot to set up the drivers, with just hotplug I got:

Code: [Select]
[3873017.213567] usb 1-1.1: new high-speed USB device number 4 using xhci-hcd
[3873017.485976] usb 1-1.1: New USB device found, idVendor=0bda, idProduct=5830
[3873017.485980] usb 1-1.1: New USB device strings: Mfr=3, Product=1, SerialNumber=2
[3873017.485982] usb 1-1.1: Product: USB Camera
[3873017.485984] usb 1-1.1: Manufacturer: Generic
[3873017.485986] usb 1-1.1: SerialNumber: 200901010001
[3873017.522882] usb 1-1.1: Unsupported device
[3873017.522983] usb 1-1.1: Unsupported device

With a reboot I got:

Code: [Select]
[    7.366970] usb 1-1.1: new high-speed USB device number 3 using xhci-hcd
[    7.639681] usb 1-1.1: New USB device found, idVendor=0bda, idProduct=5830
[    7.641078] usb 1-1.1: New USB device strings: Mfr=3, Product=1, SerialNumber=2
[    7.648574] usb 1-1.1: Product: USB Camera
[    7.652796] usb 1-1.1: Manufacturer: Generic
[    7.657213] usb 1-1.1: SerialNumber: 200901010001
[    7.706387] usb 1-1.1: Unsupported device
[    7.706478] usb 1-1.1: Unsupported device
[   10.330514] uvcvideo: Found UVC 1.00 device USB Camera (0bda:5830)
[   10.345930] uvcvideo 1-1.1:1.0: Entity type for entity Extension 4 was not initialized!
[   10.345938] uvcvideo 1-1.1:1.0: Entity type for entity Processing 2 was not initialized!
[   10.345941] uvcvideo 1-1.1:1.0: Entity type for entity Camera 1 was not initialized!
[   10.346181] input: USB Camera as /devices/platform/ff500000.dwc3/xhci-hcd.0.auto/usb1/1-1/1-1.1/1-1.1:1.0/input/input1
[   10.350606] usbcore: registered new interface driver uvcvideo
[   10.350612] USB Video Class driver (1.1.1)

Be aware of the fact that the ODroid firmware image installs a bunch of default loopback video devices so if you see:

Code: [Select]
0 video10
0 video13
0 video14
0 video15
0 video16
0 video17
0 video18
0 video19
0 video20
0 video21
0 video23

then the camera isn't being picked up, it should be video device 0.

Code: [Select]
> udevadm info --a --name /dev/video0

[...]

  looking at device '/devices/platform/ff500000.dwc3/xhci-hcd.0.auto/usb1/1-1/1-1.1/1-1.1:1.0/video4linux/video0':
    KERNEL=="video0"
    SUBSYSTEM=="video4linux"
    DRIVER==""
    ATTR{dev_debug}=="0"
    ATTR{index}=="0"
    ATTR{name}=="USB Camera"
    ATTR{power/control}=="auto"
    ATTR{power/runtime_active_time}=="0"
    ATTR{power/runtime_status}=="unsupported"
    ATTR{power/runtime_suspended_time}=="0"

[...]

  looking at parent device '/devices/platform/ff500000.dwc3/xhci-hcd.0.auto/usb1/1-1/1-1.1':
    KERNELS=="1-1.1"
    SUBSYSTEMS=="usb"
    DRIVERS=="usb"
    ATTRS{authorized}=="1"
    ATTRS{avoid_reset_quirk}=="0"
    ATTRS{bConfigurationValue}=="1"
    ATTRS{bDeviceClass}=="ef"
    ATTRS{bDeviceProtocol}=="01"
    ATTRS{bDeviceSubClass}=="02"
    ATTRS{bMaxPacketSize0}=="64"
    ATTRS{bMaxPower}=="500mA"
    ATTRS{bNumConfigurations}=="1"
    ATTRS{bNumInterfaces}==" 2"
    ATTRS{bcdDevice}=="1101"
    ATTRS{bmAttributes}=="80"
    ATTRS{busnum}=="1"
    ATTRS{configuration}=="USB Camera"
    ATTRS{devnum}=="3"
    ATTRS{devpath}=="1.1"
    ATTRS{idProduct}=="5830"
    ATTRS{idVendor}=="0bda"
    ATTRS{ltm_capable}=="no"
    ATTRS{manufacturer}=="Generic"
    ATTRS{maxchild}=="0"
    ATTRS{power/active_duration}=="287456"
    ATTRS{power/autosuspend}=="2"
    ATTRS{power/autosuspend_delay_ms}=="2000"
    ATTRS{power/connected_duration}=="287456"
    ATTRS{power/control}=="auto"
    ATTRS{power/level}=="auto"
    ATTRS{power/persist}=="1"
    ATTRS{power/runtime_active_time}=="287212"
    ATTRS{power/runtime_status}=="active"
    ATTRS{power/runtime_suspended_time}=="0"
    ATTRS{product}=="USB Camera"
    ATTRS{quirks}=="0x0"
    ATTRS{removable}=="unknown"
    ATTRS{serial}=="200901010001"
    ATTRS{speed}=="480"
    ATTRS{urbnum}=="70"
    ATTRS{version}==" 2.00"

[...]

I assume that serial number will be the same across all cameras, is anyone seeing a different value there?

For the video details:

Code: [Select]
> sudo v4l2-ctl --all --device /dev/video0
Driver Info:
        Driver name      : uvcvideo
        Card type        : USB Camera
        Bus info         : usb-xhci-hcd.0.auto-1.1
        Driver version   : 4.9.255
        Capabilities     : 0x84200001
                Video Capture
                Streaming
                Extended Pix Format
                Device Capabilities
        Device Caps      : 0x04200001
                Video Capture
                Streaming
                Extended Pix Format
Media Driver Info:
        Driver name      : uvcvideo
        Model            : USB Camera
        Serial           : 200901010001
        Bus info         : usb-xhci-hcd.0.auto-1.1
        Media version    : 0.1.0
        Hardware revision: 0x00001101 (4353)
        Driver version   : 4.9.255
Interface Info:
        ID               : 0x03000002
        Type             : V4L Video
Entity Info:
        ID               : 0x00000001 (1)
        Name             : USB Camera
        Function         : V4L2 I/O
        Pad 0x01000004   : Sink
          Link 0x0200000d: from remote pad 0x1000007 of entity 'Extension 4' (Unknown V4L2 Sub-Device): Data, Enabled, Immutable
Priority: 2
Video input : 0 (Camera 1: ok)
Format Video Capture:
        Width/Height      : 256/192
        Pixel Format      : 'YUYV' (YUYV 4:2:2)
        Field             : None
        Bytes per Line    : 512
        Size Image        : 98304
        Colorspace        : sRGB
        Transfer Function : Default (maps to sRGB)
        YCbCr/HSV Encoding: Default (maps to ITU-R 601)
        Quantization      : Default (maps to Limited Range)
        Flags             :
Crop Capability Video Capture:
        Bounds      : Left 0, Top 0, Width 256, Height 192
        Default     : Left 0, Top 0, Width 256, Height 192
        Pixel Aspect: 1/1
Selection Video Capture: crop_default, Left 0, Top 0, Width 256, Height 192, Flags:
Selection Video Capture: crop_bounds, Left 0, Top 0, Width 256, Height 192, Flags:
Streaming Parameters Video Capture:
        Capabilities     : timeperframe
        Frames per second: 25.000 (25/1)
        Read buffers     : 0
                     brightness 0x00980900 (int)    : min=-64 max=64 step=1 default=0 value=0
                       contrast 0x00980901 (int)    : min=0 max=100 step=1 default=50 value=50
                     saturation 0x00980902 (int)    : min=0 max=100 step=1 default=64 value=64
                            hue 0x00980903 (int)    : min=-180 max=180 step=1 default=0 value=0
 white_balance_temperature_auto 0x0098090c (bool)   : default=1 value=1
                          gamma 0x00980910 (int)    : min=100 max=500 step=1 default=300 value=300
           power_line_frequency 0x00980918 (menu)   : min=0 max=2 default=1 value=1 (50 Hz)
                                0: Disabled
                                1: 50 Hz
                                2: 60 Hz
      white_balance_temperature 0x0098091a (int)    : min=2800 max=6500 step=10 default=4600 value=4600 flags=inactive
                      sharpness 0x0098091b (int)    : min=0 max=100 step=1 default=50 value=50
         backlight_compensation 0x0098091c (int)    : min=0 max=1 step=1 default=0 value=0
                  exposure_auto 0x009a0901 (menu)   : min=0 max=3 default=3 value=3 (Aperture Priority Mode)
                                1: Manual Mode
                                3: Aperture Priority Mode
              exposure_absolute 0x009a0902 (int)    : min=50 max=10000 step=1 default=166 value=166 flags=inactive
         exposure_auto_priority 0x009a0903 (bool)   : default=0 value=1

Now I'm stuck in a maze of X11 plumbing to try and get it to display output via SSH-forwarded X11... would it be possible to add a -b batch-mode flag to just grab a frame of video and dump it to disk?

Another bit of feedback, it's annoyingly chatty which means I keep having to scroll back through all the output to find the bit I want, it'd be good to have the credits and usage only displayed in response to '--help' so you can see the useful output at a glance.
 
The following users thanked this post: G28, Amish Technician

Offline Amish Technician

  • Contributor
  • Posts: 30
  • Country: gb
for the build CFLAGS using -march=native would be a lot easier than having to set device-specific options, so "CFLAGS='-march=native -pipe -fomit-frame-pointer'" is a one-size-fits-all entry:
Agreed. I used device specific options so I could cross compile code optimised for slower RPis on a faster RPi, however for the purposes of sharing on github I think your suggestion makes a lot more sense as most people will compile on the device it will run on.  :-+

Another bit of feedback, it's annoyingly chatty which means I keep having to scroll back through all the output to find the bit I want, it'd be good to have the credits and usage only displayed in response to '--help' so you can see the useful output at a glance.
Good idea, how about verbose mode option '-v  --verbose'

and a help option '-?  -h  --help'
 

Offline G28Topic starter

  • Regular Contributor
  • *
  • Posts: 74
  • Country: us
    • Thermal Camera Redux
...

Thanks for the update.

My TC001's serial number is the same as yours.

Added a "-quiet" flag to quiet STDOUT prints and stat logging prints.

Added a "-help" flag to print and exit.

Will add "-snapshot prefix" and "-record prefix" 'batch' features to the TODO list.

Will investigate the camera open error.  I disabled it via the "-quiet" flag during the interim.

« Last Edit: January 15, 2024, 04:24:04 pm by G28 »
 
The following users thanked this post: Amish Technician

Offline G28Topic starter

  • Regular Contributor
  • *
  • Posts: 74
  • Country: us
    • Thermal Camera Redux

Good idea, how about verbose mode option '-v  --verbose'

and a help option '-?  -h  --help'

I will move stat logging over to "-verbose" or "-stat" once we get the single threaded platform optimizations finalized.
 
The following users thanked this post: Amish Technician

Offline G28Topic starter

  • Regular Contributor
  • *
  • Posts: 74
  • Country: us
    • Thermal Camera Redux
Review update.
« Reply #71 on: January 15, 2024, 06:10:23 pm »
Requested feature:

"-snapshot [prefix]" and exit has been added to the pre-release.

If the optional prefix isn't added, it uses the default timestamp naming convention for the .png and .raw files.

[prefix] can consist of alpha-numeric characters, underscores and hyphens as long as it does NOT start with a hyphen to differentiate it from a command line -flag.
« Last Edit: January 15, 2024, 06:12:18 pm by G28 »
 

Offline Amish Technician

  • Contributor
  • Posts: 30
  • Country: gb
The banding/shimmering issue isn't caused by redux, I've checked with all my RPi's opening the TC001 as a capture device in VLC:
RPi Zero   Good
RPi Zero2 Minimal
RPi2v1.1   Bad
RPi2v1.2   Minimal
RPi3v1.2   Bad
RPi4          Good
RPi5          Good

I'll look into this further to try and understand what causes it/how to mitigate it.


The test version DRAW_SINGLE_THREAD has yeild a further improvment in FPS for the single threaded RPi zero. Props G28 for the significant improvements since I first tested on the RPi zero and it struggled to get above single digit FPS.  :-+

RPi Zero v1.3 - No Drag

Online -scale 1
x1 18.9fps no hud (was 17.1)
x1 15.3fps default hud (was 14.0)
x1 16.4fps single temperature point with status hud disabled (was 14.9 )
x1 15.1fps both rulers with status hud disabled (was 14.0 )
x1 double 9.7fps both rulers with status hud enabled (was 9.7 )
x1 double 12.9fps no hud (was 11.8 )

Code: [Select]
-DNO_DRAG=1 -DFAST_DRAG=1 -DDRAW_SINGLE_THREAD=1
Startup timings: s 14.712, var 0.523, suo 7.021, pa 273.823, pkb 8.210, nw 1393.966, run 0.516, total 1698.771
main:thrm:img (1.00 : 0.24 : 0.75) scale 1 fps 15.6 read 4.32 rot 8.03 : [90.09 | 22.04 | 67.69] + 5.87 96.07 0.10 ONE_TEMP HUD : h 0.00 v 21.33
main:thrm:img (1.00 : 0.25 : 0.75) scale 1 fps 15.6 read 1.58 rot 4.28 : [47.32 | 11.66 | 35.47] + 3.15 50.51 0.05 ONE_TEMP HUD : h 0.00 v 10.76
main:thrm:img (1.00 : 0.25 : 0.75) scale 1 fps 15.6 read 1.57 rot 4.26 : [47.90 | 11.78 | 35.94] + 3.15 51.10 0.04 ONE_TEMP HUD : h 0.00 v 11.10
main:thrm:img (1.00 : 0.24 : 0.75) scale 1 fps 15.6 read 1.58 rot 4.25 : [47.68 | 11.67 | 35.82] + 3.17 50.90 0.04 ONE_TEMP HUD : h 0.00 v 11.09
main:thrm:img (1.00 : 0.24 : 0.75) scale 1 fps 15.6 read 1.52 rot 4.27 : [48.06 | 11.71 | 36.15] + 3.21 51.31 0.04 ONE_TEMP HUD : h 0.00 v 11.40
main:thrm:img (1.00 : 0.25 : 0.75) scale 1 fps 15.5 read 1.53 rot 4.23 : [48.22 | 11.82 | 36.19] + 3.19 51.45 0.04 ONE_TEMP HUD : h 0.00 v 11.41
main:thrm:img (1.00 : 0.25 : 0.75) scale 1 fps 15.5 read 1.55 rot 4.30 : [47.76 | 11.73 | 35.84] + 3.22 51.03 0.05 ONE_TEMP HUD : h 0.00 v 11.09
Startup timings: s 1.845, var 0.526, suo 0.312, pa 271.071, pkb 4.054, nw 1496.493, run 0.524, total 1774.825
main:thrm:img (1.00 : 0.25 : 0.75) scale 1 fps 15.5 read 4.69 rot 8.75 : [104.83 | 26.23 | 78.16] + 7.04 111.96 0.10 OFF HUD : h 0.00 v 24.54
main:thrm:img (1.00 : 0.25 : 0.75) scale 1 fps 15.4 read 1.56 rot 4.24 : [49.07 | 12.17 | 36.71] + 3.21 52.33 0.04 OFF HUD : h 0.00 v 11.62
main:thrm:img (1.00 : 0.25 : 0.75) scale 1 fps 15.3 read 1.56 rot 4.22 : [49.13 | 12.08 | 36.86] + 3.17 52.34 0.04 OFF HUD : h 0.00 v 11.82
main:thrm:img (1.00 : 0.24 : 0.75) scale 1 fps 15.3 read 1.54 rot 4.31 : [49.32 | 12.07 | 37.07] + 3.18 52.57 0.07 OFF HUD : h 0.00 v 11.93
main:thrm:img (1.00 : 0.24 : 0.75) scale 1 fps 15.3 read 1.56 rot 4.29 : [49.57 | 12.05 | 37.33] + 3.15 52.77 0.05 OFF HUD : h 0.00 v 12.24
Startup timings: s 1.793, var 0.685, suo 0.326, pa 273.368, pkb 4.283, nw 1496.998, run 0.521, total 1777.974
main:thrm:img (1.00 : 0.31 : 0.69) scale 1 fps 18.9 read 3.42 rot 5.77 : [49.47 | 15.35 | 33.99] + 4.17 53.70 0.06 OFF ONLY_VIDEO : h 0.00 v 3.21
main:thrm:img (1.00 : 0.34 : 0.66) scale 1 fps 18.9 read 1.57 rot 4.69 : [36.29 | 12.16 | 24.08] + 3.26 39.59 0.04 OFF ONLY_VIDEO : h 0.00 v 0.00
main:thrm:img (1.00 : 0.33 : 0.67) scale 1 fps 18.9 read 1.56 rot 4.69 : [36.47 | 12.16 | 24.26] + 3.26 39.78 0.05 OFF ONLY_VIDEO : h 0.00 v 0.00
main:thrm:img (1.00 : 0.33 : 0.67) scale 1 fps 18.9 read 1.61 rot 4.57 : [35.78 | 11.88 | 23.85] + 3.26 39.08 0.04 OFF ONLY_VIDEO : h 0.00 v 0.00
main:thrm:img (1.00 : 0.28 : 0.72) scale 1 fps 16.5 read 2.49 rot 6.92 : [67.44 | 18.93 | 48.38] + 5.15 72.66 0.07 OFF OFF : h 0.00 v 10.19
main:thrm:img (1.00 : 0.27 : 0.73) scale 1 fps 16.4 read 1.53 rot 4.28 : [44.54 | 11.82 | 32.67] + 3.22 47.81 0.04 OFF OFF : h 0.00 v 8.57
main:thrm:img (1.00 : 0.27 : 0.73) scale 1 fps 16.4 read 1.50 rot 4.40 : [44.67 | 11.93 | 32.69] + 3.26 47.98 0.05 OFF OFF : h 0.00 v 8.32
main:thrm:img (1.00 : 0.27 : 0.73) scale 1 fps 16.4 read 1.53 rot 4.35 : [44.64 | 11.90 | 32.69] + 3.26 47.94 0.04 OFF OFF : h 0.00 v 8.49
main:thrm:img (1.00 : 0.27 : 0.73) scale 1 fps 16.4 read 1.60 rot 4.32 : [44.75 | 11.95 | 32.75] + 3.25 48.05 0.05 OFF OFF : h 0.00 v 8.48
main:thrm:img (1.00 : 0.24 : 0.75) scale 1 fps 15.1 read 2.01 rot 5.66 : [65.52 | 15.95 | 49.35] + 4.30 69.89 0.06 BOTH OFF : h 0.00 v 17.21
main:thrm:img (1.00 : 0.24 : 0.75) scale 1 fps 15.1 read 1.51 rot 4.19 : [49.69 | 12.04 | 37.47] + 3.17 52.95 0.09 BOTH OFF : h 0.00 v 13.49
main:thrm:img (1.00 : 0.24 : 0.75) scale 1 fps 15.1 read 1.54 rot 4.26 : [50.18 | 12.12 | 37.88] + 3.24 53.47 0.04 BOTH OFF : h 0.00 v 13.69
main:thrm:img (1.00 : 0.24 : 0.75) scale 1 fps 15.1 read 1.54 rot 4.17 : [49.70 | 12.04 | 37.47] + 3.19 52.93 0.04 BOTH OFF : h 0.00 v 13.51
main:thrm:img (1.00 : 0.22 : 0.77) scale 1 fps 9.8 read 2.16 rot 6.29 : [100.82 | 21.81 | 78.08] + 7.39 108.28 0.06 BOTH HUD : h 0.00 v 30.83
main:thrm:img (1.00 : 0.21 : 0.78) scale 1 fps 9.7 read 1.54 rot 4.49 : [79.32 | 16.89 | 61.75] + 6.00 85.36 0.04 BOTH HUD : h 0.00 v 25.15
main:thrm:img (1.00 : 0.22 : 0.77) scale 1 fps 9.7 read 1.62 rot 4.23 : [79.50 | 17.14 | 61.57] + 6.02 85.57 0.04 BOTH HUD : h 0.00 v 25.26
main:thrm:img (1.00 : 0.29 : 0.70) scale 1 fps 12.9 read 1.80 rot 5.67 : [69.75 | 19.94 | 48.95] + 7.49 77.30 0.07 BOTH ONLY_VIDEO : h 0.00 v 5.84
main:thrm:img (1.00 : 0.32 : 0.67) scale 1 fps 12.9 read 1.52 rot 4.43 : [52.95 | 16.80 | 35.48] + 6.30 59.30 0.06 BOTH ONLY_VIDEO : h 0.00 v 0.00
main:thrm:img (1.00 : 0.32 : 0.67) scale 1 fps 12.9 read 1.54 rot 4.76 : [53.01 | 16.79 | 35.69] + 6.26 59.32 0.05 BOTH ONLY_VIDEO : h 0.00 v 0.00
main:thrm:img (1.00 : 0.33 : 0.66) scale 1 fps 12.9 read 1.53 rot 4.22 : [53.15 | 17.35 | 35.22] + 6.23 59.42 0.04 BOTH ONLY_VIDEO : h 0.00 v 0.00
main:thrm:img (1.00 : 0.29 : 0.71) scale 1 fps 15.9 read 2.83 rot 7.95 : [90.41 | 26.07 | 63.84] + 8.23 98.73 0.09 ONE_TEMP OFF : h 0.00 v 9.87
main:thrm:img (1.00 : 0.26 : 0.74) scale 1 fps 16.0 read 1.53 rot 4.34 : [45.67 | 11.87 | 33.75] + 3.20 48.92 0.04 ONE_TEMP OFF : h 0.00 v 8.92
main:thrm:img (1.00 : 0.26 : 0.74) scale 1 fps 16.0 read 1.52 rot 4.36 : [45.89 | 11.89 | 33.95] + 3.27 49.20 0.05 ONE_TEMP OFF : h 0.00 v 8.99
main:thrm:img (1.00 : 0.26 : 0.74) scale 1 fps 16.0 read 1.56 rot 4.44 : [45.85 | 11.94 | 33.85] + 3.24 49.13 0.04 ONE_TEMP OFF : h 0.00 v 8.98
main:thrm:img (1.00 : 0.26 : 0.74) scale 1 fps 16.0 read 1.55 rot 4.37 : [45.76 | 11.88 | 33.82] + 3.22 49.02 0.04 ONE_TEMP OFF : h 0.00 v 8.84


RPi Zero v1.3 - Fast drag draw single thread

Offline
x2 21.0fps dragging both rulers around with status hud disabled (was 19.5 )
x1 double 24.3fps dragging single temperature point around with status hud disabled (was 24.0, 23.3 )
x1 double 23.8fps dragging both rulers around with status hud disabled (was 23.2, 22.2 )

Online -scale 1
x1 16.0fps dragging single temperature point around with status hud enabled (was 14.3, 13.9 )
x1 double 11.7fps dragging single temperature point around with status hud disabled (was 11.5, 10.9 )
x1 16.9fps dragging single temperature point around with status hud disabled

Code: [Select]
-DNO_DRAG=0 -DFAST_DRAG=1 -DDRAW_SINGLE_THREAD=1
Startup timings: s 15.435, var 0.518, suo 7.039, pa 1.257, pkb 8.521, nw 1395.784, run 0.512, total 1429.066
main:thrm:img (1.00 : 0.10 : 0.89) scale 2 fps 12.3 read 0.01 rot 5.38 : [65.15 | 6.64 | 57.95] + 35.28 100.52 0.09 BOTH OFF : h 0.00 v 31.92
main:thrm:img (1.00 : 0.12 : 0.87) scale 2 fps 12.6 read 0.00 rot 4.32 : [37.41 | 4.58 | 32.55] + 26.84 64.30 0.04 BOTH OFF : h 0.00 v 17.00
main:thrm:img (1.00 : 0.12 : 0.87) scale 2 fps 12.5 read 0.00 rot 4.06 : [38.33 | 4.67 | 33.41] + 26.79 65.16 0.03 BOTH OFF : h 0.00 v 17.83
main:thrm:img (1.00 : 0.11 : 0.89) scale 2 fps 12.1 read 0.00 rot 3.97 : [41.24 | 4.42 | 36.62] + 28.45 69.72 0.03 BOTH OFF : h 0.00 v 18.94
main:thrm:img (1.00 : 0.12 : 0.88) scale 2 fps 12.1 read 0.00 rot 4.28 : [38.47 | 4.45 | 33.82] + 27.19 65.71 0.06 BOTH OFF : h 0.00 v 17.68
main:thrm:img (1.00 : 0.11 : 0.88) scale 2 fps 12.1 read 0.00 rot 3.92 : [39.23 | 4.50 | 34.48] + 27.45 66.72 0.03 BOTH OFF : h 0.00 v 18.06
main:thrm:img (1.00 : 0.06 : 0.94) scale 2 fps 11.3 read 0.00 rot 3.55 : [71.34 | 4.21 | 66.94] + 21.98 93.36 0.03 BOTH OFF : h 0.00 v 46.18
main:thrm:img (1.00 : 0.06 : 0.94) scale 2 fps 10.7 read 0.00 rot 3.54 : [72.34 | 4.23 | 67.91] + 21.93 94.32 0.05 BOTH OFF : h 0.00 v 46.83
main:thrm:img (1.00 : 0.06 : 0.94) scale 2 fps 10.3 read 0.01 rot 3.56 : [72.80 | 4.07 | 68.54] + 21.78 94.61 0.03 BOTH OFF : h 0.00 v 47.62
main:thrm:img (1.00 : 0.06 : 0.94) scale 2 fps 10.0 read 0.01 rot 3.59 : [73.97 | 4.17 | 69.59] + 21.50 95.50 0.03 BOTH OFF : h 0.00 v 48.56
main:thrm:img (1.00 : 0.06 : 0.94) scale 1 fps 9.7 read 0.00 rot 3.58 : [73.75 | 4.09 | 69.47] + 21.43 95.21 0.03 BOTH OFF : h 0.00 v 48.40
main:thrm:img (1.00 : 0.06 : 0.93) scale 2 fps 20.8 read 0.01 rot 5.42 : [38.58 | 2.19 | 36.07] + 15.72 54.35 0.05 BOTH OFF : h 0.00 v 22.75
main:thrm:img (1.00 : 0.02 : 0.97) scale 2 fps 21.1 read 0.01 rot 3.98 : [21.51 | 0.47 | 20.81] + 12.14 33.69 0.04 BOTH OFF : h 0.00 v 11.89
main:thrm:img (1.00 : 0.02 : 0.97) scale 2 fps 20.8 read 0.00 rot 3.82 : [21.93 | 0.47 | 21.25] + 12.26 34.22 0.04 BOTH OFF : h 0.00 v 12.63
main:thrm:img (1.00 : 0.02 : 0.97) scale 2 fps 21.0 read 0.00 rot 3.97 : [21.50 | 0.47 | 20.84] + 12.18 33.71 0.04 BOTH OFF : h 0.00 v 12.17
main:thrm:img (1.00 : 0.02 : 0.97) scale 2 fps 21.1 read 0.01 rot 4.02 : [21.45 | 0.49 | 20.76] + 12.09 33.57 0.03 BOTH OFF : h 0.00 v 11.91
main:thrm:img (1.00 : 0.07 : 0.93) scale 1 fps 20.6 read 0.00 rot 3.72 : [27.90 | 1.86 | 25.83] + 9.22 37.15 0.03 BOTH OFF : h 0.00 v 18.48
main:thrm:img (1.00 : 0.21 : 0.79) scale 1 fps 24.3 read 0.01 rot 4.77 : [26.54 | 5.59 | 20.87] + 7.28 33.86 0.05 ONE_TEMP OFF : h 0.00 v 13.09
main:thrm:img (1.00 : 0.22 : 0.78) scale 1 fps 24.3 read 0.01 rot 4.09 : [20.82 | 4.52 | 16.22] + 6.03 26.89 0.04 ONE_TEMP OFF : h 0.00 v 9.90
main:thrm:img (1.00 : 0.23 : 0.77) scale 1 fps 24.3 read 0.01 rot 3.86 : [20.57 | 4.66 | 15.86] + 5.91 26.52 0.04 ONE_TEMP OFF : h 0.00 v 9.74
main:thrm:img (1.00 : 0.19 : 0.80) scale 1 fps 23.5 read 0.01 rot 6.67 : [40.96 | 7.85 | 32.88] + 10.30 51.32 0.06 BOTH OFF : h 0.00 v 21.74
main:thrm:img (1.00 : 0.20 : 0.79) scale 1 fps 23.7 read 0.01 rot 4.02 : [22.24 | 4.56 | 17.52] + 6.04 28.32 0.04 BOTH OFF : h 0.00 v 11.28
main:thrm:img (1.00 : 0.20 : 0.79) scale 1 fps 23.8 read 0.01 rot 4.06 : [22.19 | 4.44 | 17.58] + 5.98 28.21 0.04 BOTH OFF : h 0.00 v 11.36
main:thrm:img (1.00 : 0.20 : 0.80) scale 1 fps 23.8 read 0.01 rot 4.02 : [22.49 | 4.43 | 17.90] + 5.99 28.51 0.04 BOTH OFF : h 0.00 v 11.57
main:thrm:img (1.00 : 0.20 : 0.79) scale 1 fps 23.8 read 0.01 rot 4.08 : [22.13 | 4.46 | 17.48] + 5.95 28.12 0.04 BOTH OFF : h 0.00 v 11.33
Startup timings: s 1.774, var 0.600, suo 0.366, pa 369.657, pkb 0.673, nw 1433.173, run 0.551, total 1806.794
main:thrm:img (1.00 : 0.25 : 0.74) scale 1 fps 16.1 read 4.09 rot 6.85 : [81.10 | 20.52 | 60.22] + 5.20 86.38 0.08 ONE_TEMP HUD : h 0.00 v 18.15
main:thrm:img (1.00 : 0.25 : 0.74) scale 1 fps 16.0 read 1.74 rot 4.38 : [51.74 | 13.11 | 38.40] + 3.25 55.03 0.05 ONE_TEMP HUD : h 0.00 v 11.58
main:thrm:img (1.00 : 0.25 : 0.74) scale 1 fps 15.9 read 1.72 rot 4.36 : [52.31 | 13.22 | 38.87] + 3.32 55.69 0.05 ONE_TEMP HUD : h 0.00 v 11.85
main:thrm:img (1.00 : 0.25 : 0.74) scale 1 fps 15.9 read 1.73 rot 4.33 : [52.20 | 13.11 | 38.88] + 3.25 55.50 0.05 ONE_TEMP HUD : h 0.00 v 11.93
main:thrm:img (1.00 : 0.25 : 0.75) scale 1 fps 11.7 read 3.01 rot 7.75 : [114.38 | 28.42 | 85.68] + 9.19 123.65 0.09 ONE_TEMP OFF : h 0.00 v 21.42
main:thrm:img (1.00 : 0.24 : 0.75) scale 1 fps 11.7 read 1.65 rot 4.44 : [71.39 | 17.47 | 53.86] + 6.37 77.81 0.05 ONE_TEMP OFF : h 0.00 v 11.57
main:thrm:img (1.00 : 0.25 : 0.75) scale 1 fps 11.7 read 1.65 rot 4.38 : [71.81 | 17.84 | 53.90] + 6.43 78.29 0.05 ONE_TEMP OFF : h 0.00 v 11.48
main:thrm:img (1.00 : 0.26 : 0.74) scale 1 fps 16.9 read 2.55 rot 7.18 : [86.33 | 22.28 | 63.90] + 6.62 93.04 0.09 ONE_TEMP OFF : h 0.00 v 15.34
main:thrm:img (1.00 : 0.27 : 0.73) scale 1 fps 16.9 read 1.72 rot 4.45 : [47.86 | 13.02 | 34.78] + 3.32 51.23 0.05 ONE_TEMP OFF : h 0.00 v 8.22
main:thrm:img (1.00 : 0.27 : 0.73) scale 1 fps 16.9 read 1.74 rot 4.43 : [48.04 | 12.96 | 35.01] + 3.30 51.39 0.05 ONE_TEMP OFF : h 0.00 v 8.35
« Last Edit: January 16, 2024, 12:37:20 am by Amish Technician »
 
The following users thanked this post: G28

Offline 5U4GB

  • Frequent Contributor
  • **
  • Posts: 391
  • Country: au
Good idea, how about verbose mode option '-v  --verbose'

and a help option '-?  -h  --help'

Yup, sounds good.
 
The following users thanked this post: Amish Technician

Offline aerdoc

  • Newbie
  • Posts: 1
  • Country: us
Re: Portrait and Landscape Rotations in 90 degree increments
« Reply #74 on: January 16, 2024, 04:46:23 pm »
Just setup my Topdon on my RPi 4 this weekend and wow this is awesome! I've been messing a round with the FLIR Lepton the last few months but have been kind of disappointed by the lack of community development and wanting a higher resolution. I made a 3D model of the Topdon and I'm gonna adapt the bootleg zoom lens I made for the Lepton. If anyone's interested I can share the design.

I've got a question about the images below. What is that gradient affect happening to the right image? I was able to enable the 8-bit AGC Histogram Equalization on the Lepton and that's what it looked like.


 
The following users thanked this post: Amish Technician

Offline G28Topic starter

  • Regular Contributor
  • *
  • Posts: 74
  • Country: us
    • Thermal Camera Redux
Re: Portrait and Landscape Rotations in 90 degree increments
« Reply #75 on: January 16, 2024, 05:07:30 pm »
...

I've got a question about the images below. What is that gradient affect happening to the right image? I was able to enable the 8-bit AGC Histogram Equalization on the Lepton and that's what it looked like.




Each frame of the camera consists of 2 sub-frames.  1 sub-frame is the image and the other sub-frame is the thermal data in Kelvin.

There is 1 temperature value per pixel ( 256 x 192 temps in total ).

This double-wide image shows both the Image ( left ) + Thermal ( right ) sub-frame as indicated by the OSD text "Img - Therm".

The app allows each sub-frame to be displayed individually or jointly.

The app does have an optional  Histogram Equalization filter that can enabled / disabled as well as other optional filters and 37 colormaps.

Hope that answers your question.
« Last Edit: January 16, 2024, 05:09:21 pm by G28 »
 
The following users thanked this post: Amish Technician

Offline Amish Technician

  • Contributor
  • Posts: 30
  • Country: gb
I've done some more testing on the RPi zero with the new DRAW_SINGLE_THREAD version to compare performance while dragging both rulers (status hud disabled) with -DFAST_DRAG=0 and -DFAST_DRAG=1

OFFLINE
-DFAST_DRAG=0
1x Double 23.0 fps
2x 19.5 fps
-DFAST_DRAG=1
1x Double 23.3 fps
2x 19.2 fps

ONLINE
-DFAST_DRAG=0
1x Double 11.5 fps
1x 15.9 fps
-DFAST_DRAG=1
1x Double 11.3 fps
1x 16.0 fps

As you can see with DRAW_SINGLE_THREAD, frame rate averages are virtually identical with -DFAST_DRAG=0 or -DFAST_DRAG=1
I've gone back and forth between each to subjectively compare the experience for stuttering and frame rate consistency. Offline there was no benefit to fast drag. Online I think it now slightly reduces the experience: With fast drag there's stuttering while dragging slowly but freezes for a moment while dragging quickly, whereas without fast drag enabled it doesn't freeze.

My recommendations:

RPi 1, RPi Zero (W), RPi Compute Module 1
- Single thread
- Online: No drag
- Offline/Freeze frame: Normal drag

All other RPi models
- Multi thread
- Normal drag both online and offline

Not the conclusion I'd expected to come to as fast drag had measurably helped with the previous version, but it's good that this work around is no longer necessary thanks to the improvements from single threading for RPi zero.

DEFAULT_FLAGS='-DNO_DRAG=0 -DFAST_DRAG=0 -DDRAW_SINGLE_THREAD=1 -DDEFAULT_FONT=0 -DDEFAULT_COLORMAP=4 -DROTATION=0 -DDISPLAY_WIDTH=1920 -DDISPLAY_HEIGHT=1080 -DUSE_CELSIUS=1 -DHUD_ALPHA=0.4'
Code: [Select]
Offline

Startup timings: s 1.880, var 0.712, suo 0.357, pa 1.379, pkb 17.916, nw 1421.720, run 0.638, total 1444.602

1x Double, Dragging both rulers around with status hud disabled
main:thrm:img (1.00 : 0.17 : 0.82) scale 1 fps 22.2 read 0.04 rot 7.05 : [47.32 | 8.00 | 38.81] + 10.88 58.27 0.07 BOTH OFF : h 0.00 v 28.30
main:thrm:img (1.00 : 0.19 : 0.80) scale 1 fps 22.7 read 0.01 rot 4.40 : [24.67 | 4.77 | 19.69] + 6.05 30.76 0.04 BOTH OFF : h 0.00 v 14.07
main:thrm:img (1.00 : 0.19 : 0.80) scale 1 fps 22.9 read 0.01 rot 4.27 : [24.61 | 4.76 | 19.60] + 6.07 30.74 0.06 BOTH OFF : h 0.00 v 14.07
main:thrm:img (1.00 : 0.20 : 0.79) scale 1 fps 22.9 read 0.01 rot 4.26 : [24.84 | 4.86 | 19.74] + 6.13 31.02 0.05 BOTH OFF : h 0.00 v 14.26
main:thrm:img (1.00 : 0.20 : 0.79) scale 1 fps 23.0 read 0.01 rot 4.16 : [24.60 | 4.87 | 19.53] + 6.03 30.67 0.04 BOTH OFF : h 0.01 v 14.16
main:thrm:img (1.00 : 0.20 : 0.80) scale 1 fps 23.0 read 0.01 rot 4.31 : [24.63 | 4.80 | 19.60] + 6.10 30.77 0.04 BOTH OFF : h 0.00 v 14.09
main:thrm:img (1.00 : 0.19 : 0.80) scale 1 fps 23.0 read 0.01 rot 4.29 : [24.83 | 4.80 | 19.81] + 6.12 30.99 0.04 BOTH OFF : h 0.00 v 14.35

2x Dragging both rulers around with status hud disabled
main:thrm:img (1.00 : 0.03 : 0.96) scale 2 fps 19.2 read 0.01 rot 4.24 : [24.45 | 0.62 | 23.58] + 14.08 38.57 0.04 BOTH OFF : h 0.00 v 13.89
main:thrm:img (1.00 : 0.02 : 0.97) scale 2 fps 19.3 read 0.01 rot 4.18 : [24.41 | 0.58 | 23.60] + 13.95 38.41 0.04 BOTH OFF : h 0.00 v 14.22
main:thrm:img (1.00 : 0.02 : 0.96) scale 2 fps 19.4 read 0.01 rot 4.25 : [24.85 | 0.60 | 23.98] + 13.70 38.59 0.04 BOTH OFF : h 0.00 v 14.27
main:thrm:img (1.00 : 0.02 : 0.97) scale 2 fps 19.5 read 0.01 rot 4.20 : [24.63 | 0.59 | 23.81] + 13.69 38.36 0.04 BOTH OFF : h 0.00 v 14.08
main:thrm:img (1.00 : 0.02 : 0.97) scale 2 fps 19.5 read 0.01 rot 4.40 : [24.55 | 0.58 | 23.76] + 13.84 38.43 0.04 BOTH OFF : h 0.00 v 13.94
main:thrm:img (1.00 : 0.02 : 0.96) scale 2 fps 19.5 read 0.01 rot 4.19 : [24.71 | 0.61 | 23.79] + 13.85 38.61 0.04 BOTH OFF : h 0.00 v 14.35
main:thrm:img (1.00 : 0.03 : 0.96) scale 2 fps 19.5 read 0.01 rot 4.05 : [24.72 | 0.64 | 23.85] + 13.84 38.60 0.04 BOTH OFF : h 0.00 v 14.32
main:thrm:img (1.00 : 0.02 : 0.97) scale 2 fps 19.5 read 0.01 rot 4.34 : [24.86 | 0.56 | 24.06] + 13.93 38.84 0.04 BOTH OFF : h 0.00 v 14.29
main:thrm:img (1.00 : 0.02 : 0.96) scale 2 fps 19.5 read 0.01 rot 4.11 : [25.53 | 0.62 | 24.62] + 13.48 39.04 0.04 BOTH OFF : h 0.00 v 15.23


Online

Startup timings: s 2.021, var 0.571, suo 0.410, pa 371.017, pkb 0.712, nw 1546.901, run 0.744, total 1922.376

1x Double, Dragging both rulers around with status hud disabled
main:thrm:img (1.00 : 0.24 : 0.75) scale 1 fps 11.4 read 3.78 rot 5.71 : [89.79 | 21.90 | 67.53] + 7.65 97.51 0.07 BOTH OFF : h 0.01 v 19.61
main:thrm:img (1.00 : 0.25 : 0.75) scale 1 fps 11.5 read 1.85 rot 4.48 : [73.41 | 18.06 | 55.16] + 6.62 80.08 0.05 BOTH OFF : h 0.00 v 14.73
main:thrm:img (1.00 : 0.24 : 0.75) scale 1 fps 11.5 read 1.88 rot 4.59 : [73.41 | 17.93 | 55.28] + 6.57 80.04 0.05 BOTH OFF : h 0.00 v 14.73
main:thrm:img (1.00 : 0.24 : 0.75) scale 1 fps 11.6 read 1.88 rot 4.58 : [73.44 | 17.89 | 55.36] + 6.68 80.18 0.06 BOTH OFF : h 0.00 v 14.75
main:thrm:img (1.00 : 0.24 : 0.75) scale 1 fps 11.5 read 1.90 rot 5.01 : [72.89 | 17.75 | 54.91] + 6.50 79.45 0.05 BOTH OFF : h 0.00 v 14.45
main:thrm:img (1.00 : 0.25 : 0.75) scale 1 fps 11.5 read 1.93 rot 4.64 : [72.91 | 17.97 | 54.70] + 6.55 79.51 0.05 BOTH OFF : h 0.00 v 14.33
main:thrm:img (1.00 : 0.24 : 0.75) scale 1 fps 11.5 read 1.85 rot 4.88 : [73.26 | 17.86 | 55.18] + 6.55 79.87 0.06 BOTH OFF : h 0.00 v 14.51

2x Dragging both rulers around with status hud disabled
main:thrm:img (1.00 : 0.14 : 0.86) scale 2 fps 5.5 read 2.88 rot 7.42 : [205.74 | 28.23 | 177.11] + 16.12 221.97 0.11 BOTH OFF : h 0.00 v 22.07
main:thrm:img (1.00 : 0.11 : 0.88) scale 2 fps 5.5 read 1.92 rot 4.12 : [158.58 | 17.98 | 140.32] + 12.46 171.09 0.05 BOTH OFF : h 0.00 v 10.00

1x Dragging both rulers around with status hud disabled - stuttering / inconsistent movement but still better while dragging quickly compared to the 'fast drag' option
main:thrm:img (1.00 : 0.26 : 0.73) scale 1 fps 15.9 read 2.47 rot 5.83 : [71.48 | 18.81 | 52.36] + 4.66 76.23 0.08 BOTH OFF : h 0.00 v 15.67
main:thrm:img (1.00 : -0.00 : 1.00) scale 1 fps 15.9 read 1.98 rot 4.61 : [-8537.67 | 14.08 | -8551.96] + 3.55 -8534.06 0.06 BOTH OFF : h 0.00 v 10.18
main:thrm:img (1.00 : 0.27 : 0.73) scale 1 fps 15.9 read 1.95 rot 4.50 : [51.72 | 14.01 | 37.51] + 3.52 55.30 0.05 BOTH OFF : h 0.00 v 9.98
main:thrm:img (1.00 : 0.27 : 0.73) scale 1 fps 15.9 read 1.93 rot 4.50 : [52.04 | 14.00 | 37.84] + 3.52 55.61 0.05 BOTH OFF : h 0.00 v 10.28

DEFAULT_FLAGS='-DNO_DRAG=0 -DFAST_DRAG=1 -DDRAW_SINGLE_THREAD=1 -DDEFAULT_FONT=0 -DDEFAULT_COLORMAP=4 -DROTATION=0 -DDISPLAY_WIDTH=1920 -DDISPLAY_HEIGHT=1080 -DUSE_CELSIUS=1 -DHUD_ALPHA=0.4'
Code: [Select]
Offline
Startup timings: s 15.927, var 0.636, suo 7.181, pa 1.102, pkb 16.664, nw 1488.083, run 0.527, total 1530.120
1x Double, Dragging both rulers around with status hud disabled
main:thrm:img (1.00 : 0.11 : 0.88) scale 1 fps 22.3 read 0.05 rot 10.91 : [114.21 | 12.28 | 100.99] + 45.92 160.23 0.10 BOTH OFF : h 0.00 v 61.77
main:thrm:img (1.00 : 0.21 : 0.78) scale 1 fps 22.7 read 0.01 rot 4.28 : [23.33 | 4.87 | 18.23] + 6.16 29.52 0.03 BOTH OFF : h 0.00 v 12.67
main:thrm:img (1.00 : 0.21 : 0.78) scale 1 fps 23.0 read 0.01 rot 4.38 : [22.82 | 4.72 | 17.87] + 6.13 28.99 0.04 BOTH OFF : h 0.00 v 12.40
main:thrm:img (1.00 : 0.21 : 0.78) scale 1 fps 23.1 read 0.01 rot 4.30 : [22.72 | 4.74 | 17.79] + 6.12 28.88 0.04 BOTH OFF : h 0.00 v 12.30
main:thrm:img (1.00 : 0.21 : 0.78) scale 1 fps 23.2 read 0.01 rot 4.50 : [23.08 | 4.85 | 18.04] + 6.16 29.28 0.04 BOTH OFF : h 0.00 v 12.39
main:thrm:img (1.00 : 0.21 : 0.78) scale 1 fps 23.3 read 0.01 rot 4.61 : [23.00 | 4.92 | 17.91] + 6.08 29.12 0.04 BOTH OFF : h 0.00 v 12.14
main:thrm:img (1.00 : 0.21 : 0.78) scale 1 fps 23.3 read 0.01 rot 4.49 : [22.90 | 4.91 | 17.81] + 6.14 29.07 0.04 BOTH OFF : h 0.00 v 12.18
main:thrm:img (1.00 : 0.21 : 0.78) scale 1 fps 23.3 read 0.01 rot 4.59 : [23.00 | 4.95 | 17.87] + 6.18 29.22 0.04 BOTH OFF : h 0.00 v 12.15

2x Dragging both rulers around with status hud disabled
main:thrm:img (1.00 : 0.02 : 0.97) scale 2 fps 18.4 read 0.00 rot 4.13 : [23.61 | 0.51 | 22.81] + 14.04 37.68 0.04 BOTH OFF : h 0.00 v 13.53
main:thrm:img (1.00 : 0.02 : 0.97) scale 2 fps 18.6 read 0.01 rot 4.12 : [24.42 | 0.55 | 23.60] + 13.90 38.36 0.04 BOTH OFF : h 0.00 v 14.36
main:thrm:img (1.00 : 0.02 : 0.97) scale 2 fps 18.8 read 0.00 rot 4.29 : [23.65 | 0.51 | 22.88] + 14.06 37.75 0.04 BOTH OFF : h 0.00 v 13.26
main:thrm:img (1.00 : 0.02 : 0.97) scale 2 fps 18.9 read 0.00 rot 4.09 : [23.79 | 0.53 | 23.03] + 14.13 37.96 0.04 BOTH OFF : h 0.00 v 13.85
main:thrm:img (1.00 : 0.02 : 0.97) scale 2 fps 19.0 read 0.01 rot 4.12 : [23.58 | 0.51 | 22.83] + 14.06 37.69 0.05 BOTH OFF : h 0.00 v 13.15
main:thrm:img (1.00 : 0.02 : 0.97) scale 2 fps 19.1 read 0.01 rot 4.09 : [23.62 | 0.52 | 22.83] + 13.88 37.55 0.04 BOTH OFF : h 0.00 v 13.22
main:thrm:img (1.00 : 0.02 : 0.97) scale 2 fps 19.2 read 0.01 rot 4.10 : [23.92 | 0.51 | 23.18] + 14.25 38.21 0.04 BOTH OFF : h 0.00 v 13.61
main:thrm:img (1.00 : 0.02 : 0.97) scale 2 fps 19.2 read 0.01 rot 4.06 : [23.71 | 0.51 | 22.96] + 14.06 37.81 0.04 BOTH OFF : h 0.00 v 13.42
main:thrm:img (1.00 : 0.02 : 0.97) scale 2 fps 19.2 read 0.00 rot 4.01 : [23.31 | 0.56 | 22.53] + 14.45 37.80 0.04 BOTH OFF : h 0.00 v 13.17


Online

Startup timings: s 1.900, var 0.684, suo 0.390, pa 264.882, pkb 8.979, nw 1513.572, run 0.649, total 1791.056

1x Double, Dragging both rulers around with status hud disabled - poor experience. recommend 'no drag'
main:thrm:img (1.00 : 0.23 : 0.76) scale 1 fps 11.3 read 3.49 rot 5.57 : [90.55 | 21.11 | 69.03] + 7.74 98.35 0.06 BOTH OFF : h 0.00 v 17.15
main:thrm:img (1.00 : 0.24 : 0.75) scale 1 fps 11.4 read 1.73 rot 4.45 : [74.61 | 18.08 | 56.31] + 6.58 81.24 0.06 BOTH OFF : h 0.00 v 11.96
main:thrm:img (1.00 : 0.23 : 0.76) scale 1 fps 11.3 read 1.75 rot 4.75 : [75.64 | 17.71 | 57.71] + 6.57 82.25 0.05 BOTH OFF : h 0.00 v 13.34

1x Dragging both rulers around with status hud disabled - stuttering while dragging slowely, freezes while dragging quickly
main:thrm:img (1.00 : 0.24 : 0.76) scale 1 fps 15.9 read 2.90 rot 8.41 : [111.15 | 26.17 | 84.57] + 8.02 119.25 0.09 BOTH OFF : h 0.00 v 26.77
main:thrm:img (1.00 : 0.27 : 0.73) scale 1 fps 16.0 read 1.80 rot 4.58 : [51.16 | 13.67 | 37.30] + 3.57 54.77 0.05 BOTH OFF : h 0.00 v 9.70
main:thrm:img (1.00 : 0.27 : 0.73) scale 1 fps 16.0 read 1.85 rot 4.40 : [51.59 | 13.78 | 37.57] + 3.49 55.13 0.05 BOTH OFF : h 0.00 v 10.02
main:thrm:img (1.00 : 0.27 : 0.73) scale 1 fps 16.0 read 1.82 rot 4.52 : [50.89 | 13.79 | 36.90] + 3.50 54.44 0.06 BOTH OFF : h 0.00 v 9.41
 

Offline Amish Technician

  • Contributor
  • Posts: 30
  • Country: gb
Arrow keys aren't doing anything for me, I tried with two different keyboard, both were laptop style without a num-pad however. I will try again with a full size keyboard.

": Keypad Up/Down/Left/Right/Center(5) moves rulers"

With a RPi it's not working on a full size keyboard for me either. It IS working on my PC however using the same full size keyboard with the num-pad arrows while num-lock is off.

Is anyone else able to reproduce this issue? I'd be interested to know which layout your keyboard uses, and what device you're running redux on.

On a related note I discovered the 'insert' key performs the same function as the 'c' key, decreases the scale. I haven't found another key that increases scale other than 'd'


To compile redux for my PC I first tried just changing the 'march' CFlag like so: '-mavx2 -msse4.2 -msse4.1 -malign-double -march=native' which compiled without errors but fails to run with "Illegal instruction (core dumped)". I'm using a Ivy Bridge CPU which should support these flags according to this page: https://gcc.gnu.org/onlinedocs/gcc/x86-Options.html
I then used these flags and it's working perfectly: CFLAGS='-march=native -mtune=native -pipe -fomit-frame-pointer'
 

Offline 5U4GB

  • Frequent Contributor
  • **
  • Posts: 391
  • Country: au
Feedback on the latest snapshot, on an ODroid at least it definitely needs to run as root because most of /dev isn't user-accessible:

Code: [Select]
> ll /dev/video0
crw-rw---- 1 root video 81, 11 Jan 18 03:35 /dev/video0

> ./redux -d 0 -snapshot
openCamera(4065): Opening cameara /dev/video0
Error opening video stream(/dev/video0)
Failed to open /dev/video0: Permission denied

> sudo ./redux -d 0 -snapshot
openCamera(4065): Opening cameara /dev/video0
openCamera(4094): Opened camera /dev/video0
Backend: V4L2

However it's still trying to interact with the X11 system when -snapshot is specified:

Code: [Select]
MoTTY X11 proxy: No authorisation provided
terminate called after throwing an instance of 'cv::Exception'
  what():  OpenCV(4.5.4) ./modules/highgui/src/window_gtk.cpp:635: error: (-2:Unspecified error) Can't initialize GTK backend in function 'cvInitSystem'
 
The following users thanked this post: Amish Technician

Offline tankslapper

  • Newbie
  • Posts: 8
  • Country: gb
Feedback on the latest snapshot, on an ODroid at least it definitely needs to run as root because most of /dev isn't user-accessible:

Add your user to the group "video", and you shouldn't need to run it as root.

Do the command:

sudo usermod -a -G video yourusername

and you should have access.
 
The following users thanked this post: G28

Offline G28Topic starter

  • Regular Contributor
  • *
  • Posts: 74
  • Country: us
    • Thermal Camera Redux
Feedback on the latest snapshot, on an ODroid at least it definitely needs to run as root because most of /dev isn't user-accessible:

...

However it's still trying to interact with the X11 system when -snapshot is specified:

Code: [Select]
MoTTY X11 proxy: No authorisation provided
terminate called after throwing an instance of 'cv::Exception'
  what():  OpenCV(4.5.4) ./modules/highgui/src/window_gtk.cpp:635: error: (-2:Unspecified error) Can't initialize GTK backend in function 'cvInitSystem'

The back end is required for the video capture to open the camera.  The code is using CAP_V4L. 

X11 needs to be running to do X11 forwarding.

I could move the [-snapshot [prefix]] before the imshow() and exit, but that is well after the camera is initialized.


Here is the OpenCV architecture.  To access the thermal camera, you need to go through a backend.  The selected backend must be available on your platform AND must be able to pass the raw data.

If you choose CAP_OPENCV_MJPEG, it returns Motion JPEG which is a lossy format.  Lossy formats scath the thermal frame data, rendering it useless for this purpose.   CAP_FFMPEG would have pass the raw data unscathed.   CAP_V4L supports the raw format.
« Last Edit: January 18, 2024, 03:52:17 am by G28 »
 

Offline 5U4GB

  • Frequent Contributor
  • **
  • Posts: 391
  • Country: au
The back end is required for the video capture to open the camera.  The code is using CAP_V4L. 

Unfortunately the call it fails in returns essentially useless diagnostics, ./modules/highgui/src/window_gtk.cpp calls gtk_gl_init() which just exits with no useful information ("This function will terminate your program if it was unable to initialize the library for some reason"), a Google search just reveals lots of other people with the same problem and no answers.  I can start an xterm so who knows what it could be...

Does it need a particular OpenCV release?  The current version is 4.9.0 but the one that apt-get installs is 4.5.4, I initially tried building 4.9.0 from source but it seems to require a specific build environment that doesn't match what's on the ODroid device.
 

Offline G28Topic starter

  • Regular Contributor
  • *
  • Posts: 74
  • Country: us
    • Thermal Camera Redux
The back end is required for the video capture to open the camera.  The code is using CAP_V4L. 

...

Does it need a particular OpenCV release?  The current version is 4.9.0 but the one that apt-get installs is 4.5.4, I initially tried building 4.9.0 from source but it seems to require a specific build environment that doesn't match what's on the ODroid device.

I am using 4.5.1, so you are using a newer version than what I have tried.

What does the following return ?

v4l2-ctl --list-devices --all
 

Offline G28Topic starter

  • Regular Contributor
  • *
  • Posts: 74
  • Country: us
    • Thermal Camera Redux
The back end is required for the video capture to open the camera.  The code is using CAP_V4L. 

Unfortunately the call it fails in returns essentially useless diagnostics, ./modules/highgui/src/window_gtk.cpp calls gtk_gl_init() which just exits with no useful information ("This function will terminate your program if it was unable to initialize the library for some reason"), a Google search just reveals lots of other people with the same problem and no answers.  I can start an xterm so who knows what it could be...

Does it need a particular OpenCV release?  The current version is 4.9.0 but the one that apt-get installs is 4.5.4, I initially tried building 4.9.0 from source but it seems to require a specific build environment that doesn't match what's on the ODroid device.

Found this:

https://github.com/opencv/opencv/issues/18461

Code: [Select]
I managed to solve it by making sure when I ssh into aarch64 that I use ssh -Y user@host.
This gives authorization to allow cv2.imshow() to display the window.
gtk_init_check error solved
hope that helps

Another post:

To help others, I found that my .bashrc needed to contain the following:
export DISPLAY=:0.0
previously, it said
export DISPLAY=localhost:0.0
« Last Edit: January 18, 2024, 04:25:05 am by G28 »
 

Offline G28Topic starter

  • Regular Contributor
  • *
  • Posts: 74
  • Country: us
    • Thermal Camera Redux
Version 0.9.1 changes pushed to Github
« Reply #84 on: January 18, 2024, 06:50:42 pm »
2024-01-18: Version 0.9.1 modifications have been pushed to github for weak and single threaded/single core hardware.

BIG THANKS to Amish Technician for all of his RPi model variant testing and regressions.  :-+

The release also contains some minor optimizations for regular multi-threaded hardware as well as some recent requests made by others. 

Thanks to all who have provided feedback.

https://github.com/92es/Thermal-Camera-Redux
 
The following users thanked this post: Fraser, Amish Technician

Offline 5U4GB

  • Frequent Contributor
  • **
  • Posts: 391
  • Country: au
What does the following return ?

v4l2-ctl --list-devices --all

See my earlier post, it's fine with that:
Code: [Select]
USB Camera (usb-xhci-hcd.0.auto-1.1):
        /dev/video0
        /dev/media0

Driver Info:
        Driver name      : uvcvideo
        Card type        : USB Camera
        Bus info         : usb-xhci-hcd.0.auto-1.1
        Driver version   : 4.9.255
        Capabilities     : 0x84200001
                Video Capture
                Streaming
                Extended Pix Format
                Device Capabilities
        Device Caps      : 0x04200001
                Video Capture
                Streaming
                Extended Pix Format

(About two more screens of output snipped)
 

Offline G28Topic starter

  • Regular Contributor
  • *
  • Posts: 74
  • Country: us
    • Thermal Camera Redux
Sorry about that.  I wanted to make sure it saw V4L and the proper color format.

Code: [Select]
Entity Info:
        ID               : 0x00000001 (1)
        Name             : USB Camera
        Function         : V4L2 I/O
        Pad 0x01000004   : Sink
          Link 0x0200000d: from remote pad 0x1000007 of entity 'Extension 4' (Unknown V4L2 Sub-Device): Data, Enabled, Immutable
Priority: 2
Video input : 0 (Camera 1: ok)
Format Video Capture:
        Width/Height      : 256/192
        Pixel Format      : 'YUYV' (YUYV 4:2:2)
        Field             : None
        Bytes per Line    : 512
        Size Image        : 98304
        Colorspace        : sRGB
        Transfer Function : Default (maps to sRGB)
        YCbCr/HSV Encoding: Default (maps to ITU-R 601)
        Quantization      : Default (maps to Limited Range)
        Flags             :
 

Offline Amish Technician

  • Contributor
  • Posts: 30
  • Country: gb
I've just made a bit of a breakthrough with the 'CPU challenged' Pi zero v1.3

I'm able to achieve a consistent and very responsive 24.9fps live image at 1x scale with both rulers by setting the colour map to 'none'.  I only get ~15 with the default colour map.
« Last Edit: January 20, 2024, 01:10:33 pm by Amish Technician »
 
The following users thanked this post: G28

Offline G28Topic starter

  • Regular Contributor
  • *
  • Posts: 74
  • Country: us
    • Thermal Camera Redux
I've just made a bit of a breakthrough with the 'CPU challenged' Pi zero v1.3

I'm able to achieve a consistent and very responsive 24.9fps live image at 1x scale with both rulers by setting the colour map to 'none'.  I only get ~15 with the default colour map.

Applying a colormap is a single API call into the OpenCV library / frame which appears to be expensive on the Pi Zero v1.3. 

Applying an inverse colormap makes 2 API calls into the OpenCV library.  Could possibly pre-generate inverse maps on startup so when they are applied at runtime, they only make 1 call / frame.
« Last Edit: January 20, 2024, 03:23:15 pm by G28 »
 
The following users thanked this post: Amish Technician

Offline Amish Technician

  • Contributor
  • Posts: 30
  • Country: gb
Applying an inverse colormap makes 2 API calls into the OpenCV library.  Could possibly pre-generate inverse maps on startup so when they are applied at runtime, they only make 1 call / frame.

This probably explains how I'm seeing different FPS with different colourmaps (RPi zero):
'Jet'       18.6fps with overlays disabled, 15.4fps with default overlays.
'Bone'   23.5fps with overlays disabled, 18.7fps with default overlays.
'Winter' 24.7fps with overlays disabled, 20.0fps with default overlays.
'None'   25.0fps with overlays disabled, 24.9fps with default overlays.
 

Offline G28Topic starter

  • Regular Contributor
  • *
  • Posts: 74
  • Country: us
    • Thermal Camera Redux
Applying an inverse colormap makes 2 API calls into the OpenCV library.  Could possibly pre-generate inverse maps on startup so when they are applied at runtime, they only make 1 call / frame.

This probably explains how I'm seeing different FPS with different colourmaps (RPi zero):
'Jet'       18.6fps with overlays disabled, 15.4fps with default overlays.
'Bone'   23.5fps with overlays disabled, 18.7fps with default overlays.
'Winter' 24.7fps with overlays disabled, 20.0fps with default overlays.
'None'   25.0fps with overlays disabled, 24.9fps with default overlays.

Jet and Bone should take the same time. 

"Inv Jet" should take longer (as well as any of the other "Inv XXX" and "Cold" because they make 2 OpenCV calls per frame vs 1.

Changing the interpolation method will also change the amount of CPU cycles used. 

Cubic is the slowest, but also the best image quality.  Try Nearest or Linear to see if it makes any detectable speed difference.
 

Offline Amish Technician

  • Contributor
  • Posts: 30
  • Country: gb
RPi zero 1x online

Cubic
'Jet'       18.6fps with overlays disabled, 15.4fps with default overlays.
'Jet Inv' 18.0fps with overlays disabled, 15.4fps with default overlays.

Linear
'Jet'       19.0fps with overlays disabled, 16.2fps with default overlays.
'Jet Inv' 18.0fps with overlays disabled, 15.2fps with default overlays.

Nearest
'Jet'       18.8fps with overlays disabled, 16.3fps with default overlays.
'Jet Inv' 17.6fps with overlays disabled, 15.2fps with default overlays.
« Last Edit: January 20, 2024, 09:58:55 pm by Amish Technician »
 
The following users thanked this post: ZigmundRat

Offline G28Topic starter

  • Regular Contributor
  • *
  • Posts: 74
  • Country: us
    • Thermal Camera Redux
Looks like 1 FPS can be had on INV maps by pre-generating them at startup.
 

Offline Amish Technician

  • Contributor
  • Posts: 30
  • Country: gb
For anyone having difficulty getting Thermal Camera Redux working you first need to install the 'libopencv-dev' package. Enter the following in a terminal on Raspberry Pi OS (or Debian derived distro on any other device or PC):

Code: [Select]
sudo apt update && sudo apt install libopencv-dev
Open the 'build_redux' file in the 'src' source directory with a text editor and configure the options for your device, or just replace the contents of this file with my one size fits all 'build_redux' script which should work on PC, all raspberry pi's, and likely most other similar SBCs:

Code: [Select]
#!/bin/bash

# Build Thermal Camera Redux

echo "Building redux and test_driver ..."

rm ./redux

# Change build flags based on your hardware
CFLAGS='-march=native -mtune=native -pipe -fomit-frame-pointer'

# Setup default startup configuration options

# ROTATION options:         0, 90, 180, 270
# USE_CELSIUS options:      0, 1
# DEFAULT_COLORMAP options: 0 - 36
# USE_ASSERT:               0, 1
# HUD_ALPHA:                0.0 = Full Transparent, 1.0 Full Opaque, Default 0.4

#  VGA -  800 x  480 is a max 2X scale
#        1280 x  720 is a max 3X scale
#        1920 x 1080 is a max 5X scale
#        2560 x 1440 is a max 7X scale

# 2560 x 1600 is a max 8X scale
DEFAULT_FLAGS='-DNO_TS=0 -DNO_DRAG=0 -DFAST_DRAG=0 -DDRAW_SINGLE_THREAD=0 -DDEFAULT_FONT=0 -DDEFAULT_COLORMAP=4 -DROTATION=0 -DDISPLAY_WIDTH=1920 -DDISPLAY_HEIGHT=1080 -DUSE_CELSIUS=1 -DHUD_ALPHA=0.4'
#DEFAULT_FLAGS='-DDEFAI:T_FONT=0 -DDEFAULT_COLORMAP=4 -DROTATION=0 -DDISPLAY_WIDTH=1024 -DDISPLAY_HEIGHT=768 -DUSE_CELSIUS=0 -DHUD_ALPHA=0.4'
#DEFAULT_FLAGS='-DDEFAI:T_FONT=0 -DDEFAULT_COLORMAP=4 -DROTATION=0 -DDISPLAY_WIDTH=320 -DDISPLAY_HEIGHT=240 -DUSE_CELSIUS=0 -DHUD_ALPHA=0.4'
#DEFAULT_FLAGS='-DDEFAI:T_FONT=0 -DDEFAULT_COLORMAP=4 -DROTATION=0 -DDISPLAY_WIDTH=1280 -DDISPLAY_HEIGHT=1024 -DUSE_CELSIUS=0 -DHUD_ALPHA=0.4'

# Compile and link Redux Thermal Camera code
g++ -Wall -Wextra -O3 -ffast-math ${DEFAULT_FLAGS} ${CFLAGS} -DUSE_ASSERT=0 -I/usr/include/opencv4 tc001.cpp thread.cpp -o redux -lpthread `pkg-config --cflags --libs opencv4`


# Debug for gprof, valgrind and perf
#g++ -Wall -Wextra -ffast-math -pg -ggdb3 ${DEFAULT_FLAGS} ${CFLAGS} -DUSE_ASSERT=0 -I/usr/include/opencv4 tc001.cpp thread.cpp -o redux -lpthread `pkg-config --cflags --libs opencv4`

gcc -Wall test_driver.c -o test_driver

Change these default flags to =1 for improved performance on Pi Zero 1 (W), Pi 1, computer module 1, or any other SBC with a single threaded CPU:
-DNO_TS=1
-DDRAW_SINGLE_THREAD=1


Then from the directory with the source files run the build script:

Code: [Select]
sudo ./build_redux

If it builds successfully you should now have a new binary file called 'redux' in the same directory. Connect your camera and run redux:
Code: [Select]
./redux -d 0If this fails check file permission and ensure 'redux' is executable. Your camera might not be 'device 0' in which case specify the appropriate number for yours instead:
Code: [Select]
./redux -d 1
A limitation to keep in mind with my script is that the resulting binary may not work if you take it to a different device from the one you build it on, if you build it on a PC and copy it to a raspberry pi, or even between some pi models. The flags in this script haven't resulted in a degradation in performance compared to the flags I had manually specified for each RPi before, that said there are flags I haven't tried yet. I'll update here if I discover any improvements (or if someone more knowledgeable has a suggestion that works better).

Hope this is helpful, feel free to ask if any clarification is required or if you run in to any problems.
 
The following users thanked this post: ZigmundRat, G28

Offline G28Topic starter

  • Regular Contributor
  • *
  • Posts: 74
  • Country: us
    • Thermal Camera Redux
Amish Tech, did you need any additional commands to install the V4L packages or did the OpenCV install pull those in as well ?
 

Offline Amish Technician

  • Contributor
  • Posts: 30
  • Country: gb
From a fresh install of Pi OS 'libopencv-dev' was the only package I installed.
 
The following users thanked this post: ZigmundRat, G28

Offline G28Topic starter

  • Regular Contributor
  • *
  • Posts: 74
  • Country: us
    • Thermal Camera Redux
Upcoming New Feature - Locked Auto Ranging
« Reply #96 on: January 22, 2024, 10:02:50 pm »
Many have expressed the desire for the various thermal camera apps to be able to lock the camera's auto-ranging so when the camera is panned, the colormap would not jump around making it hard to compare relative color coded temperatures.

Originally, I tried to implement this feature, but was only to get it to half work.  After learning more about the camera and the APIs, I believe I will have this feature available soon with a few twists.

So far, it will have 2 controls.  One control will determine if the locking method uses a static pass band or an adaptive pass band filter.

The static pass band filter will clip temps outside of the original pass band set by the original lock as requested by a TC001 user.

The dynamic pass band grows as the camera encounters outliers, never clips and never shrinks back until reset.

The other control will cycle through various linear/weighted temp to colormap conversion algorithms.  Some colormaps favor one algorithm over another depending on the data one is interested in.  It appears the camera uses a weighted algorithm internally so I will try and provide that emulation as well.

I will probably release a beta version to receive feedback and adjust the code accordingly.


 
The following users thanked this post: ZigmundRat, Amish Technician

Offline G28Topic starter

  • Regular Contributor
  • *
  • Posts: 74
  • Country: us
    • Thermal Camera Redux
Re: Upcoming New Feature - Locked Auto Ranging
« Reply #97 on: January 24, 2024, 06:38:06 am »
Many have expressed the desire for the various thermal camera apps to be able to lock the camera's auto-ranging so when the camera is panned, the colormap would not jump around making it hard to compare relative color coded temperatures.

Originally, I tried to implement this feature, but was only to get it to half work.  After learning more about the camera and the APIs, I believe I will have this feature available soon with a few twists.

So far, it will have 2 controls.  One control will determine if the locking method uses a static pass band or an adaptive pass band filter.

The static pass band filter will clip temps outside of the original pass band set by the original lock as requested by a TC001 user.

The dynamic pass band grows as the camera encounters outliers, never clips and never shrinks back until reset.

The other control will cycle through various linear/weighted temp to colormap conversion algorithms.  Some colormaps favor one algorithm over another depending on the data one is interested in.  It appears the camera uses a weighted algorithm internally so I will try and provide that emulation as well.

I will probably release a beta version to receive feedback and adjust the code accordingly.

Some more previews:

The left window has Auto Ranging Locked while the right window has Auto Ranging Unlocked.  Both windows look the same until panned off the hot spots.

 

The left image retains it's locked colormap in contrast to the camera's auto ranging in the right window making it hard to compare colorized temps around the room.

While the auto-ranging is locked, any of the mapping filters can be changed along with any of the other configurations including changing colormaps, portrait/landscale, scale, fonts, etc.






 
The following users thanked this post: ZigmundRat, Amish Technician

Offline Amish Technician

  • Contributor
  • Posts: 30
  • Country: gb
Thermal Camera Redux running at 2x scale on a RPi Zero 2 W with 800x480 60Hz touchscreen (With TC001 for scale):

2x scale


2x scale full screen


Mock-up of possible overlay layout to make better use of available screen space


This is the mock-up being displayed above. I doubled the width of the gradient scale to 16 pixels, I think it might be slightly too wide now  ::)


I have all the different elements on separate layers in GIMP so I can experiment with it. I'm happy to mock-up any layout suggestions.
« Last Edit: January 25, 2024, 01:52:57 pm by Amish Technician »
 
The following users thanked this post: ZigmundRat, G28

Offline Amish Technician

  • Contributor
  • Posts: 30
  • Country: gb
Another mock-up, 3x scale with no display size limitation.

« Last Edit: January 25, 2024, 01:59:12 pm by Amish Technician »
 
The following users thanked this post: G28

Offline G28Topic starter

  • Regular Contributor
  • *
  • Posts: 74
  • Country: us
    • Thermal Camera Redux
Github Version 0.9.2 changes pushed - Locked Auto Ranging
« Reply #100 on: January 26, 2024, 06:03:18 am »
UPDATE:

2024-01-25: Version 0.9.2 modifications have been pushed to github to optionally lock out camera's colormap auto-ranging.
2024-01-18: Version 0.9.1 modifications have been pushed to github for weak and single threaded/single core hardware.

https://github.com/92es/Thermal-Camera-Redux

The ability to lock the camera's colormap auto ranging has been pushed to the github repository.

The user can optionally enable / disable auto ranging.
The user can optionally cycle through temperature pixel to color pixel mapping methods.
These mapping methods are a WIP and may change over time with user feedback.

The 'l' key cycles between unlocked, static band pass and dynamic band pass.
Static band pass will clip temps outside of the band pass range established at the time the lock was set.
Dynamic band pass will dynamically grow, but not shrink from the time the lock was set.

The 'i' and 'k' keys will allow the user to cycle through mapping options.  No mapping is also included in the cycle so one can view the default images as displayed in the first row below.

The left or top window ( normally the image window ) will display the range locked view while the right or bottom ( normally thermal window ) will display the live auto-ranging for side-by-side real time comparison. 

The user can optionally display any of the single and double window layouts as before as well as change colormaps or any other configuration option.

Note 1:   Colormap / Mapping permutations vary in utility.

Note 2:   This feature utilizes more CPU cycles and will be optimized over time.  Plan accordingly for entry level SBCs.

In offline mode, the right/bottom window will display the same mapping methods when locking is enabled for offline use of these maps.

Here are some example permutations:

Image and Thermal windows with Auto Ranging Disabled ( or map option 0 ):



Locked and Unlocked windows with the left window using mapping option 1



Locked and Unlocked windows with the left window using mapping option 5



Please post any feedback you may have.  It will be greatly appreciated.
« Last Edit: January 26, 2024, 06:47:48 am by G28 »
 
The following users thanked this post: RO, Amish Technician

Offline Amish Technician

  • Contributor
  • Posts: 30
  • Country: gb
OpenCV copyMakeBorder demo attached.
 

Offline G28Topic starter

  • Regular Contributor
  • *
  • Posts: 74
  • Country: us
    • Thermal Camera Redux
OpenCV copyMakeBorder demo attached.

Here is an initial cut.

It scales dynamically based on font/text widths.

This will probably be a compile flag to switch between borders and no borders.


Key map overlap:

« Last Edit: January 27, 2024, 07:53:16 am by G28 »
 
The following users thanked this post: Amish Technician

Offline Amish Technician

  • Contributor
  • Posts: 30
  • Country: gb
Thank you G28 for implementing my layout suggestions!  :-+ :-+ :-+

« Last Edit: January 28, 2024, 02:15:38 am by Amish Technician »
 
The following users thanked this post: G28

Offline G28Topic starter

  • Regular Contributor
  • *
  • Posts: 74
  • Country: us
    • Thermal Camera Redux
Thanks for testing. 

I am updating the HUD display with the various auto-ranging lock permutations and will push the changes to git hub within a day.
 
The following users thanked this post: Amish Technician

Offline G28Topic starter

  • Regular Contributor
  • *
  • Posts: 74
  • Country: us
    • Thermal Camera Redux
Github push: Optional dynamic boarder layout build.
« Reply #105 on: January 28, 2024, 02:46:24 am »
UPDATE:

2024-01-27: Version 0.9.3 modifications have been pushed to github to optionally build with dynamic border layout.
2024-01-25: Version 0.9.2 modifications have been pushed to github to optionally lock out camera's colormap auto-ranging.
2024-01-18: Version 0.9.1 modifications have been pushed to github for weak and single threaded/single core hardware.

https://github.com/92es/Thermal-Camera-Redux

 
The following users thanked this post: Amish Technician

Offline Amish Technician

  • Contributor
  • Posts: 30
  • Country: gb
Full screen aspect ratio fixed  :-+  Many thanks G28

 
The following users thanked this post: G28

Offline G28Topic starter

  • Regular Contributor
  • *
  • Posts: 74
  • Country: us
    • Thermal Camera Redux
Full screen aspect ratio fixed  :-+  Many thanks G28

(Attachment Link)

Just added the border layout feature description page to github.

https://github.com/92es/Thermal-Camera-Redux/blob/main/doc/BORDER_LAYOUT.md
« Last Edit: January 28, 2024, 11:39:21 pm by G28 »
 
The following users thanked this post: Amish Technician

Offline Amish Technician

  • Contributor
  • Posts: 30
  • Country: gb
I've discovered using the screen configuration utility included with raspberry pi OS to flip the display output can noticeably lower the frame rate. Around 15fps on Pi Zero 2W at 2x scale full screen instead of 25.

Performance appears negligibly affected by the addition of 'borders'.

Clearer fonts  :-+
 

Offline Amish Technician

  • Contributor
  • Posts: 30
  • Country: gb
Edit: Display configured 800x480
But build_redux configured
DISPLAY_WIDTH/HEIGHT 480x800
max scale, full screen.
Rotation:
0, 90,
180, 270

'BeltsAndSuspenders' 1





'BeltsAndSuspenders' 2


« Last Edit: February 01, 2024, 06:13:14 pm by Amish Technician »
 
The following users thanked this post: G28

Offline Amish Technician

  • Contributor
  • Posts: 30
  • Country: gb
Mock-up of 480x800 portrait layout

 

Offline Amish Technician

  • Contributor
  • Posts: 30
  • Country: gb
The attachment 'Rotations.7z' contains full screen resolution captures of all combinations of;

build_redux
Code: [Select]
-DDISPLAY_WIDTH=800 -DDISPLAY_HEIGHT=480 and
Code: [Select]
-DDISPLAY_WIDTH=480 -DDISPLAY_HEIGHT=800
OS (xrandr) rotation 0 and 90,
Camera 0 and 90,
Display 0 and 90.

I've omitted 180 and 270 as they produce the same layout as as 0 and 90, just rotated 180 degrees.

OS (xrandr) rotation not recommended on lower performing devices, frame rate drops to ~15-16fps on pi zero 2w. It's still useful for testing portrait layouts as there are pi displays with native portrait resolutions.


These combinations are currently working well making good use of the available resolution to display the thermal image as large as possible without stretching/distorting it, overlapped minimally by HUD elements:

800x480_OS-0_Cam0_Display0


800x480_OS-90_Cam0_Display90



Edit: a miss labelled Display180 appears to have sneaked in called 800x480_OS-0_Cam90_Display90
« Last Edit: February 06, 2024, 10:28:39 pm by Amish Technician »
 
The following users thanked this post: G28


Share me

Digg  Facebook  SlashDot  Delicious  Technorati  Twitter  Google  Yahoo
Smf