Save the colormap to the output path. Args: out_file (str): Output path for saving the colormap.
(self, out_file)
| 891 | self.visible_label = set() |
| 892 | |
| 893 | def save(self, out_file): |
| 894 | """Save the colormap to the output path. |
| 895 | |
| 896 | Args: |
| 897 | out_file (str): Output path for saving the colormap. |
| 898 | """ |
| 899 | with open(out_file, 'w') as f: |
| 900 | for key, value in self.color_map.items(): |
| 901 | print(key, value, file=f) |
| 902 | |
| 903 | def get_color(self, label): |
| 904 | """Get the color of a given category label. |
nothing calls this directly
no outgoing calls
no test coverage detected