Comments (11)
I've fixed the error, but you'll face to another problem: the threshold between animal color and background color is very specific for my lab environment, therefore contour of your animal is corrupted.
So I'll try to make the threshold more adaptive, or at most to replace my detecting algorithm by common one, e.g. GOTURN. Thank you for new video provided with different environment, Shahrukh.
from animal-tracking.
As to file extension: you just need to replace all .avi
by .mp4
in the end of track.py
.
from animal-tracking.
water-maze-lesion.zip
The trajectory of animal is not shown by the animal-tracking app and it shows the distance travelled by the animal is very negligible. How to correct the errors? And how to optimise it for circular arena? Can binary threshold images processed by Fiji used if the animal is not as white as snow in the video? I get some errors like encoder error when binary threshold videos are used
from animal-tracking.
How much light intensity in lux is needed during video recording for perfect tracking of the animal?
from animal-tracking.
The trajectory of animal is not shown by the animal-tracking app and it shows the distance travelled by the animal is very negligible. How to correct the errors?
Download v0.1.1 and just fill full right half of UI window by the green quad. Your mistake in water-maze-lesion.zip was the highlighting of only the part of arena. Green quad is needed to get rid of perspective effect that is caused by optical aberrations.
And how to optimise it for circular arena?
What you need to fit units of the distance is normalize it by the length of the average side of red quad you've selected as frame in UI measured in meters:
E.g. if the length between top right and bottom right points of red frame is 2.1 meters then divide the distance by 2.1.
Can binary threshold images processed by Fiji used if the animal is not as white as snow in the video? I get some errors like encoder error when binary threshold videos are used.
That is exactly what cv2.threshold()
does in my code, so you don't need do any preprocessing. Actually, metamarking of your video with orange centroid of an animal and green quadrants of the arena are overly.
How much light intensity in lux is needed during video recording for perfect tracking of the animal?
Everyday working lighting 200–400 lx is enough.
from animal-tracking.
im still have a war with trying to count a speed ,
speed = _x =_y = 0
distance += np.sqrt(((x - _x) / float(h))**2 + ((y - _y) / float(h))**2)
speed=(distance)/abs(time.time())
# speed1=str(speed)
from where i can get Time ?) And also your code with last corrections does not work when im pressing python track.py
it just
shows again this
PS C:\users\dark\dev\animal-tracking-master>
from animal-tracking.
im still have a war with trying to count a speed
Are you sure you have read my answer? The item 3 states: there is a variable t
that stores elapsed time measured in seconds. How do you think the time appears on the left frame? It is possible due to this variable. So, for elapsed time
speed = distance / t
print(speed)
From where i can get Time?)
From the variable t
. I'm not kidding.
And also your code with last corrections does not work when im pressing python track.py
If you don't see red frame on the right side then you have to highlight it manually before you press Enter
. Look at the gif above.
from animal-tracking.
May I know how you avoided the errors caused by water ripples? I am unable to reproduce the same results for the video I used.
from animal-tracking.
The only thing I did is average all frames and subtracted the sum from each current frame. It helped for your example, but not in general. Try to decrease THRESHOLD_ANIMAL_VS_FLOOR
from 70 to 50: it will increase the area of animal and in the same time will make it possible to take the dark ripples for the animal.
We can introduce Kalman filter if you will continue facing the problem.
from animal-tracking.
But what you say is actually the latest commits you did to tracker.py. Did you edit the video to get the results that avoid the errors caused by water ripples. I'm unable to reproduce the same result with the latest release.
from animal-tracking.
No, I did not. I use raw video you have attached. The only differences between our environments are OS and version of python modules, mine are:
- macOS
- opencv-contrib-python==4.0.0.21
- numpy==1.15.4
from animal-tracking.
Related Issues (20)
- ValueError: need more than 2 values to unpack HOT 1
- Open field test for circular arena HOT 1
- Two errors that I came across HOT 3
- The program shows me just half of my field HOT 8
- Calibration HOT 1
- Track.py Code Issue
- Tracking is not working HOT 3
- Taking the right side square of the camera environment HOT 4
- The cropping method HOT 3
- An added GUI with tkinter HOT 9
- I want to remove the normal colored frame HOT 1
- Can you look at my last 2 issues ? HOT 2
- Issue with tkinter gui
- How is the distance calculated ? HOT 3
- Can I change the way the distance is calculated ? HOT 16
- Description of my problem about running long play video file HOT 1
- Issues with the code HOT 1
- Code not running properly HOT 4
- Vidéo split in two HOT 1
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from animal-tracking.