Shank2358 / GGHL

This is the implementation of GGHL (A General Gaussian Heatmap Label Assignment for Arbitrary-Oriented Object Detection)
GNU General Public License v3.0
625 stars 112 forks source link

Error when trying to execute demo on single image #19

Closed TerrafYassin closed 1 year ago

TerrafYassin commented 2 years ago

image

Crescent-Ao commented 2 years ago

Can you provide more information about inference settings such as config, log information, input image?

TerrafYassin commented 2 years ago

config :

coding=utf-8

DATA_PATH = "/content/drive/MyDrive/HRSC2016"#"F:/Datasets/DOTAx/test/"# PROJECT_PATH = "/content/drive/MyDrive/GGHL/"

DATA = {"CLASSES": [ 'ship', ],

    "NUM": 1}

DATASET_NAME = "train_HRSC2016" MODEL = {"STRIDES":[8, 16, 32]}

MAX_LABEL = 1000 SHOW_HEATMAP = False SCALE_FACTOR = 2.0#2.0 SCALE_FACTOR_A = 2.0 #3.0

TRAIN = { "EVAL_TYPE": 'VOC', # ['VOC', 'COCO'] "TRAIN_IMG_SIZE": 800, "TRAIN_IMG_NUM": 63182, "AUGMENT": True, "MULTI_SCALE_TRAIN": True, "MULTI_TRAIN_RANGE": [23, 28, 1], "BATCH_SIZE": 8, "IOU_THRESHOLD_LOSS": 0.6, "EPOCHS": 151, "NUMBER_WORKERS": 12, "MOMENTUM": 0.9, "WEIGHT_DECAY": 0.0005, "LR_INIT": 1e-4, "LR_END": 1e-6, "WARMUP_EPOCHS": 5, "IOU_TYPE": 'GIOU' # ['GIOU','CIOU'] }

TEST = { "EVAL_TYPE": 'VOC', "EVAL_JSON": 'test.json', "EVAL_NAME": 'test', "NUM_VIS_IMG": 0, "TEST_IMG_SIZE": 800, "BATCH_SIZE": 4, "NUMBER_WORKERS": 24, "CONF_THRESH": 0.3, "NMS_THRESH": 0.45, "IOU_THRESHOLD": 0.5, "NMS_METHODS": 'NMS', "MULTI_SCALE_TEST": False, "MULTI_TEST_RANGE": [736, 864, 96], "FLIP_TEST": False }

TerrafYassin commented 2 years ago

for the input images i select some images from test folder of HRSC2016 dataset

TerrafYassin commented 2 years ago

image

Shank2358 commented 2 years ago

image

I have updated the codes to fix this problem. Please update the codes. Thanks.

YoonaIAN commented 2 years ago

请问这个代码是在pytorch框架下的吗

Crescent-Ao commented 2 years ago

Sure, the network is implemented on the Pytorch.

YoonaIAN commented 2 years ago

Sure, the network is implemented on the Pytorch.

谢谢。再请问一下,如果想用您训练好的权重测试图片是不是只要把环境配置好,然后在config.py修改好路径,运行test.py就可以了?