wskingdom/Crowd-Hat

请问有SHA、SHB和QNRF数据集的处理方式提供吗

Closed this issue · 1 comments

请问有SHA、SHB和QNRF数据集的处理方式提供吗

你好,ShanghaiTech和UCF-QNRF的checkpoint/训练方式等将在近日加入repo。所有数据集的预处理和NWPU-Crowd是相同的,可以直接改hat_config里的img_root和json_root;如果你指的是读取gt标注,实际上只需要读取人群点标注points和人数count。

简单处理一下,有:
def load_annotation_shanghaitech(mat_path):
points = loadmat(mat_path)['image_info'][0][0][0][0][0]
count = points.shape[0]
return count,points

def load_annotation_ucf_qnrf(mat_path):
points = loadmat(mat_path)['annPoints']
count = points.shape[0]
return count,points

我们在持续更新中,之后会提供更多接口,欢迎关注我们的工作