Closed milesOIST closed 2 years ago
I am going to look into it, it seems to be a more of problem with the final segment than larger buffer sizes. Do you have a short recording, e.g. 300 frames, that can reproduce the behaviour?
Weird, had no problems with 300 frame vid. I then tried again on another computer, just in case, and found the same error with 3000 frames and 24 buffer
Could you tell me what filetype your input file is? A Tiff with bin_size 5 and buffer_size 24 works for me with 3000 frames
This file was 3000 frames of HDF5 format, converted from a larger MDF file using
vid = get_video_file_reader("filename.MDF", 50);
vid = vid.read_frames(10000:13000);
input_file = "outfilename.HDF5");
writer = get_video_file_writer(input_file, 'HDF5');
writer.write_frames(vid);
I have found the bug, it is a problem with boundary handling after binning. Currently, the toolbox needs at least ceil(bin_size / 2) frames for the last binned frame. What behaviour would help you the most or what would you normally do for binning, should we discard the last few frames or average over however many frames are left?
That makes sense. For me, averaging over the last frames would be better as it is easier to align to the behaviour.
From: Philipp Flotho @.> Date: Friday, 13May, 2022 1:00 To: phflot/flow_registration @.> Cc: Miles Desforges @.>, Author @.> Subject: Re: [phflot/flow_registration] Larger buffer size seems to cause issue (Issue #6)
I have found the bug, it is a problem with boundary handling after binning. Currently, the toolbox needs at least ceil(bin_size / 2) frames for the last binned frame. What behaviour would help you the most or what would you normally do for binning, should we discard the last few frames or average over however many frames are left?
— Reply to this email directly, view it on GitHubhttps://github.com/phflot/flow_registration/issues/6#issuecomment-1125168427, or unsubscribehttps://github.com/notifications/unsubscribe-auth/AIHOLZNVOZIWVKLOXY2PBULVJUTJDANCNFSM5VTYB5VA. You are receiving this because you authored the thread.Message ID: @.***>
The bug is fixed with the latest commit, could you let me know if the behaviour is not as expected?
Using larger buffer produces error. I was compensating a 3000 frame video, but used my stanrdard settings for 20000 frame vid. Solved by removing the line
'buffer_size', 24
or reducing buffer_size to 16. Suggestion: If buffer size will cause errors later in the program, catching this at the start, rather than after running for some time, would be better.Error:
Here I was using these options: