Skip to content

Commit

Permalink
Merge pull request #232 from InnopolisUni/mm
Browse files Browse the repository at this point in the history
Mmdetection 3d integration
  • Loading branch information
BarzaH authored Sep 16, 2024
2 parents f260535 + 8daf70a commit 350914a
Show file tree
Hide file tree
Showing 21 changed files with 5,946 additions and 3,038 deletions.
1 change: 1 addition & 0 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
./data
wandb/
lightning_logs/
mmdetection3d/
*.pth
# Byte-compiled / optimized / DLL files
__pycache__/
Expand Down
11 changes: 6 additions & 5 deletions Dockerfile
Original file line number Diff line number Diff line change
@@ -1,11 +1,12 @@
FROM python:3.8.3-slim

RUN apt-get update && apt-get upgrade -y
RUN apt-get install ffmpeg libsm6 libxext6 -y
RUN apt-get install curl -y
RUN pip3 install --upgrade pip
RUN apt-get update && apt-get upgrade -y && \
apt-get install ffmpeg libsm6 libxext6 -y && \
apt-get install curl -y && \
apt-get -y install git && \
pip3 install --upgrade pip
# works with 1.2.2
RUN /bin/bash -c 'curl -sSL https://install.python-poetry.org | python - --version 1.3.0'
RUN /bin/bash -c 'curl -sSL https://install.python-poetry.org | python - --version 1.6.1'

COPY . /code
WORKDIR code
Expand Down
2 changes: 1 addition & 1 deletion DockerfileMED
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ RUN apt-get update \
&& apt-get install ffmpeg libsm6 libxext6 curl iotop -y \
&& rm -rf /var/lib/{apt,dpkg,cache,log}/
RUN pip3 install --upgrade pip pyopenssl cryptography
RUN /bin/bash -c 'curl -sSL https://install.python-poetry.org | python - --version 1.3.0'
RUN /bin/bash -c 'curl -sSL https://install.python-poetry.org | python - --version 1.6.1'

COPY . /code
RUN rm -r /code/config/experiments/*
Expand Down
2 changes: 1 addition & 1 deletion DockerfileNM
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ RUN apt-get update \
&& apt-get install ffmpeg libsm6 libxext6 curl iotop -y \
&& rm -rf /var/lib/{apt,dpkg,cache,log}/
RUN pip3 install --upgrade pip pyopenssl cryptography
RUN /bin/bash -c 'curl -sSL https://install.python-poetry.org | python - --version 1.3.0'
RUN /bin/bash -c 'curl -sSL https://install.python-poetry.org | python - --version 1.6.1'

COPY . /code
RUN rm -r /code/config/experiments/*
Expand Down
2 changes: 1 addition & 1 deletion DockerfilePROM
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ RUN apt-get update \
&& apt-get install ffmpeg libsm6 libxext6 curl iotop -y \
&& rm -rf /var/lib/{apt,dpkg,cache,log}/
RUN pip3 install --upgrade pip pyopenssl cryptography
RUN /bin/bash -c 'curl -sSL https://install.python-poetry.org | python - --version 1.3.0'
RUN /bin/bash -c 'curl -sSL https://install.python-poetry.org | python - --version 1.6.1'

COPY . /code
RUN rm -r /code/config/experiments/*
Expand Down
27 changes: 27 additions & 0 deletions config/datasets/detection-3d/lep_3d_dataset.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,27 @@
task:
- 3d-detection

name: lep_3d
description: Набор данных содержит видео облетов c бпла над территорией линии электропередач

markup_info: Набор данных содержит разметку bounding box, под формат детекции столбов ЛЭП.
date_time: 10.06.2024

_target_: innofw.core.integrations.mmdetection.datamodule.Mmdetection3DDataModuleAdapter

train:
source: https://api.blackhole.ai.innopolis.university/public-datasets/lep_3d_detection/train.zip
target: ./data/lep3d

test:
source: https://api.blackhole.ai.innopolis.university/public-datasets/lep_3d_detection/test.zip
target: ./data/lep3d

infer:
source: https://api.blackhole.ai.innopolis.university/public-datasets/lep_3d_detection/test.zip
target: ./data/lep3d

num_workers: 8

val_size: 0.2
num_classes: 4
14 changes: 14 additions & 0 deletions config/experiments/detection-3d/KG_110624_oegq01.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,14 @@
# @package _global_
defaults:
- override /models: detection-3d/base
- override /datasets: detection-3d/lep_3d_dataset
- override /optimizers: adam

project: "lep_3d_det"
task: "3d-detection"
random_seed: 42
epochs: 10
batch_size: 2
weights_freq: 1
accelerator: gpu
devices: 0
3 changes: 3 additions & 0 deletions config/models/detection-3d/base.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
_target_: innofw.core.integrations.mmdetection.model_adapter.BaseMmdetModel
description: "base model for 3D point cloud detection"
name: "Base 3D model"
2 changes: 1 addition & 1 deletion dui/pages/config_list.py
Original file line number Diff line number Diff line change
Expand Up @@ -72,7 +72,7 @@ def layout():
selected_rows=[],
page_action="native",
page_current=0,
page_size=10,
page_size=20,
style_header={'backgroundColor': 'white',
'fontWeight': 'bold',
'textAlign': 'left'
Expand Down
1 change: 1 addition & 0 deletions innofw/constants.py
Original file line number Diff line number Diff line change
Expand Up @@ -19,6 +19,7 @@ class Frameworks(Enum):
xgboost = "xgboost"
catboost = "catboost"
ultralytics = "ultralytics"
mmdetection = "mmdetection"
none = "none"

PathLike = TypeVar(
Expand Down
1 change: 1 addition & 0 deletions innofw/core/integrations/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -3,3 +3,4 @@
UltralyticsDataModuleAdapter as UltralyticsDataModule,
)
from .ultralytics.ultralytics_adapter import UltralyticsAdapter as YOLOv5
from .mmdetection.datamodule import Mmdetection3DDataModuleAdapter as Mmdetection3DDataModule
Empty file.
Loading

0 comments on commit 350914a

Please sign in to comment.