In some cases, arithmetic results (in particular from division) on zoom
levels return floats; however, the PyQt API requires int values to
function correctly. Therefore, explicit conversion to int or integer
division has been added for these cases.
A behavior bug causing sudden crashes was fixed. When a rectangular box
is dragged with the right mouse button, but the left mouse button is
touched prior to release of the right mouse button, the program
crashed. The root cause seems to be that this deselects the dragged
object so it is no longer available (i.e. `self.canvas.selected_shape is
None`). The new behavior does nothing / cancels the operation if this
occurs.
Added a shortcut for switching file format (CTRL+Y) since I often use
this functionality.
* Introduced two new attributes of MainWindow:
cur_img_idx - Index of current image in m_img_list.
img_count - Length of m_img_list.
* Implement counter_str method to get string representation of counter.
* Appended counter to window title.
* Based image switching logic on counter instead of local variables.
* Removed useless condition.
current_index = self.m_img_list.index(ustr(item.text()))
if current_index < len(self.m_img_list):
list.index will raise ValueError if item doesn't exist.
* Fix incorrect save dir path handling for ML format.
Save dir path was split by incorrect os.dependent separator '/'
which was the cause of labels being saved to parent folder.
* Implement path normalization for command arguments.
Renamed 'predefined_classes_file' parameter to 'class_file'.
* rename local variables in main file
* additional renaming of functions and variables
* Rename main file functions
* Rename functions and variables in canvas.py
* Rename functions and locals for remaining files
* Rename non-Qt derived class' members
* Rename members of Qt-derived classes
* Fix paint label issue
* adds createMl reader & writer class
* adds getFormatMeta function to support more than two save_format
* adds CreateML read & write support
* adds format CreateML icon
* fixes negative height/width
* removes type hints
* fixes coordinate calculation
* adds unit test
* removes typehint
* Add previous bounding boxes code
* Create method to avoid repeated code
* Fix text in the action copyprevbounding
* Add description for different languages
Add Silent option for openDirDialog to facilitate opening a directory at start up
if the filePath provided is a directory without opening the file selector UI.
The scenario is:
1. Open an image
2. Delete all bounding boxes
3. Select "Edit Label".
* labelImg.py
(editLabel): Avoid crash zhen there's no currently selected item.