ultralytics/xview-yolov3

Fine tune model for using on grayscale images of xview

sawhney-medha opened this issue · 3 comments

I want to fine tune this model on a different dataset that is grayscale. I understand that train.py has a resume option which will start training from previous weights. But train.py also uses target_c60.mat. I cannot understand how to create the .mat files for my own custom data. Please help

@sawhney-medha Hello, thank you for your interest in our work! Please note that this repository is no longer actively maintained. Instead we recommend all users start from github.com/ultralytics/yolov3 and adapt it to their specific needs.

The target_c60.mat file you mentioned can be read by scipy.io, however it was generated by a seperate MATLAB script, which mainly trims poor labels and creates a k-means anchors from the remaining good candidates.

save('targets_c60.mat','wh','targets','id','class_mu','class_sigma','class_cov','image_weights','image_numbers')

In order to adapt github.com/ultralytics/yolov3 to geospatial data similar to xview you mainly need to implement the sliding window inference and chip training, and ideally also do a k-means search of your anchors.

Okay, Thank you.

Great, you're welcome!