04-03-2015 04:28 AM
Hi everybody,
I`m trying to realize one tracking with LabVIEW Vision, It works not so bad, but sometime I have one problem.
I have to draw the deplacement of my objectand sometimes I have one parasite point, and unforthunately because of that the draw is not good. It happens not often, maybe twice with one video of 2 minutes (20FPS).
It is very important to avoid that.
So as you can see, I should not have this straight line.
Labview send my each coordinate of my object for each frame of the video.... I have two ideas to delete this parasite point, but I don`t know which one is the best and how to do.
1) I could compare the point before and the point after, and if the point between both of them is to different, LabVIEW delete it.
2) I could put one threshold, I mean if the value is more or less than the point before more or less 20 pixel, so this point is delete.....
I would like to know what you`re thinking about that. Maybe there isa simpl solution.
I`m searching but at this moment I found nothing ^^
Thansk a lot
Maxime
04-03-2015 06:44 AM
04-03-2015 08:29 AM
I agree with you that modify the tracking is the best, But to be honest, I work with LabVIEW Vison. I put one picture about that. And I played with the minimum score but impossible to correct everything.
So for me, maybe the first solution is the best.... At the end, LabVIEW Vision, send me a big array with all the coordinate of my Object (X and Y).
So I suppose I could check every point of those coordinates, and when one is too far from the others, it is exluded.
You spook about one fitler, How can I do. If you know to orient me it will be great. I`m just a beginner with LabView so my knowledges are limited ^^
But thanks for your help!!
04-04-2015 12:07 AM
04-07-2015 04:47 AM
Thks for your precision,
I will work on it. And I will come back here if I meet some news troubles.
Maxime
04-07-2015 05:23 AM - edited 04-07-2015 05:23 AM
Do you know how to calculate the distance? You should be getting your position measurements as a series of XY positions. Calculating distance between two adjacent points is simple geometry: sqrt(deltaX^2+deltaY^2).
I wanted to pass this along because I realized that based on your posts I don't know what your background is. You could be an academic researcher and, so know this. Or you could be a high school kid with a really cool class project and so might not.
In either case, no offense is intended.
Mike...
04-07-2015 06:50 AM
I knew it..... No offense of course. I`m still a student, but not in secondary school..... For my second years of Master in Engineering in Biochemistry, I am doing one intership abroad.
But yes effectively, the English is not my mother tongue and I`m a beginner in LabVIEW......
Well for my software, I know exactly what I want to do..... The most difficult part is to find how with LabVIEW.
04-07-2015 07:45 AM - edited 04-07-2015 07:53 AM
Well I found something not to bad in my opinion.
This software resolve this kind of errors (0, NaN or number to far). The software replace the bad number bythe average between the number before and after
1 1
2 2
0 => 3
4 4
or
1 1
2 2
NaN => 3
4 4
or
1 1
2 2
20 => 3
4 4
But I still have one problem, If there is one repetition about the wrong number..... For exemple
1
2
0 or 20 or NaN
0 or 20 or NaN
5
6
With this graphique, I obtain the wrong result.
I could put one loop if, and if the number before is not good take, the number before again.
But it will work only till the number before before.
There is something to resolve this kind of thing?
04-09-2015 06:28 AM
Sorry, I can`t edit my old message..... I don`t why but there is not this option.....
Anyway, I send to you my software a little quick.... There were some errors. I fixed everything except one.
If the last number of the array is 0 or a parasite point, my software will turn around.....
It is logic because in this two case, the software take the point before and the point after to make an average. But like my array is finish after, all the number after are 0.... So It will check after and after but will find all the time 0....
How can I fix that? Any ideas?
I added the good one.
Sorry for the flood, and thanks in advance