Skip to content
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

Empty .mat files #2

Open
qwoprocks opened this issue May 7, 2023 · 7 comments
Open

Empty .mat files #2

qwoprocks opened this issue May 7, 2023 · 7 comments

Comments

@qwoprocks
Copy link

qwoprocks commented May 7, 2023

I tried loading all the .mat files under Video_V into MatLab (was trying to convert them into .csv format for use in Python3). I found that quite a few of the .mat files don't have data, which is illustrated in the following screenshot:
image

I thought it meant that there were no drones in the video, but I checked this specific file and there does seem to be a drone.

This is what a non-empty .mat file gives:
image

The script I'm using to convert to .csv is as follows:

for file = dir(fullfile('Video_V', '**/*.mat'))'
    fullFileName = fullfile(file.folder, file.name);
    [pathstr, name, ext] = fileparts(file.name);
    fileType = split(file.name, '_');
    fileType = fileType(2);
    gt = load(fullFileName);
    try
        gTruth = selectLabels([gt.gTruth], fileType);
        csvFile = fullfile('CSVs', strcat(name, '.csv'));
        writetimetable(gTruth.LabelData, csvFile);
    catch ME
        file.name
    end
end
@DroneDetectionThesis
Copy link
Owner

DroneDetectionThesis commented May 11, 2023 via email

@qwoprocks
Copy link
Author

Thank you for the response! I can't seem to view the image you uploaded, could you post it again?
image

@DroneDetectionThesis
Copy link
Owner

DroneDetectionThesis commented May 13, 2023 via email

@pilot00
Copy link

pilot00 commented May 20, 2023

I met the same problem, did you solve it?

@qwoprocks
Copy link
Author

I met the same problem, did you solve it?

nope, I just skipped over the empty files

@DroneDetectionThesis
Copy link
Owner

DroneDetectionThesis commented May 21, 2023 via email

@pilot00
Copy link

pilot00 commented May 21, 2023

All the .mat files are above 0KB.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants