# DL_python_script **Repository Path**: zjchenchujie/DL_python_script ## Basic Information - **Project Name**: DL_python_script - **Description**: Some useful python scripts for data preprocess in Deep-Learning - **Primary Language**: Python - **License**: Not specified - **Default Branch**: master - **Homepage**: None - **GVP Project**: No ## Statistics - **Stars**: 0 - **Forks**: 0 - **Created**: 2019-11-14 - **Last Updated**: 2020-12-19 ## Categories & Tags **Categories**: Uncategorized **Tags**: None ## README # Data preprocess utils for deep learning - [image_xml_matchment.py]() - checking matchment of image (JPEGImages) and xml file (Annotations) in voc dataset. image or xml files that don't have a correspond match will be moved to the directory named 'unmatched'. - [image_area_cover.py]() - a fixed area of image will be covered with black background. If there were any targets included in this area, the targets won't be covered. - [generate_train_test_filelist.py]() - generate train and test filelist in ImageSet/Main directory. Both voc format yolo format filelist will be generated. - [convert_voc_xml_to_yolo_label.py]() - Convert voc xml annotations to yolo text labels in directory 'labels'. - [check_xml.py]() - Check if the boxes in xml were valid. - [copy_files.py]() - Copy files from one directory to another. - [eval_ap_pr.py]() - Evaluate average precision and precision. - [extract_video_frames.py]() - Extract video frames. - [classification_accuracy.py]() - classification accuracy - [voc2coco.py]() - voc annotation (xml) to coco annotation (json). - [coco2voc.py]() - coco annotation (json) to voc annotation (xml). - [draw_anchors.py]() - Draw anchors distribution. - [k_means_yolov3_multi.py]() - generate yolov3 anchors by k-means. - [generate_vocxml_from_det.py]() - generate voc xml files from detection results. - [append_object_in_xml.py]() - append object in xml. - [delete_marked_xml_img.py]() - Delete xml marked with delete, ignore or empty. - [draw_voc_rectangle.py]() - Draw object rectangles on image and save this image in `img_with_rectangle` directory. - [generate_subset.py]() - select a subset in dataset. ###data augmentation - [crop.py]() - crop images. - [flip.py]() - flip images, vertically, mirror, or both. - [resize.py]() - resize images. If fixed_ratio is True, then image should be kept original ratio with padding. - [rotate.py]() - rotate images. - [sample_augmentation_mosaic.py]() - mosaic image. doesn't work well currently.