Explorar el Código

Use visible colors as default for auto_shape_color

Kentaro Wada hace 5 años
padre
commit
8b5b4ea410

+ 1 - 1
examples/instance_segmentation/README.md

@@ -3,7 +3,7 @@
 ## Annotation
 
 ```bash
-labelme data_annotated --labels labels.txt --nodata --validatelabel exact
+labelme data_annotated --labels labels.txt --nodata --validatelabel exact --config '{shift_auto_shape_color: -2}'
 labelme data_annotated --labels labels.txt --nodata --labelflags '{.*: [occluded, truncated], person-\d+: [male]}'
 ```
 

+ 1 - 1
examples/semantic_segmentation/README.md

@@ -3,7 +3,7 @@
 ## Annotation
 
 ```bash
-labelme data_annotated --labels labels.txt --nodata --validatelabel exact
+labelme data_annotated --labels labels.txt --nodata --validatelabel exact --config '{shift_auto_shape_color: -2}'
 ```
 
 ![](.readme/annotation.jpg)

+ 1 - 1
examples/video_annotation/README.md

@@ -4,7 +4,7 @@
 ## Annotation
 
 ```bash
-labelme data_annotated --labels labels.txt --nodata --keep-prev
+labelme data_annotated --labels labels.txt --nodata --keep-prev --config '{shift_auto_shape_color: -2}'
 ```
 
 <img src=".readme/00000100.jpg" width="49%" /> <img src=".readme/00000101.jpg" width="49%" />

+ 1 - 1
labelme/app.py

@@ -993,7 +993,7 @@ class MainWindow(QtWidgets.QMainWindow):
 
     def _get_rgb_by_label(self, label):
         item = self.uniqLabelList.findItems(label, Qt.MatchExactly)[0]
-        label_id = self.uniqLabelList.indexFromItem(item).row() - 1
+        label_id = self.uniqLabelList.indexFromItem(item).row() + 1
         label_id += self._config['shift_auto_shape_color']
         return LABEL_COLORMAP[label_id % len(LABEL_COLORMAP)]