Batch dataset tag editor tool #942
DuskXi
started this conversation in
Show and tell
Replies: 1 comment
-
看起来好用,谢谢。 |
Beta Was this translation helpful? Give feedback.
0 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
LabelEditor: Repository
Descibe:
A dataset editor that supports batch tag editing
release version does not require nodejs environment, only python environment
Just need to download and unzip
Execute
pip install -r requirements.txt
to get readypython main.py
to start the editorCommand line arguments:
--host: IP address to listen to (default 127.0.0.1)
--port: listen to the port (default 5000)
--dest: data directory (empty will bring up a popup window for selection)
Stabl diffusion Webui actually has a UI extension that can edit data, but because that extension cannot be added or modified in bulk, it is not friendly for editing larger data sets, so I wrote this thing
Feature:
As shown in the picture, this tool is divided into two main parts
One part is the collapsible Tag editor
The other part is the main filter, which supports filtering data according to the selected tag, and also supports reverse selection.
Main Filter
Please note that the thing called "Reverse filter", all your selected tag will appear a switch over there, control the state of the switch can control the tag filtering is forward or reverse respectively.
For example: you selected tag: a and tag: b, you will be tag: b reverse filter open, the data on the left will only be displayed in line with a and not b (if the Filter logic method dialed to And mode)
Tag Editor
When you have Tag Edit's collapsed basket open, you can select this data when you click on the card (including the image) on the left side where the image is located. A small filter will appear under Tag Edit. This filter will only show the tag of the image you selected, or you can collapse it if you think this is blocking the view.
The plus sign is the button to add the tag to the bulk edit mode. Of course, if you want to add some new tags that are not in the dataset, you can also add them by clicking on the plus sign at the right side of the checkbox below.
When you have selected some images and the action checkbox is selected for the tag you want to operate on. Below the checkboxes some buttons will appear.
As in the figure, add label to the selected image, remove label to the selected image, as well as a two-way arrow and a slider, the first two buttons must not need to explain the meaning of those two arrows means to move the tag forward/backward (because some data sets have sequential meaning of the tag), and that slider is to move the tag to the relative position (from 0% to 100%), these button actions will only be performed for the data you selected.
Then there are two buttons at the top, one button is the clear button is responsible for clearing the selected data, while the other button is responsible for the inverse selection, that is, select all the data that are not selected in the data displayed by the filter, so when there is no data when you press this button is equal to the full selection.
Save:
After you have made changes to the dataset, a block-level button will appear in the upper right corner for you to save the data, a modal box will pop up which shows all the changes, scroll to the bottom, click OK, and it will save to the original path.
Localization (vue-i18n):
Now support English and Chinese, no plan to support other languages for the time being
Beta Was this translation helpful? Give feedback.
All reactions