Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat!: perception frame config #114

Closed
wants to merge 9 commits into from
2 changes: 1 addition & 1 deletion .vscode/settings.json
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@
"editor.formatOnPaste": true,
"editor.formatOnSave": true,
"editor.codeActionsOnSave": {
"source.organizeImports": true
"source.organizeImports": "explicit"
},
"editor.defaultFormatter": "ms-python.black-formatter"
},
Expand Down
8 changes: 4 additions & 4 deletions docs/en/common.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
# Common items in Perception and Sensing

## [`<class> DynamicObject(...)`](../../perception_eval/perception_eval/common/object.py)
## [`<class> DynamicObject(...)`](../../perception_eval/perception_eval/object/object3d.py)

- Evaluation task: `DETECTION`, `TRACKING`, `PREDICTION`, `SENSING`

Expand All @@ -27,7 +27,7 @@
| `predicted_confidence` | `float` | List of predicted confidence. |
| `visibility` | `Optional[Visibility]` | Visibility status. |

## [`<class> DynamicObject2D(...)`](../../perception_eval/perception_eval/common/object2d.py)
## [`<class> DynamicObject2D(...)`](../../perception_eval/perception_eval/object/object2d.py)

- Evaluation task: `DETECTION2D`, `TRACING2D`, `CLASSIFICATION2D`

Expand All @@ -43,7 +43,7 @@

## Ground truth

### [`<class> FrameGroundTruth(...)`](../../perception_eval/perception_eval/common/dataset.py)
### [`<class> FrameGroundTruth(...)`](../../perception_eval/perception_eval/dataset/ground_truth.py)

| Argument | type | Description |
| :----------- | :-----------------------: | :------------------------------------------------------------------------------------------------------ |
Expand All @@ -53,7 +53,7 @@
| `ego2map` | `Optional[numpy.ndarray]` | 4x4 matrix to transform objects with respect to base_link coordinate system map one. (Defaults to None) |
| `raw_data` | `Optional[numpy.ndarray]` | Array of pointcloud/image. (Defaults to None) |

### [`<func> load_all_datasets(...) -> List[FrameGroundTruth]`](../../perception_eval/perception_eval/common/dataset.py)
### [`<func> load_all_datasets(...) -> List[FrameGroundTruth]`](../../perception_eval/perception_eval/dataset/load.py)

| Argument | type | Description |
| :---------------- | :---------------------------------: | :------------------------------------------------ |
Expand Down
4 changes: 2 additions & 2 deletions docs/en/perception/data_structure.md
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,7 @@

### `<class> PerceptionFrameResult(...)`

For the details, see [perception_eval/evaluation/result/perception_frame_result.py](../../../perception_eval/perception_eval/evaluation/result/perception_frame_result.py)
For the details, see [perception_eval/result/perception/perception_frame_result.py](../../../perception_eval/perception_eval/result/perception/perception_frame_result.py)

- Initialization

Expand Down Expand Up @@ -118,7 +118,7 @@ For the details, see [perception_eval/evaluation/result/perception_frame_result.

Call `<func> get_object_results(...)` function to generate a set of matching pairs `List[DynamicObjectWithPerceptionResult]` from a set of Estimated objects `List[ObjectType]`and a set of GT objects `List[ObjectType]`.

For the details,see [perception_eval/evaluation/result/object_result.py](../../../perception_eval/perception_eval/evaluation/result/object_result.py)
For the details,see [perception_eval/result/perception/perception_result.py](../../../perception_eval/perception_eval/result/perception/perception_result.py)

```python
from perception_eval.evaluation.result.object_results import get_object_results
Expand Down
6 changes: 3 additions & 3 deletions docs/en/perception/design.md
Original file line number Diff line number Diff line change
Expand Up @@ -203,7 +203,7 @@

- **4. Specify parameters besides parameters of `MetricsConfig`**

- About each MetricsConfig,see [perception_eval/evaluation/metrics/config](../../../perception_eval/perception_eval/evaluation/metrics/config/)
- About each MetricsConfig,see [perception_eval/metrics/config](../../../perception_eval/perception_eval/metrics/config/)

```python
evaluation_config_dict = {
Expand Down Expand Up @@ -236,7 +236,7 @@

- An interface to determine target objects dynamically
- Specify in every frame, not in initialization of `PerceptionEvaluationManger`
- See [perception_eval/evaluation/result/perception_frame_config](../../../perception_eval/perception_eval/evaluation/result/perception_frame_config.py)
- See [perception_eval/result/perception/perception_frame_config](../../../perception_eval/perception_eval/result/perception/perception_frame_config.py)

| Arguments | type | Mandatory | Description |
| :-------------------------- | :--------------------------: | :-------------: | :-------------------------------------------------------------------------------------------------------------- |
Expand All @@ -257,7 +257,7 @@

- A class to decide Pass / Fail. For Pass/Fail decision, determine TP/FP by **Plane distance**.
- Specify in every frame, not in initializing `PerceptionEvaluationManager`.
- For the details, see [perception_eval/evaluation/result/perception_frame_config](../../../perception_eval/perception_eval/evaluation/result/perception_frame_config.py).
- For the details, see [perception_eval/result/perception/perception_frame_config](../../../perception_eval/perception_eval/result/perception/perception_frame_config.py).

| Arguments | type | Mandatory | Description |
| :------------------------ | :--------------------------: | :-------: | :--------------------------------------------------------------------------------------------------------------------- |
Expand Down
2 changes: 1 addition & 1 deletion docs/en/perception/label.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
# Object Labels

- For the details, see [perception_eval.common.label.py](../../../perception_eval/perception_eval/common/label.py)
- For the details, see [perception_eval.common.label.types.py](../../../perception_eval/perception_eval/common/label/types.py)

## `AutowareLabel`

Expand Down
16 changes: 8 additions & 8 deletions docs/en/perception/metrics.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
# Perception Evaluation Metrics

## [`<class> MetricsScore(...)`](../../../perception_eval/perception_eval/evaluation/metrics/metrics.py)
## [`<class> MetricsScore(...)`](../../../perception_eval/perception_eval/metrics/metrics.py)

- A class to evaluate each of detection/tracking/prediction task

Expand All @@ -10,10 +10,10 @@

- Initialize `detection/tracking/prediction_config` from input MetricsConfig

- [`detection_config (DetectionMetricsConfig)`](../../../perception_eval/perception_eval/evaluation/metrics/config/detection_metrics_config.py)
- [`tracking_config (TrackingMetricsConfig)`](../../../perception_eval/perception_eval/evaluation/metrics/config/tracking_metrics_config.py)
- [`prediction_config (PredictionMetricsConfig)`](../../../perception_eval/perception_eval/evaluation/metrics/config/prediction_metrics_config.py)
- [`classification_config (ClassificationMetricsConfig)`](../../../perception_eval/perception_eval/evaluation/metrics/config/classification_metrics_config.py)
- [`detection_config (DetectionMetricsConfig)`](../../../perception_eval/perception_eval/metrics/config/detection_metrics_config.py)
- [`tracking_config (TrackingMetricsConfig)`](../../../perception_eval/perception_eval/metrics/config/tracking_metrics_config.py)
- [`prediction_config (PredictionMetricsConfig)`](../../../perception_eval/perception_eval/metrics/config/prediction_metrics_config.py)
- [`classification_config (ClassificationMetricsConfig)`](../../../perception_eval/perception_eval/metrics/config/classification_metrics_config.py)

- Calculate each metrics based on each config

Expand Down Expand Up @@ -77,7 +77,7 @@

## Detection

### [`<class> Map(...)`](../../../perception_eval/perception_eval/evaluation/metrics/detection/map.py)
### [`<class> Map(...)`](../../../perception_eval/perception_eval/metrics/detection/map.py)

- A class to calculate mAP (mean Average Prevision)

Expand Down Expand Up @@ -252,7 +252,7 @@
## Matching

- A class of the way of matching estimation and GT
- For the details, see [perception_eval/evaluation/matching/object_matching.py](../../../perception_eval/perception_eval/evaluation/matching/object_matching.py)
- For the details, see [perception_eval/evaluation/matching/object_matching.py](../../../perception_eval/perception_eval/matching/object_matching.py)

| Matching Method | Value |
| ------------------ | --------------------------------------------------------------------- |
Expand Down Expand Up @@ -296,7 +296,7 @@
## TP Metrics

- A class to return TP value
- For the details,see [perception_eval/evaluation/metrics/detection/tp_metrics.py](../../../perception_eval/perception_eval/evaluation/metrics/detection/tp_metrics.py)
- For the details,see [perception_eval/evaluation/metrics/detection/tp_metrics.py](../../../perception_eval/perception_eval/metrics/detection/tp_metrics.py)

| TP Metrics | Value |
| ------------------- | ------------------------------------------ |
Expand Down
4 changes: 2 additions & 2 deletions docs/en/sensing/data_structure.md
Original file line number Diff line number Diff line change
Expand Up @@ -48,7 +48,7 @@
### `<class> SensingFrameResult(...)`

Sensing result for pointcloud in detection/non-detection area at one frame.
For the details, see [perception_eval/evaluation/sensing/sensing_frame_result.py](../../../perception_eval/perception_eval/evaluation/sensing/sensing_frame_result.py)
For the details, see [perception_eval/result/sensing/sensing_frame_result.py](../../../perception_eval/perception_eval/result/sensing/sensing_frame_result.py)

| Argument | type | Description |
| :--------------------- | :------------------: | :---------------------- |
Expand Down Expand Up @@ -76,7 +76,7 @@ Evaluate false position pointcloud detection in detection/non-detection area.
### `<class> DynamicObjectWithSensingResult(...)`

Sensing result for one GT.
For the details, see [perception_eval/evaluation/sensing/sensing_result.py](../../../perception_eval/perception_eval/evaluation/sensing/sensing_result.py)
For the details, see [perception_eval/result/sensing/sensing_result.py](../../../perception_eval/perception_eval/result/sensing/sensing_result.py)

| Argument | type | Description |
| :----------------------------- | :-------------------: | :-------------------------------------------- |
Expand Down
8 changes: 4 additions & 4 deletions docs/ja/common.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
# Common items in Perception and Sensing

## [`<class> DynamicObject(...)`](../../perception_eval/perception_eval/common/object.py)
## [`<class> DynamicObject(...)`](../../perception_eval/perception_eval/object/object3d.py)

3 次元オブジェクトのクラス.

Expand Down Expand Up @@ -29,7 +29,7 @@
| `predicted_confidence` | `Optional[float]` | 予測状態の信頼度. (Default: None) |
| `visibility` | `Optional[Visibility]` | 視認性のステータス. (Default: None) |

## [`<class> DynamicObject2D(...)`](../../perception_eval/perception_eval/common/object2d.py)
## [`<class> DynamicObject2D(...)`](../../perception_eval/perception_eval/object/object2d.py)

2 次元オブジェクトのクラス.

Expand All @@ -47,7 +47,7 @@

## Ground truth

### [`<class> FrameGroundTruth(...)`](../../perception_eval/perception_eval/common/dataset.py)
### [`<class> FrameGroundTruth(...)`](../../perception_eval/perception_eval/dataset/ground_truth.py)

フレームごとの GT オブジェクトの集合のクラス.

Expand All @@ -59,7 +59,7 @@
| `ego2map` | `Optional[numpy.ndarray]` | オブジェクトの座標系を base_link から map に変換する 4x4 行列. (Default: None) |
| `raw_data` | `Optional[numpy.ndarray]` | 点群または画像. (Default: None) |

### [`<func> load_all_datasets(...) -> List[FrameGroundTruth]`](../../perception_eval/perception_eval/common/dataset.py)
### [`<func> load_all_datasets(...) -> List[FrameGroundTruth]`](../../perception_eval/perception_eval/dataset/load.py)

データセットをロードする関数.

Expand Down
4 changes: 2 additions & 2 deletions docs/ja/perception/data_structure.md
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,7 @@

## Frame 単位でのデータ構造

### [`<class> PerceptionFrameResult(...)`](../../../perception_eval/perception_eval/evaluation/result/perception_frame_result.py)
### [`<class> PerceptionFrameResult(...)`](../../../perception_eval/perception_eval/result/perception/perception_frame_result.py)

- Initialization

Expand Down Expand Up @@ -127,7 +127,7 @@

## Object 単位でのデータ構造

### [`<class> DynamicObjectWithPerceptionResult(...)`](../../../perception_eval/perception_eval/evaluation/result/object_result.py)
### [`<class> DynamicObjectWithPerceptionResult(...)`](../../../perception_eval/perception_eval/result/perception/perception_result.py)

推定オブジェクトの集合`List[ObjectType]`と GT オブジェクトの集合`List[ObjectType]`からマッチングペアの集合`List[DynamicObjectWithPerceptionResult]`を得るには,`get_object_results()`関数を使う.

Expand Down
6 changes: 3 additions & 3 deletions docs/ja/perception/design.md
Original file line number Diff line number Diff line change
Expand Up @@ -219,7 +219,7 @@ json_result = json.dump(dict_result)

- **4. TP/FP/FN 判定用のパラメータに各 `MetricsConfig` の引数以外ものを設定した場合**

- 各 MetricsConfig は,[perception_eval/evaluation/metrics/config](../../../perception_eval/perception_eval/evaluation/metrics/config/)を参考
- 各 MetricsConfig は,[perception_eval/metrics/config](../../../perception_eval/perception_eval/metrics/config/)を参考

```python
evaluation_config_dict = {
Expand Down Expand Up @@ -248,7 +248,7 @@ json_result = json.dump(dict_result)
Usage: {'plane_distance_thresholds', 'iou_3d_thresholds', 'center_distance_thresholds', 'target_labels', 'iou_bev_thresholds'}
```

### [`<class> CriticalObjectFilterConfig(...)`](../../../perception_eval/perception_eval/evaluation/result/perception_frame_config.py)
### [`<class> CriticalObjectFilterConfig(...)`](../../../perception_eval/perception_eval/result/perception/perception_frame_config.py)

- 注目物体を動的決定するためのインターフェイス.
- `PerceptionEvaluationManger`の初期化時ではなく,各フレーム毎(=callback)に指定する.
Expand All @@ -268,7 +268,7 @@ json_result = json.dump(dict_result)

\* **max_x/y_position**,**max/min_distance**についてはどちらか片方のみ指定する必要がある.

### [`<class> PerceptionPassFailConfig(...)`](../../../perception_eval/perception_eval/evaluation/result/perception_frame_config.py)
### [`<class> PerceptionPassFailConfig(...)`](../../../perception_eval/perception_eval/result/perception/perception_frame_config.py)

- Pass / Fail を決めるためのパラメータ. Pass/Fail の判定については,**Plane distance**によって TP/FP の判定を行う.
- `PerceptionEvaluationManger`の初期化時ではなく,各フレーム毎(=callback)に指定する.
Expand Down
2 changes: 1 addition & 1 deletion docs/ja/perception/label.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
# オブジェクト ラベル

- 詳細は[perception_eval.common.label.py](../../../perception_eval/perception_eval/common/label.py)を参照
- 詳細は[perception_eval.common.label.types.py](../../../perception_eval/perception_eval/common/label/types.py)を参照

## Autoware Label

Expand Down
14 changes: 7 additions & 7 deletions docs/ja/perception/metrics.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
# Perception Evaluation Metrics

## [`<class> MetricsScore(...)`](../../../perception_eval/perception_eval/evaluation/metrics/metrics.py)
## [`<class> MetricsScore(...)`](../../../perception_eval/perception_eval/metrics/metrics.py)

- detection/tracking/prediction の各評価指標を実行する class

Expand All @@ -10,9 +10,9 @@

- 入力された MetricsScoreConfig から,`detection/tracking/prediction_config`を生成

- [`detection_config (DetectionMetricsConfig)`](../../../perception_eval/perception_eval/evaluation/metrics/config/detection_metrics_config.py)
- [`tracking_config (TrackingMetricsConfig)`](../../../perception_eval/perception_eval/evaluation/metrics/config/tracking_metrics_config.py)
- [`prediction_config (PredictionMetricsConfig)`](../../../perception_eval/perception_eval/evaluation/metrics/config/prediction_metrics_config.py)
- [`detection_config (DetectionMetricsConfig)`](../../../perception_eval/perception_eval/metrics/config/detection_metrics_config.py)
- [`tracking_config (TrackingMetricsConfig)`](../../../perception_eval/perception_eval/metrics/config/tracking_metrics_config.py)
- [`prediction_config (PredictionMetricsConfig)`](../../../perception_eval/perception_eval/metrics/config/prediction_metrics_config.py)

- 各 config をもとにそれぞれの Metrics が計算される.

Expand Down Expand Up @@ -76,7 +76,7 @@

## Detection

### [`<class> Map(...)`](../../../perception_eval/perception_eval/evaluation/metrics/detection/map.py)
### [`<class> Map(...)`](../../../perception_eval/perception_eval/metrics/detection/map.py)

- mAP (mean Average Precision) のスコア計算を行う class.

Expand Down Expand Up @@ -249,7 +249,7 @@
## Matching

- 予測 object と Ground Truth のマッチング方式の class
- 詳細は,[perception_eval/evaluation/matching/object_matching.py](../../../perception_eval/perception_eval/evaluation/matching/object_matching.py)を参照
- 詳細は,[perception_eval/evaluation/matching/object_matching.py](../../../perception_eval/perception_eval/matching/object_matching.py)を参照

| Matching Method | Value |
| ------------------ | --------------------------------------------------------------------- |
Expand Down Expand Up @@ -295,7 +295,7 @@
## TP Metrics

- True Positive 時の値を返す class
- 詳細は,[perception_eval/evaluation/metrics/detection/tp_metrics.py](../../../perception_eval/perception_eval/evaluation/metrics/detection/tp_metrics.py)を参照
- 詳細は,[perception_eval/evaluation/metrics/detection/tp_metrics.py](../../../perception_eval/perception_eval/metrics/detection/tp_metrics.py)を参照

| TP Metrics | Value |
| ------------------- | ----------------------------- |
Expand Down
4 changes: 2 additions & 2 deletions docs/ja/sensing/data_structure.md
Original file line number Diff line number Diff line change
Expand Up @@ -50,7 +50,7 @@

### SensingFrameResult

1 frame に対しての検出・非検出対象エリアに対する点群のセンシング結果[(参照)](../../../perception_eval/perception_eval/evaluation/sensing/sensing_frame_result.py)
1 frame に対しての検出・非検出対象エリアに対する点群のセンシング結果[(参照)](../../../perception_eval/perception_eval/result/sensing/sensing_frame_result.py)

| Argument | type | Description |
| :--------------------- | :------------------: | :------------- |
Expand All @@ -76,7 +76,7 @@

### DynamicObjectWithSensingResult

1 つの GT オブジェクト(アノテーションされた bounding box)に対しての結果[(参照)](../../../perception_eval/perception_eval/evaluation/sensing/sensing_result.py)
1 つの GT オブジェクト(アノテーションされた bounding box)に対しての結果[(参照)](../../../perception_eval/perception_eval/result/sensing/sensing_result.py)

| Argument | type | Description |
| :----------------------------- | :-------------------: | :----------------------------- |
Expand Down
Loading
Loading