From 2378745e3b537c08656898c83ba6597e197ac5a7 Mon Sep 17 00:00:00 2001 From: YYJ-aaaa <1058387004@qq.com> Date: Mon, 4 Nov 2024 16:51:44 +0800 Subject: [PATCH] first commit --- config.json | 77 ++++++++++++++++++++++++++++++++++++++++ model.safetensors | 3 ++ preprocessor_config.json | 18 ++++++++++ 3 files changed, 98 insertions(+) create mode 100644 config.json create mode 100644 model.safetensors create mode 100644 preprocessor_config.json diff --git a/config.json b/config.json new file mode 100644 index 0000000..336bffe --- /dev/null +++ b/config.json @@ -0,0 +1,77 @@ +{ + "activation_dropout": 0.0, + "activation_function": "relu", + "architectures": [ + "DeformableDetrForObjectDetection" + ], + "attention_dropout": 0.0, + "auxiliary_loss": false, + "backbone": "resnet50", + "backbone_config": null, + "bbox_cost": 5, + "bbox_loss_coefficient": 5, + "class_cost": 1, + "d_model": 256, + "decoder_attention_heads": 8, + "decoder_ffn_dim": 1024, + "decoder_layers": 6, + "decoder_n_points": 4, + "dice_loss_coefficient": 1, + "dilation": false, + "disable_custom_kernels": false, + "dropout": 0.1, + "encoder_attention_heads": 8, + "encoder_ffn_dim": 1024, + "encoder_layerdrop": 0.0, + "encoder_layers": 6, + "encoder_n_points": 4, + "eos_coefficient": 0.1, + "focal_alpha": 0.25, + "giou_cost": 2, + "giou_loss_coefficient": 2, + "id2label": { + "0": "N/A", + "1": "Caption", + "10": "Text", + "11": "Title", + "2": "Footnote", + "3": "Formula", + "4": "List-item", + "5": "Page-footer", + "6": "Page-header", + "7": "Picture", + "8": "Section-header", + "9": "Table" + }, + "init_std": 0.02, + "init_xavier_std": 1.0, + "is_encoder_decoder": true, + "label2id": { + "Caption": 1, + "Footnote": 2, + "Formula": 3, + "List-item": 4, + "N/A": 0, + "Page-footer": 5, + "Page-header": 6, + "Picture": 7, + "Section-header": 8, + "Table": 9, + "Text": 10, + "Title": 11 + }, + "mask_loss_coefficient": 1, + "max_position_embeddings": 1024, + "model_type": "deformable_detr", + "num_channels": 3, + "num_feature_levels": 4, + "num_queries": 200, + "position_embedding_type": "sine", + "torch_dtype": "float32", + "transformers_version": "4.36.2", + "two_stage": true, + "two_stage_num_proposals": 200, + "use_pretrained_backbone": true, + "use_timm_backbone": "SenseTime/deformable-detr-with-box-refine-two-stage", + "with_box_refine": true +} diff --git a/model.safetensors b/model.safetensors new file mode 100644 index 0000000..4abbb9b --- /dev/null +++ b/model.safetensors @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:e3861d34685d3b36e5f38370597daf98fb2f98a852cfa5c125035057ded06809 +size 164653696 diff --git a/preprocessor_config.json b/preprocessor_config.json new file mode 100644 index 0000000..04d3b5c --- /dev/null +++ b/preprocessor_config.json @@ -0,0 +1,18 @@ +{ + "do_normalize": true, + "do_resize": true, + "image_processor_type": "DeformableDetrImageProcessor", + "format": "coco_detection", + "image_mean": [ + 0.0, + 0.0, + 0.0 + ], + "image_std": [ + 1.0, + 1.0, + 1.0 + ], + "max_size": 1333, + "size": 800 +}