Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Changing the item's class #161

Open
evgevd opened this issue May 10, 2018 · 1 comment
Open

Changing the item's class #161

evgevd opened this issue May 10, 2018 · 1 comment

Comments

@evgevd
Copy link

evgevd commented May 10, 2018

from
to

I use Sloth in correcting a predicted labels for following using corrected labels in training. Prediction model is underlearned so I often ought to change the item's classes. Is it possible to change the class without deleting an exciting rectangle?

@evgevd
Copy link
Author

evgevd commented May 16, 2018

Solved (I guess):
I added code to keyPressEvent in annotationscene.py:

`            if event.key() == Qt.Key_Y:
                if  self.selectedItems()[-1]._model_item._dict['class']=='s':
                    self.selectedItems()[-1]._model_item._dict['class']='m'
                    self.selectedItems()[-1].setColor(Qt.red)
                elif self.selectedItems()[-1]._model_item._dict['class']=='m':
                    self.selectedItems()[-1]._model_item._dict['class']='s'
                    self.selectedItems()[-1].setColor(Qt.green)`

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant