Link to Analysis: Analysis
Ensure you have Docker installed on your system. Pull the repo and run
docker build -t bdd-project-env
I tried finetuning RTDETR for 6 epochs: Checkpoint
Please put it under train/checkpoints/
Run the script to create dataframes for analysis:
docker run --rm \
-v "/path/to/assignment_data_bdd/:/data" \
-v "<path to local repo folder>:/bdd_files" \
bdd-project-env \
python data/create_dataframes.py \
--base-path /data \
--output-path /bdd_filesStart the Streamlit app to perform analysis:
PLEASE SCROLL HORIZONTALLY AND COPY THE ENTIRE COMMAND, STREAMLIT ACTS WEIRD WITH MULTILINE ARGPARSE HENCE I HAD TO PUT IT ALL IN ONE LINE
docker run -p 8501:8501 --rm \
-v "/path/to/assignment_data_bdd/:/data" \
-v "<path to where you pulled the repo>:/bdd_files" \
bdd-project-env \
streamlit run data/dashboard_with_val.py -- --train-df-path /bdd_files/extracted_data.pq --val-df-path /bdd_files/extracted_data_val.pq --base-data-path /dataGenerate the necessary COCO files:
docker run --rm \
-v "/path/to/assignment_data_bdd/:/data" \
-v "<path to where you pulled the repo>:/bdd_files" \
bdd-project-env \
python data/json_to_coco.py \
--bdd-json-path /data/bdd100k_labels_release/bdd100k/labels/bdd100k_labels_images_train.json \
--output-json-path /data/bdd100k_images_100k/bdd100k/images/100k/train/_annotations.coco.json \
--split-name train
docker run --rm \
-v "/path/to/assignment_data_bdd/:/data" \
-v "<path to where you pulled the repo>:/bdd_files" \
bdd-project-env \
python data/json_to_coco.py \
--bdd-json-path /data/bdd100k_labels_release/bdd100k/labels/bdd100k_labels_images_val.json \
--output-json-path /data/bdd100k_images_100k/bdd100k/images/100k/val/_annotations.coco.json \
--split-name valTrain the RT-DETR model:
docker run --rm \
-v "/path/to/assignment_data_bdd/:/data" \
-v "<path to where you pulled the repo>:/bdd_files" \
bdd-project-env \
python train/train_rtdetr.pyEvaluate the trained model and generate metrics:
docker run --rm \
-v "/path/to/assignment_data_bdd/:/data" \
-v "<path to where you pulled the repo>:/bdd_files" \
bdd-project-env \
python train/eval_model.py --output-path /bdd_filesRun the Streamlit app to visualize results and perform qualitative analysis:
PLEASE SCROLL HORIZONTALLY AND COPY THE ENTIRE COMMAND, STREAMLIT ACTS WEIRD WITH MULTILINE ARGPARSE HENCE I HAD TO PUT IT ALL IN ONE LINE
docker run -p 8501:8501 --rm \
-v "/path/to/assignment_data_bdd/:/data" \
-v "<path to where you pulled the repo>:/bdd_files" \
bdd-project-env \
streamlit run eval/eval_dashboard.py -- --matched-predictions-path /bdd_files/results_iou.json --image-dir /data/bdd100k_images_100k/bdd100k/images/100k/val --processed-data-path /bdd_files/extracted_data_val.pq --coco-annotations-path /data/bdd100k_images_100k/bdd100k/images/100k/val/_annotations.coco.json- Ensure all paths are correctly set according to your project structure.
- Adjust the Docker volumes as necessary for your environment.