03-08-2021 04:10 AM
Hi.
I have a system for measure the current of a photovoltaic plate, the current of each point is saved in anm array and showed with a gray scale image (you can save the image) now i want to make profiles from this image (array) drawing a line on the array and i dont know hoow to do it. I give you the front planel of the array.
03-08-2021 04:21 AM
Hi diego,
@diego_gonza wrote:
I give you the front planel of the array.
This is like giving a photograph of your car to the garage and ask the mechanic to repair your car…
@diego_gonza wrote:
I have a system for measure the current of a photovoltaic plate, the current of each point is saved in anm array and showed with a gray scale image (you can save the image) now i want to make profiles from this image (array) drawing a line on the array and i dont know hoow to do it.
Use a cursor of the intensity graph to let the use select the row/column of your 2D data.
Then use the cursor position to index the corresponding data from your array and to display a profile plot from these 1D data…
03-08-2021 04:33 AM
I can make profiles of a col and a row, but i dont know how i can do the same for a line that the user draw. Sorry for the image, i send now the back panel of how i do the profiles of rows and cols
03-08-2021 09:10 AM
Now there's a picture of the engine!
03-08-2021 10:43 AM - edited 03-08-2021 10:49 AM
Hi diego,
as RavensFan already said: it's still a photograph of your car, you just opened the engine hood…
And it is an ugly engine! From what I see on that image is an overuse of local variables. Use more wires!
@diego_gonza wrote:
i dont know how i can do the same for a line that the user draw.
A line has two end points: you can determine their indices. And you can determine the indices of all points in between them.
After all it's simple linear algebra, usually taught in school…
(Coming to my mind: Have you ever heard of Bresenham? That's the way we calculated lines the fast way 35 years ago on 8bit computers…)
03-08-2021 10:54 AM
ok sorry, now i think we share the car.
The starter arrays come from the measures, "opciones guardado.vi is just for save the results and the first case is for work without devices.
03-08-2021 11:09 AM - edited 03-08-2021 11:09 AM
Hi Diego,
@diego_gonza wrote:
ok sorry, now i think we share the car.
We are coming closer: Now you gave us the car, but removed important parts of the engine…
All the subVIs are missing!
Is this the expected output of this code snippet?
03-08-2021 11:49 AM
Use mouse-down events to draw a line using "plot images.front".
and extract the line profile using bilinear interpolation.
(here is an old example that uses two cursors and interpolation)
03-09-2021 03:21 PM
@altenbach ha escrito:
Use mouse-down events to draw a line using "plot images.front".
and extract the line profile using bilinear interpolation.
(here is an old example that uses two cursors and interpolation)
I try to use your vi with the interpolation and it doesnt work with other array (i think im doing something wrong), the try is in the interpolation.rar
03-09-2021 03:23 PM
@GerdW ha escrito:
Hi Diego,
@diego_gonza wrote:
ok sorry, now i think we share the car.
We are coming closer: Now you gave us the car, but removed important parts of the engine…
All the subVIs are missing!
Is this the expected output of this code snippet?
I think here is the complete car😬, the array of the image is for generate the 1D array with the numbers of the initial 2D array that we select with the vertical and horizontal lines. The size of the array should be the numbers of pixels (col or row).