feat: supervison downloader added

Signed-off-by: Onuralp SEZER <thunderbirdtr@gmail.com>
This commit is contained in:
Onuralp SEZER 2024-01-09 05:15:28 +03:00
parent a72ad42628
commit a337ee591a
No known key found for this signature in database
GPG Key ID: CF0835DFDF14CA38
4 changed files with 11 additions and 17 deletions

View File

@ -36,7 +36,7 @@ https://github.com/roboflow/supervision/assets/26109316/0542fd3c-bb5f-475e-b96c-
- download `vehicles.mp4` file
```bash
./setup.sh
python3.10 video_downloader.py
```
## 🛠️ script arguments

View File

@ -1,6 +1,6 @@
gdown
supervision==0.18.0rc1
tqdm
requests
ultralytics
super-gradients
inference

View File

@ -1,14 +0,0 @@
#!/bin/bash
# Get the directory where the script is located
DIR="$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )"
# Check if 'data' directory does not exist and then create it
if [[ ! -e $DIR/data ]]; then
mkdir "$DIR/data"
else
echo "'data' directory already exists."
fi
# Download the vehicles.mp4 file from Google Drive
gdown -O "$DIR/data/vehicles.mp4" "https://drive.google.com/uc?id=1pz68D1Gsx80MoPg-_q-IbEdESEmyVLm-"

View File

@ -0,0 +1,8 @@
import os
from supervision.assets import VideoAssets, download_assets
if not os.path.exists("data"):
os.makedirs("data")
os.chdir("data")
download_assets(VideoAssets.VEHICLES)