borgesnogueira / ZebTrack

Software de rastreio de animais em matlab
GNU General Public License v2.0
5 stars 2 forks source link

Annotating Calibration Images #6

Open mtxslv opened 4 years ago

mtxslv commented 4 years ago

To get the frames, run this:

frame_inicial = video.FrameRate*tempo_inicial;
frame_final = video.FrameRate*tempo_final; 
new_video = VideoReader([video.Path,'\',video.Name]); % preciso criar um novo VideoReader pra evitar um bug  
frames_video = read(new_video, floor([frame_inicial, frame_final]));                         %cria um vetor com todos os frames entre frame_incial e frame_final.
length_frames_video = (floor(frame_final) - floor(frame_inicial)) + 1;

to print them, do:

imtool(frames_video(:,:,:,8))

(it will print frame 8)

mtxslv commented 4 years ago

How to get Pixel Information?

https://www.mathworks.com/help/images/get-pixel-information-in-image-viewer-app.html

mtxslv commented 4 years ago
frame blue_fish_position red_fish_position blue_fish_rgb red_fish_rgb
1 (356 , 278) (329, 329) [ 23 27 57 ] [ 74 32 41 ]
2 (357 , 278) (328 , 330) [ 23 25 56 ] [ 57 27 28 ]
3 (359 , 279) (327 , 330) [ 29 36 77 ] [ 61 13 27 ]
4 (361 , 278) (326 , 330) [ 25 25 52 ] [ 57 22 27 ]
5 (362 , 279) (324 , 331) [ 28 33 72 ] [ 62 14 28 ]
6 (366 , 279) (322 , 332) [ 23 28 70 ] [ 73 17 29 ]
7 (367 , 278) (320 , 333) [ 18 15 48 ] [ 64 11 29 ]
8 (369 , 280) (319 , 333) [ 28 33 72 ] [ 68 8 26 ]
9 (369 , 279) (318 , 333) [ 20 23 61 ] [ 66 4 18 ]
10 (369 , 279) (317 , 334) [ 15 16 52 ] [ 69 15 27 ]
11 (371 , 279) (314 , 335) [ 16 17 55 ] [ 61 8 24 ]
12 (373 , 279) (313 , 336) [ 20 18 60 ] [ 67 14 27 ]
13 (375 , 279) (312 , 337) [ 17 18 58 ] [ 69 28 40 ]
14 (376 , 279) (313 , 337) [ 15 14 51 ] [ 63 0 14 ]
15 (377 , 278) (310 , 338) [ 17 14 45 ] [ 74 0 17 ]
16 (380 , 277) (303 , 337) [ 18 14 52 ] [ 73 0 14 ]
17 (383 , 277) (300 , 337) [ 23 25 65 ] [ 69 0 15 ]
18 (383 , 276) (297 , 337) [ 18 15 50 ] [ 73 0 19 ]
19 (384 , 276) (293 , 337) [ 17 15 41 ] [ 69 0 15 ]
20 (387 , 275) (290 , 337) [ 21 16 56 ] [ 68 2 13 ]
21 (391 , 274) (279 , 337) [ 19 13 47 ] [ 74 0 13 ]
22 (392 , 273) (273 , 337) [ 16 12 36 ] [ 70 2 11 ]
23 (394 , 273) (270 , 335) [ 17 17 60 ] [ 81 7 16 ]
24 (395 , 272) (266 , 333) [ 18 16 53 ] [ 78 16 21 ]
25 (396 , 271) (260 , 332) [ 22 21 56 ] [ 62 10 9 ]
26 (397 , 270) (254 , 329) [ 19 19 46 ] [ 55 12 10 ]
mtxslv commented 4 years ago

How am I annotating the calibration set? I use imtool(), zoom the image and choose a colorful pixel at both animals. Then I annotate its RGB value and position

mtxslv commented 4 years ago

how to import calibration dataset?

HOME -> IMPORT DATA (choose right .txt file)

COLUMN DELIMITERS: all standard delimiters should remain unchecked. Check suggested delimiter Space|

RANGE: A3:E28