kitcar_ml.utils package
Subpackages
- kitcar_ml.utils.data package
- Subpackages
- Submodules
- kitcar_ml.utils.data.analyse_bbox_dataset module
AnalyseBBoxDatasetAnalyseBBoxDataset.statistical_height()AnalyseBBoxDataset.statistical_width()AnalyseBBoxDataset.statistical_aspect_ratio()AnalyseBBoxDataset.img_sizeAnalyseBBoxDataset.bboxes_by_class()AnalyseBBoxDataset.draw_class_distribution()AnalyseBBoxDataset.scatter_plot()AnalyseBBoxDataset.heatmap_plot()AnalyseBBoxDataset.basic_info()AnalyseBBoxDataset.report()AnalyseBBoxDataset.classesAnalyseBBoxDataset.labels
- kitcar_ml.utils.data.bbox_dataset module
- kitcar_ml.utils.data.image_folder module
- kitcar_ml.utils.data.import_kitcar_xml_labels module
- kitcar_ml.utils.data.import_label_studio_labels module
- kitcar_ml.utils.data.labeled_dataset module
LabeledDatasetLabeledDataset.attributesLabeledDataset.classesLabeledDataset.labelsLabeledDataset._base_pathLabeledDataset._cacheLabeledDataset.available_filesLabeledDataset.cache()LabeledDataset.filter_labels()LabeledDataset.append_label()LabeledDataset.save_as_yaml()LabeledDataset.make_ids_continuous()LabeledDataset.replace_id()LabeledDataset.split()LabeledDataset.from_yaml()LabeledDataset.split_file()LabeledDataset.filter_file()LabeledDataset.adjust_classes()LabeledDataset.prune_classes()LabeledDataset.adjust_attributes()LabeledDataset.merge_datasets()
- kitcar_ml.utils.data.unlabeled_dataset module
- kitcar_ml.utils.data.visual_labeled_dataset module
- Module contents
- kitcar_ml.utils.data_generation package
- Subpackages
- Submodules
- kitcar_ml.utils.data_generation.augmentation_utils module
- kitcar_ml.utils.data_generation.data_generation_tool module
- kitcar_ml.utils.data_generation.generation_config module
GenerationConfigurationGenerationConfiguration.supersamplingGenerationConfiguration.max_number_of_objectsGenerationConfiguration.min_distanceGenerationConfiguration.max_distanceGenerationConfiguration.angle_x_maxGenerationConfiguration.angle_z_maxGenerationConfiguration.noise_sigmaGenerationConfiguration.noise_meanGenerationConfiguration.gauss_blur_allGenerationConfiguration.gauss_blur_signGenerationConfiguration.overlay_tresholdGenerationConfiguration.sigma_allGenerationConfiguration.mean_allGenerationConfiguration.crop_boxGenerationConfiguration.bbox_min_visibilityGenerationConfiguration.bbox_min_areaGenerationConfiguration.hor_motion_blur_size
- kitcar_ml.utils.data_generation.object_generation_utils module
- kitcar_ml.utils.data_generation.sample_generator module
- kitcar_ml.utils.data_generation.utils module
- Module contents
- kitcar_ml.utils.evaluation package
- Subpackages
- Submodules
- kitcar_ml.utils.evaluation.evaluator module
- kitcar_ml.utils.evaluation.example module
- kitcar_ml.utils.evaluation.interpolation_evaluator module
InterpolationResulthead()InterpolationEvaluatorInterpolationEvaluator._class_label_string()InterpolationEvaluator._abc_implInterpolationEvaluator.calculate_ap_every_point()InterpolationEvaluator.calculate_interpolation_points()InterpolationEvaluator.calculate_ap_11_point_interp()InterpolationEvaluator.calculate_sorted_prefix_sum()InterpolationEvaluator.calculate_metrics()InterpolationEvaluator.calculate_class_results()InterpolationEvaluator.calculate_results()InterpolationEvaluator.plot_precision_recall_curves()
- kitcar_ml.utils.evaluation.simple_evaluator module
- kitcar_ml.utils.evaluation.tutorial module
- Module contents
- kitcar_ml.utils.models package
- Submodules
- kitcar_ml.utils.models.advanced_sequential module
AdvancedSequentialAdvancedSequential.forward()AdvancedSequential._modulesAdvancedSequential.trainingAdvancedSequential._parametersAdvancedSequential._buffersAdvancedSequential._non_persistent_buffers_setAdvancedSequential._backward_hooksAdvancedSequential._is_full_backward_hookAdvancedSequential._forward_hooksAdvancedSequential._forward_pre_hooksAdvancedSequential._state_dict_hooksAdvancedSequential._load_state_dict_pre_hooksAdvancedSequential._load_state_dict_post_hooks
- kitcar_ml.utils.models.normalize module
NormalizeNormalize.forward()Normalize.trainingNormalize._parametersNormalize._buffersNormalize._non_persistent_buffers_setNormalize._backward_hooksNormalize._is_full_backward_hookNormalize._forward_hooksNormalize._forward_pre_hooksNormalize._state_dict_hooksNormalize._load_state_dict_pre_hooksNormalize._load_state_dict_post_hooksNormalize._modules
- Module contents
- kitcar_ml.utils.pre_processing package
- kitcar_ml.utils.test package
Submodules
kitcar_ml.utils.benchmark module
kitcar_ml.utils.bounding_box module
Classes:
|
Class representing a bounding box. |
- class BoundingBox(x1: float, y1: float, x2: float, y2: float, class_label: str, confidence: Optional[float] = None)[source]
Bases:
objectClass representing a bounding box.
The four coordinates are the absolute coordinates in the image.
Attributes:
Lower inclusive bound of the bounding box.
Left inclusive bound of the bounding box.
Upper inclusive bound of the bounding box.
Right inclusive bound of the bounding box.
Class that the model gave the bounding box.
Confidence of the model, that this bounding box is correct.
The area of the bounding box.
Methods:
shift_and_scale(shift, scale)Shift and scale the bounding box :param shift: Vector that translates the bounding box.
create_bounding_boxes(boxes, labels[, scores])Create multiple bounding boxes.
iou(box_a, box_b)Calculate the IOU(Intersection over Union) of two bounding boxes.
union_area(box_a, box_b[, intersection_area])Calculate the union area of two bounding boxes.
intersection_area(box_a, box_b)Calculate the intersection area of two bounding boxes.
- x1: float
Lower inclusive bound of the bounding box.
- y1: float
Left inclusive bound of the bounding box.
- x2: float
Upper inclusive bound of the bounding box.
- y2: float
Right inclusive bound of the bounding box.
- class_label: str
Class that the model gave the bounding box.
- confidence: float = None
Confidence of the model, that this bounding box is correct.
- property coordinates
- property center_point: Tuple[float, float]
- property width: float
- property height: float
- property area
The area of the bounding box.
(width + 1)x(height + 1), because the boundaries are inside the bounding box.
- shift_and_scale(shift, scale)[source]
Shift and scale the bounding box :param shift: Vector that translates the bounding box. :param scale: Vector that increases or decreases the bounding box.
- Returns
The scaled and shifted bounding box coordinates.
- classmethod create_bounding_boxes(boxes: Iterable[Iterable[int]], labels: Iterable[str], scores: Optional[Iterable[float]] = None)[source]
Create multiple bounding boxes.
- classmethod iou(box_a: BoundingBox, box_b: BoundingBox) float[source]
Calculate the IOU(Intersection over Union) of two bounding boxes.
- classmethod union_area(box_a: BoundingBox, box_b: BoundingBox, intersection_area=None) float[source]
Calculate the union area of two bounding boxes.
- static intersection_area(box_a: BoundingBox, box_b: BoundingBox) float[source]
Calculate the intersection area of two bounding boxes.
kitcar_ml.utils.visualization module
Functions:
|
Draw labeled boxes on an image. |
|
Show the image along with the specified boxes around detected objects. |
- show_labeled_image(image: Union[Image, ndarray, Tensor], boxes: Optional[Tensor] = None, labels: Optional[List[str]] = None, save_path: Optional[str] = None, show: bool = False)[source]
Show the image along with the specified boxes around detected objects.
- Parameters
image – The image that is displayed.
boxes – The bounding boxes on the image.
labels – A list of labels for each bounding box.
save_path – The path to the folder where the image should be saved.
show – If the image should be shown interactively.
Module contents
Utils Package for KITcar-Machine-Learning.