原文:yolov8 分类太阳能板 - 知乎 (zhihu.com)
1、数据集
https://github.com/zae-bayern/elpv-datasetgithub.com/zae-bayern/elpv-dataset
2、数据分析
import matplotlib.pyplot as plt
import ostrain_dir = "./images"
valid_extensions=('.jpg', '.png', '.jpeg')categories = ['poly', 'mono']
category_count = {}for each_category in categories:folder_path = os.path.join(train_dir, each_category)valid_images = [file for file in os.listdir(folder_path) if file.lower().endswith(valid_extensions)]category_count[each_category] = len(valid_images)fig, ax = plt.subplots(figsize