From e9c8623973f585fdb0d53e8b3784c53965e92a5a Mon Sep 17 00:00:00 2001 From: Kye Date: Tue, 3 Oct 2023 16:56:55 -0400 Subject: [PATCH] clean up --- swarms/agents/{ => models}/groundingdino/__init__.py | 0 .../groundingdino/config/GroundingDINO_SwinB_cfg.py | 0 .../groundingdino/config/GroundingDINO_SwinT_OGC.py | 0 .../agents/{ => models}/groundingdino/config/__init__.py | 0 .../{ => models}/groundingdino/datasets/__init__.py | 0 .../groundingdino/datasets/cocogrounding_eval.py | 0 .../{ => models}/groundingdino/datasets/transforms.py | 0 .../groundingdino/models/GroundingDINO/__init__.py | 0 .../models/GroundingDINO/backbone/__init__.py | 0 .../models/GroundingDINO/backbone/backbone.py | 0 .../models/GroundingDINO/backbone/position_encoding.py | 0 .../models/GroundingDINO/backbone/swin_transformer.py | 0 .../groundingdino/models/GroundingDINO/bertwarper.py | 0 .../GroundingDINO/csrc/MsDeformAttn/ms_deform_attn.h | 0 .../csrc/MsDeformAttn/ms_deform_attn_cpu.cpp | 0 .../GroundingDINO/csrc/MsDeformAttn/ms_deform_attn_cpu.h | 0 .../csrc/MsDeformAttn/ms_deform_attn_cuda.cu | 0 .../GroundingDINO/csrc/MsDeformAttn/ms_deform_attn_cuda.h | 0 .../csrc/MsDeformAttn/ms_deform_im2col_cuda.cuh | 0 .../models/GroundingDINO/csrc/cuda_version.cu | 0 .../groundingdino/models/GroundingDINO/csrc/vision.cpp | 0 .../groundingdino/models/GroundingDINO/fuse_modules.py | 0 .../groundingdino/models/GroundingDINO/groundingdino.py | 0 .../groundingdino/models/GroundingDINO/ms_deform_attn.py | 0 .../groundingdino/models/GroundingDINO/transformer.py | 0 .../models/GroundingDINO/transformer_vanilla.py | 0 .../groundingdino/models/GroundingDINO/utils.py | 0 .../agents/{ => models}/groundingdino/models/__init__.py | 0 .../agents/{ => models}/groundingdino/models/registry.py | 0 swarms/agents/{ => models}/groundingdino/util/__init__.py | 0 swarms/agents/{ => models}/groundingdino/util/box_ops.py | 0 .../{ => models}/groundingdino/util/get_tokenlizer.py | 0 .../agents/{ => models}/groundingdino/util/inference.py | 0 swarms/agents/{ => models}/groundingdino/util/logger.py | 0 swarms/agents/{ => models}/groundingdino/util/misc.py | 0 swarms/agents/{ => models}/groundingdino/util/slconfig.py | 0 swarms/agents/{ => models}/groundingdino/util/slio.py | 0 .../{ => models}/groundingdino/util/time_counter.py | 0 swarms/agents/{ => models}/groundingdino/util/utils.py | 0 .../agents/{ => models}/groundingdino/util/visualizer.py | 0 swarms/agents/{ => models}/groundingdino/util/vl_utils.py | 0 swarms/agents/multi_modal_visual_agent.py | 8 ++++---- 42 files changed, 4 insertions(+), 4 deletions(-) rename swarms/agents/{ => models}/groundingdino/__init__.py (100%) rename swarms/agents/{ => models}/groundingdino/config/GroundingDINO_SwinB_cfg.py (100%) rename swarms/agents/{ => models}/groundingdino/config/GroundingDINO_SwinT_OGC.py (100%) rename swarms/agents/{ => models}/groundingdino/config/__init__.py (100%) rename swarms/agents/{ => models}/groundingdino/datasets/__init__.py (100%) rename swarms/agents/{ => models}/groundingdino/datasets/cocogrounding_eval.py (100%) rename swarms/agents/{ => models}/groundingdino/datasets/transforms.py (100%) rename swarms/agents/{ => models}/groundingdino/models/GroundingDINO/__init__.py (100%) rename swarms/agents/{ => models}/groundingdino/models/GroundingDINO/backbone/__init__.py (100%) rename swarms/agents/{ => models}/groundingdino/models/GroundingDINO/backbone/backbone.py (100%) rename swarms/agents/{ => models}/groundingdino/models/GroundingDINO/backbone/position_encoding.py (100%) rename swarms/agents/{ => models}/groundingdino/models/GroundingDINO/backbone/swin_transformer.py (100%) rename swarms/agents/{ => models}/groundingdino/models/GroundingDINO/bertwarper.py (100%) rename swarms/agents/{ => models}/groundingdino/models/GroundingDINO/csrc/MsDeformAttn/ms_deform_attn.h (100%) rename swarms/agents/{ => models}/groundingdino/models/GroundingDINO/csrc/MsDeformAttn/ms_deform_attn_cpu.cpp (100%) rename swarms/agents/{ => models}/groundingdino/models/GroundingDINO/csrc/MsDeformAttn/ms_deform_attn_cpu.h (100%) rename swarms/agents/{ => models}/groundingdino/models/GroundingDINO/csrc/MsDeformAttn/ms_deform_attn_cuda.cu (100%) rename swarms/agents/{ => models}/groundingdino/models/GroundingDINO/csrc/MsDeformAttn/ms_deform_attn_cuda.h (100%) rename swarms/agents/{ => models}/groundingdino/models/GroundingDINO/csrc/MsDeformAttn/ms_deform_im2col_cuda.cuh (100%) rename swarms/agents/{ => models}/groundingdino/models/GroundingDINO/csrc/cuda_version.cu (100%) rename swarms/agents/{ => models}/groundingdino/models/GroundingDINO/csrc/vision.cpp (100%) rename swarms/agents/{ => models}/groundingdino/models/GroundingDINO/fuse_modules.py (100%) rename swarms/agents/{ => models}/groundingdino/models/GroundingDINO/groundingdino.py (100%) rename swarms/agents/{ => models}/groundingdino/models/GroundingDINO/ms_deform_attn.py (100%) rename swarms/agents/{ => models}/groundingdino/models/GroundingDINO/transformer.py (100%) rename swarms/agents/{ => models}/groundingdino/models/GroundingDINO/transformer_vanilla.py (100%) rename swarms/agents/{ => models}/groundingdino/models/GroundingDINO/utils.py (100%) rename swarms/agents/{ => models}/groundingdino/models/__init__.py (100%) rename swarms/agents/{ => models}/groundingdino/models/registry.py (100%) rename swarms/agents/{ => models}/groundingdino/util/__init__.py (100%) rename swarms/agents/{ => models}/groundingdino/util/box_ops.py (100%) rename swarms/agents/{ => models}/groundingdino/util/get_tokenlizer.py (100%) rename swarms/agents/{ => models}/groundingdino/util/inference.py (100%) rename swarms/agents/{ => models}/groundingdino/util/logger.py (100%) rename swarms/agents/{ => models}/groundingdino/util/misc.py (100%) rename swarms/agents/{ => models}/groundingdino/util/slconfig.py (100%) rename swarms/agents/{ => models}/groundingdino/util/slio.py (100%) rename swarms/agents/{ => models}/groundingdino/util/time_counter.py (100%) rename swarms/agents/{ => models}/groundingdino/util/utils.py (100%) rename swarms/agents/{ => models}/groundingdino/util/visualizer.py (100%) rename swarms/agents/{ => models}/groundingdino/util/vl_utils.py (100%) diff --git a/swarms/agents/groundingdino/__init__.py b/swarms/agents/models/groundingdino/__init__.py similarity index 100% rename from swarms/agents/groundingdino/__init__.py rename to swarms/agents/models/groundingdino/__init__.py diff --git a/swarms/agents/groundingdino/config/GroundingDINO_SwinB_cfg.py b/swarms/agents/models/groundingdino/config/GroundingDINO_SwinB_cfg.py similarity index 100% rename from swarms/agents/groundingdino/config/GroundingDINO_SwinB_cfg.py rename to swarms/agents/models/groundingdino/config/GroundingDINO_SwinB_cfg.py diff --git a/swarms/agents/groundingdino/config/GroundingDINO_SwinT_OGC.py b/swarms/agents/models/groundingdino/config/GroundingDINO_SwinT_OGC.py similarity index 100% rename from swarms/agents/groundingdino/config/GroundingDINO_SwinT_OGC.py rename to swarms/agents/models/groundingdino/config/GroundingDINO_SwinT_OGC.py diff --git a/swarms/agents/groundingdino/config/__init__.py b/swarms/agents/models/groundingdino/config/__init__.py similarity index 100% rename from swarms/agents/groundingdino/config/__init__.py rename to swarms/agents/models/groundingdino/config/__init__.py diff --git a/swarms/agents/groundingdino/datasets/__init__.py b/swarms/agents/models/groundingdino/datasets/__init__.py similarity index 100% rename from swarms/agents/groundingdino/datasets/__init__.py rename to swarms/agents/models/groundingdino/datasets/__init__.py diff --git a/swarms/agents/groundingdino/datasets/cocogrounding_eval.py b/swarms/agents/models/groundingdino/datasets/cocogrounding_eval.py similarity index 100% rename from swarms/agents/groundingdino/datasets/cocogrounding_eval.py rename to swarms/agents/models/groundingdino/datasets/cocogrounding_eval.py diff --git a/swarms/agents/groundingdino/datasets/transforms.py b/swarms/agents/models/groundingdino/datasets/transforms.py similarity index 100% rename from swarms/agents/groundingdino/datasets/transforms.py rename to swarms/agents/models/groundingdino/datasets/transforms.py diff --git a/swarms/agents/groundingdino/models/GroundingDINO/__init__.py b/swarms/agents/models/groundingdino/models/GroundingDINO/__init__.py similarity index 100% rename from swarms/agents/groundingdino/models/GroundingDINO/__init__.py rename to swarms/agents/models/groundingdino/models/GroundingDINO/__init__.py diff --git a/swarms/agents/groundingdino/models/GroundingDINO/backbone/__init__.py b/swarms/agents/models/groundingdino/models/GroundingDINO/backbone/__init__.py similarity index 100% rename from swarms/agents/groundingdino/models/GroundingDINO/backbone/__init__.py rename to swarms/agents/models/groundingdino/models/GroundingDINO/backbone/__init__.py diff --git a/swarms/agents/groundingdino/models/GroundingDINO/backbone/backbone.py b/swarms/agents/models/groundingdino/models/GroundingDINO/backbone/backbone.py similarity index 100% rename from swarms/agents/groundingdino/models/GroundingDINO/backbone/backbone.py rename to swarms/agents/models/groundingdino/models/GroundingDINO/backbone/backbone.py diff --git a/swarms/agents/groundingdino/models/GroundingDINO/backbone/position_encoding.py b/swarms/agents/models/groundingdino/models/GroundingDINO/backbone/position_encoding.py similarity index 100% rename from swarms/agents/groundingdino/models/GroundingDINO/backbone/position_encoding.py rename to swarms/agents/models/groundingdino/models/GroundingDINO/backbone/position_encoding.py diff --git a/swarms/agents/groundingdino/models/GroundingDINO/backbone/swin_transformer.py b/swarms/agents/models/groundingdino/models/GroundingDINO/backbone/swin_transformer.py similarity index 100% rename from swarms/agents/groundingdino/models/GroundingDINO/backbone/swin_transformer.py rename to swarms/agents/models/groundingdino/models/GroundingDINO/backbone/swin_transformer.py diff --git a/swarms/agents/groundingdino/models/GroundingDINO/bertwarper.py b/swarms/agents/models/groundingdino/models/GroundingDINO/bertwarper.py similarity index 100% rename from swarms/agents/groundingdino/models/GroundingDINO/bertwarper.py rename to swarms/agents/models/groundingdino/models/GroundingDINO/bertwarper.py diff --git a/swarms/agents/groundingdino/models/GroundingDINO/csrc/MsDeformAttn/ms_deform_attn.h b/swarms/agents/models/groundingdino/models/GroundingDINO/csrc/MsDeformAttn/ms_deform_attn.h similarity index 100% rename from swarms/agents/groundingdino/models/GroundingDINO/csrc/MsDeformAttn/ms_deform_attn.h rename to swarms/agents/models/groundingdino/models/GroundingDINO/csrc/MsDeformAttn/ms_deform_attn.h diff --git a/swarms/agents/groundingdino/models/GroundingDINO/csrc/MsDeformAttn/ms_deform_attn_cpu.cpp b/swarms/agents/models/groundingdino/models/GroundingDINO/csrc/MsDeformAttn/ms_deform_attn_cpu.cpp similarity index 100% rename from swarms/agents/groundingdino/models/GroundingDINO/csrc/MsDeformAttn/ms_deform_attn_cpu.cpp rename to swarms/agents/models/groundingdino/models/GroundingDINO/csrc/MsDeformAttn/ms_deform_attn_cpu.cpp diff --git a/swarms/agents/groundingdino/models/GroundingDINO/csrc/MsDeformAttn/ms_deform_attn_cpu.h b/swarms/agents/models/groundingdino/models/GroundingDINO/csrc/MsDeformAttn/ms_deform_attn_cpu.h similarity index 100% rename from swarms/agents/groundingdino/models/GroundingDINO/csrc/MsDeformAttn/ms_deform_attn_cpu.h rename to swarms/agents/models/groundingdino/models/GroundingDINO/csrc/MsDeformAttn/ms_deform_attn_cpu.h diff --git a/swarms/agents/groundingdino/models/GroundingDINO/csrc/MsDeformAttn/ms_deform_attn_cuda.cu b/swarms/agents/models/groundingdino/models/GroundingDINO/csrc/MsDeformAttn/ms_deform_attn_cuda.cu similarity index 100% rename from swarms/agents/groundingdino/models/GroundingDINO/csrc/MsDeformAttn/ms_deform_attn_cuda.cu rename to swarms/agents/models/groundingdino/models/GroundingDINO/csrc/MsDeformAttn/ms_deform_attn_cuda.cu diff --git a/swarms/agents/groundingdino/models/GroundingDINO/csrc/MsDeformAttn/ms_deform_attn_cuda.h b/swarms/agents/models/groundingdino/models/GroundingDINO/csrc/MsDeformAttn/ms_deform_attn_cuda.h similarity index 100% rename from swarms/agents/groundingdino/models/GroundingDINO/csrc/MsDeformAttn/ms_deform_attn_cuda.h rename to swarms/agents/models/groundingdino/models/GroundingDINO/csrc/MsDeformAttn/ms_deform_attn_cuda.h diff --git a/swarms/agents/groundingdino/models/GroundingDINO/csrc/MsDeformAttn/ms_deform_im2col_cuda.cuh b/swarms/agents/models/groundingdino/models/GroundingDINO/csrc/MsDeformAttn/ms_deform_im2col_cuda.cuh similarity index 100% rename from swarms/agents/groundingdino/models/GroundingDINO/csrc/MsDeformAttn/ms_deform_im2col_cuda.cuh rename to swarms/agents/models/groundingdino/models/GroundingDINO/csrc/MsDeformAttn/ms_deform_im2col_cuda.cuh diff --git a/swarms/agents/groundingdino/models/GroundingDINO/csrc/cuda_version.cu b/swarms/agents/models/groundingdino/models/GroundingDINO/csrc/cuda_version.cu similarity index 100% rename from swarms/agents/groundingdino/models/GroundingDINO/csrc/cuda_version.cu rename to swarms/agents/models/groundingdino/models/GroundingDINO/csrc/cuda_version.cu diff --git a/swarms/agents/groundingdino/models/GroundingDINO/csrc/vision.cpp b/swarms/agents/models/groundingdino/models/GroundingDINO/csrc/vision.cpp similarity index 100% rename from swarms/agents/groundingdino/models/GroundingDINO/csrc/vision.cpp rename to swarms/agents/models/groundingdino/models/GroundingDINO/csrc/vision.cpp diff --git a/swarms/agents/groundingdino/models/GroundingDINO/fuse_modules.py b/swarms/agents/models/groundingdino/models/GroundingDINO/fuse_modules.py similarity index 100% rename from swarms/agents/groundingdino/models/GroundingDINO/fuse_modules.py rename to swarms/agents/models/groundingdino/models/GroundingDINO/fuse_modules.py diff --git a/swarms/agents/groundingdino/models/GroundingDINO/groundingdino.py b/swarms/agents/models/groundingdino/models/GroundingDINO/groundingdino.py similarity index 100% rename from swarms/agents/groundingdino/models/GroundingDINO/groundingdino.py rename to swarms/agents/models/groundingdino/models/GroundingDINO/groundingdino.py diff --git a/swarms/agents/groundingdino/models/GroundingDINO/ms_deform_attn.py b/swarms/agents/models/groundingdino/models/GroundingDINO/ms_deform_attn.py similarity index 100% rename from swarms/agents/groundingdino/models/GroundingDINO/ms_deform_attn.py rename to swarms/agents/models/groundingdino/models/GroundingDINO/ms_deform_attn.py diff --git a/swarms/agents/groundingdino/models/GroundingDINO/transformer.py b/swarms/agents/models/groundingdino/models/GroundingDINO/transformer.py similarity index 100% rename from swarms/agents/groundingdino/models/GroundingDINO/transformer.py rename to swarms/agents/models/groundingdino/models/GroundingDINO/transformer.py diff --git a/swarms/agents/groundingdino/models/GroundingDINO/transformer_vanilla.py b/swarms/agents/models/groundingdino/models/GroundingDINO/transformer_vanilla.py similarity index 100% rename from swarms/agents/groundingdino/models/GroundingDINO/transformer_vanilla.py rename to swarms/agents/models/groundingdino/models/GroundingDINO/transformer_vanilla.py diff --git a/swarms/agents/groundingdino/models/GroundingDINO/utils.py b/swarms/agents/models/groundingdino/models/GroundingDINO/utils.py similarity index 100% rename from swarms/agents/groundingdino/models/GroundingDINO/utils.py rename to swarms/agents/models/groundingdino/models/GroundingDINO/utils.py diff --git a/swarms/agents/groundingdino/models/__init__.py b/swarms/agents/models/groundingdino/models/__init__.py similarity index 100% rename from swarms/agents/groundingdino/models/__init__.py rename to swarms/agents/models/groundingdino/models/__init__.py diff --git a/swarms/agents/groundingdino/models/registry.py b/swarms/agents/models/groundingdino/models/registry.py similarity index 100% rename from swarms/agents/groundingdino/models/registry.py rename to swarms/agents/models/groundingdino/models/registry.py diff --git a/swarms/agents/groundingdino/util/__init__.py b/swarms/agents/models/groundingdino/util/__init__.py similarity index 100% rename from swarms/agents/groundingdino/util/__init__.py rename to swarms/agents/models/groundingdino/util/__init__.py diff --git a/swarms/agents/groundingdino/util/box_ops.py b/swarms/agents/models/groundingdino/util/box_ops.py similarity index 100% rename from swarms/agents/groundingdino/util/box_ops.py rename to swarms/agents/models/groundingdino/util/box_ops.py diff --git a/swarms/agents/groundingdino/util/get_tokenlizer.py b/swarms/agents/models/groundingdino/util/get_tokenlizer.py similarity index 100% rename from swarms/agents/groundingdino/util/get_tokenlizer.py rename to swarms/agents/models/groundingdino/util/get_tokenlizer.py diff --git a/swarms/agents/groundingdino/util/inference.py b/swarms/agents/models/groundingdino/util/inference.py similarity index 100% rename from swarms/agents/groundingdino/util/inference.py rename to swarms/agents/models/groundingdino/util/inference.py diff --git a/swarms/agents/groundingdino/util/logger.py b/swarms/agents/models/groundingdino/util/logger.py similarity index 100% rename from swarms/agents/groundingdino/util/logger.py rename to swarms/agents/models/groundingdino/util/logger.py diff --git a/swarms/agents/groundingdino/util/misc.py b/swarms/agents/models/groundingdino/util/misc.py similarity index 100% rename from swarms/agents/groundingdino/util/misc.py rename to swarms/agents/models/groundingdino/util/misc.py diff --git a/swarms/agents/groundingdino/util/slconfig.py b/swarms/agents/models/groundingdino/util/slconfig.py similarity index 100% rename from swarms/agents/groundingdino/util/slconfig.py rename to swarms/agents/models/groundingdino/util/slconfig.py diff --git a/swarms/agents/groundingdino/util/slio.py b/swarms/agents/models/groundingdino/util/slio.py similarity index 100% rename from swarms/agents/groundingdino/util/slio.py rename to swarms/agents/models/groundingdino/util/slio.py diff --git a/swarms/agents/groundingdino/util/time_counter.py b/swarms/agents/models/groundingdino/util/time_counter.py similarity index 100% rename from swarms/agents/groundingdino/util/time_counter.py rename to swarms/agents/models/groundingdino/util/time_counter.py diff --git a/swarms/agents/groundingdino/util/utils.py b/swarms/agents/models/groundingdino/util/utils.py similarity index 100% rename from swarms/agents/groundingdino/util/utils.py rename to swarms/agents/models/groundingdino/util/utils.py diff --git a/swarms/agents/groundingdino/util/visualizer.py b/swarms/agents/models/groundingdino/util/visualizer.py similarity index 100% rename from swarms/agents/groundingdino/util/visualizer.py rename to swarms/agents/models/groundingdino/util/visualizer.py diff --git a/swarms/agents/groundingdino/util/vl_utils.py b/swarms/agents/models/groundingdino/util/vl_utils.py similarity index 100% rename from swarms/agents/groundingdino/util/vl_utils.py rename to swarms/agents/models/groundingdino/util/vl_utils.py diff --git a/swarms/agents/multi_modal_visual_agent.py b/swarms/agents/multi_modal_visual_agent.py index 72fe8953..bec5de7c 100644 --- a/swarms/agents/multi_modal_visual_agent.py +++ b/swarms/agents/multi_modal_visual_agent.py @@ -1046,11 +1046,11 @@ class Text2Box: # load image image_pil = Image.open(image_path).convert("RGB") # load image - transform = Compose( + transform = T.Compose( [ - RandomResize([512], max_size=1333), - ToTensor(), - Normalize([0.485, 0.456, 0.406], [0.229, 0.224, 0.225]), + T.RandomResize([512], max_size=1333), + T.ToTensor(), + T.Normalize([0.485, 0.456, 0.406], [0.229, 0.224, 0.225]), ] ) image, _ = transform(image_pil, None) # 3, h, w