Spaces:
Sleeping
license: mit
title: monitoringInterface
sdk: gradio
emoji: π
colorFrom: purple
colorTo: purple
monitoring-interface
Requirements
pip install -r requiremnets.txt
To install Detectron2, please follow here.
Dataset Preparation
We use Fiftyone library to load and visualize datasets.
BDD100k, COCO, KITTI and OpenImage can be loaded directly through Fiftyone Datasets Zoo.
For other datasets, such as NuScene can be loaded manually via the following simple pattern:
import fiftyone as fo
# A name for the dataset
name = "my-dataset"
# The directory containing the dataset to import
dataset_dir = "/path/to/dataset"
# The type of the dataset being imported
dataset_type = fo.types.COCODetectionDataset # for example
dataset = fo.Dataset.from_dir(
dataset_dir=dataset_dir,
dataset_type=dataset_type,
name=name,
)
The custom dataset folder should have the following structure:
βββ /path/to/dataset
|
βββ Data
βββ labels.json
Notice that the annotation file labels.json
should be prepared in COCO format.
Interface demo
Three interfaces are provided:
interface.py
: all-in-1 interfaceinterface_tabbed.py
: tabbed interfaceenlarge.py
: interface for monitor interval enlargement
To run any of these interfaces, just execute python <script name.py>
.
Please note that feature extraction for both training data and evaluation data can be a time-consuming process. However, if you are only interested in testing monitor construction, monitor evaluation, or monitoring demo, you can use the following settings to load a pretrained model along with the corresponding extracted features and monitors.
ID | Backbone | Clustering method for Monitors |
---|---|---|
KITTI | ResNet | KMeans(nb_clusters=[1, 4, 5, 6]) |