프로젝트

일반

사용자정보

개정판 ca84c19d

IDca84c19d0c3ff7e3200dc2b0d1b7482feace5826
상위 dd6d4de9
하위 c72c9442

함의성이(가) 4년 이상 전에 추가함

issue #1366: training test

차이점 보기:

DTI_PID/WebServer/symbol_training/src/doftech_dataset.py
54 54
                self.anno_list.extend(new_label_list)
55 55

  
56 56
    def rescale_func(self, img_list, anno_list):
57
        scale_array = [0.7, 0.8, 0.9, 1.0, 1.1, 1.2, 1.3]
57
        #scale_array = [0.7, 0.8, 0.9, 1.0, 1.1, 1.2, 1.3]
58
        scale_array = [0.7, 0.8, 0.9, 1.0, 1.1, 1.2, 1.3, 1.0, 1.0, 1.0]
58 59

  
59 60
        new_image_list = []
60 61
        new_label_list = []
......
67 68
                new_label = []
68 69
                if obj[0] - cut_range > 0 and obj[1] - cut_range > 0 and obj[2] + cut_range > 0 and obj[
69 70
                    3] + cut_range > 0:
70
                    random_int = random.randint(0, 6)
71
                    random_int = random.randint(0, 9)
71 72

  
72 73
                    cut_xmin = obj[0] - cut_range
73 74
                    cut_ymin = obj[1] - cut_range
......
130 131
        origin_image = cv2.cvtColor(origin_image, cv2.COLOR_BGR2RGB)
131 132
        if self.is_training:
132 133
            if self.use_rotation:
133
                angle_array = [0,30,45,60,90,120,135,150,180,210,240,255,270,300,330,345,360]
134
                random_int = random.randint(0,16)
134
                #angle_array = [0,30,45,60,90,120,135,150,180,210,240,255,270,300,330,345,360]
135
                angle_array = [0,30,45,60,90,120,135,150,180,210,240,255,270,300,330,345, 0,90,180,270, 0,90,180,270, 0,90,180,270,]
136
                random_int = random.randint(0,27)
135 137
                transformations = Compose([Rotate(angle_array[random_int], self.image_size)])
136 138
            else :
137 139
                transformations = Compose([Resize(self.image_size)])

내보내기 Unified diff

클립보드 이미지 추가 (최대 크기: 500 MB)