-
Notifications
You must be signed in to change notification settings - Fork 138
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Issue during features extraction. #52
Comments
Ok, I found the topic in your FAQ. I'll follow the the Batch pre-process videos in SimBA tutorial. |
Hi @DorianBattivelli - yes it's to do with all body-parts falling on the same X/Y co-ordinates. Happy you found it. There are two types of heatmaps - one that requires features and one that doesn't. The one that does require features plots heatmaps representing the time/location of animals engaging in classified behaviours and is accessed in the visualization tab. The one that doesn't require features plots heatmaps representing the time spend in locations and is accessed in ROI tab: |
@sgoldenlab Thank you for the answer. Indeed I tried this function, but it does not work neither. |
Ah thanks - I'm not sure why - but the heading seems to have moved one row? It now starts at row two, whereas SimBA expects the heading in row 1. Does it work if you move it up? |
Thanks - let me check this again when I get to a computer. Might be that I can replicate it by using the auto argument or playing more with the bin size. |
@DorianBattivelli - would you happen to have any files in your outlier_corrected_movement_location folder which is not represented in your video_info.csv file? |
That's what I meant, it looks like it should! |
As I can't replicate it here, I wonder if you can help me by inserting a line in your code and tell me what's printed out? In this file: Could you insert a new line on Line 41 which would read like this? At least of these guys for some reason is going to be zero in your setup and it would help knowing which one it is |
Don't worry about the try and except you see at the lower part, you don't have it, I just inserted it now to catch the error you are seeing |
I'll try that as soon as I'll be back at mine, and I let you know, thanks. |
@sgoldenlab, I added the line you told me (print(...)), but the line starting by binWidth, etc. was not at line 40 in my document, but at the line 54, so I added the line at line 55. Now that I saved the file like that, I can't launch SimBA anymore, here what appears: |
Ah its common one, it needs to be uniform 4 spaces or uniform tabs, I will send you the file |
just replace the one you have with this |
ah |
That seems very strange, does it come with en error msg in the terminal? Does it persist after restarting SimBA? |
Actually, I don't know what happened, but now it is working, the analysis is on going, thank you! |
good news again! |
Hmm, I don't think so - are the videos all the same resolution? I may have to troubleshoot this tomorrow. |
Yes, they have the same resolution. |
@sgoldenlab, to give you further inputs about my issue. This morning I tried to generate heat map (only the last picture) with another set of videos and I get a strange result. Since I have 2 animals, I first run for "center1", and it generated one picture for all my videos, so I though the problem was solved. But then, when I run for "center2", one picture is missing for my last video. FYI: The resolution of the videos I worked with this morning: I have the feeling that the resolution of my videos is very low, and that can be very problematic. Actually it's because I cropped a subfield of my raw videos, so the remaining portion on which I'm focusing for working ends up with a pretty bad resolution. |
Hi @DorianBattivelli. Yes for your first point, I think what is happening is that one animal, for whatever reason - is placed "outside" the heat-map array and it breaks. For this reason I thought I'd just insert a fix saying if the animal (as in your case) is placed in column 16 (and the array only contains 15 columns) then place the animal in column 15. EDIT: This is because, for example, "Center2" has a coordinate outside the map, but "Center1" does not. For your second, I am not entire sure I understand - could you be more specific? I know the videos are pretty poor resolution (0.3 pixels per milometer) but this should not matter if you have good tracking and can see yourself what is happening in the cropped videos. |
@DorianBattivelli - can you give this file a go? It should catch and correct the IndexErrors you are seeing. |
Thanks it's because your body part is now two columns out of the frame, why I don't know, and I only controlled for one. I don't have a file to troubleshoot with, would you mind sharing a single .csv for me from your outlier_corrected_movdment_location folder? |
Concerning the second point, I meant that certainly the reason why my feature extraction failed is due to the low resolution / the bad quality of my model. I deduced that from what I read on your FAQ concerning the QHull 6013 error that I have when I click "extract features". There, it is said that this error occurs when one or the two animals are missing (and so the tracking is not good enough, DLC failed to identify the body parts I guess). For all these reasons, I deduce that my impossibility to extract the features is due to the low quality of my tracking model. Maybe I'm wrong. |
No problem for sharing my csv file, where can I send it to you privately? |
Can share share through a google drive with snilsson@uw.edu ? Yes zeros are not good for feature extractions. I don't know when this occurs, but if it happens when animals is not present you can deal with it by clipping that part of the video. If the zero detection happens because the experimenter is present, then crop/clip that part of the video. If all the animal are present, the body-parts are present, and the experimenter is not there (and pose-estimation should pick up the body-part location but you still see zero) then you have to improve the model somehow - train it on additional videos and/or frames is a good start. |
Shared. FYI: cEFp3: it works for video _15, for both Center_1 and Center_2, but for the video _60, Center2 fails. |
Thanks! got it, will take a look a little later and get you a fix. |
Thank you! |
One more thing - could you share your video_info.csv also? To make sure I'm working with your settings |
Done |
Hi @DorianBattivelli - I'm sorry I still struggle to re-create this, my heatmaps generate fine for the 60 file using the center of animal 2: What I am thinking is that you sent me the DLC output files, from |
Since I'm working on multi animal project, I converted the h5 DLC files in csv through SimBA, and they are the files I sent to you. |
Hi @DorianBattivelli - can you try it using this script? It should catch any error you have in the alignment between the resolution of your video and bin size, and print a warning, and then plows on |
Hi @sgoldenlab , thank you very much for the big help, that works perfectly well! |
@sgoldenlab , Hello, I'm unfortunately dealing with a new error message.
I have been able to analyze the ROI and to obtain: number of entries, cumulative time, distance and velocity data.
Now I would like to draw heat maps. But I should first extract features right?
When I click Extract Features, it seems that the process stops, and here what happens:
I then click on append ROI data to features, and here what appears:
Have you any idea about the reason why it's not working?
As reminder, I'm working on multi animal project, on windows 7, avi videos, SimBA = 1.2.7. Concerning the outlier correction, I skipped it.
Thank you,
Best,
Dorian
The text was updated successfully, but these errors were encountered: