Create Annotator() class (#4591)
* Add Annotator() class * Download Arial * 2x for loop * Cleanup * tuple 2 list * max_size=1920 * bold logging results to * tolist() * im = annotator.im * PIL save in detect.py * Smart asarray in detect.py * revert to cv2.imwrite * Cleanup * Return result asarray * Add `Profile()` profiler * CamelCase Timeout * Resize after mosaic * pillow>=8.0.0 * daemon imwrite * Add cv2 support * Remove plot_wh_methods and plot_one_box * pil=False for hubconf.py annotations * im.shape bug fix * colorstr common.py * join daemons * Update t.daemon * Removed daemon saving
This commit is contained in:
1 parent
7b35971ba5
commit
de44376d1b
6 files changed
+100
-103
No files matched your search
+3
-2
@@ -122,9 +122,10 @@ def is_pip():
|
||||
return 'site-packages' in Path(__file__).absolute().parts
|
||||
|
||||
|
||||
def is_ascii(str=''):
|
||||
def is_ascii(s=''):
|
||||
# Is string composed of all ASCII (no UTF) characters?
|
||||
return len(str.encode().decode('ascii', 'ignore')) == len(str)
|
||||
s = str(s) # convert to str() in case of None, etc.
|
||||
return len(s.encode().decode('ascii', 'ignore')) == len(s)
|
||||
|
||||
|
||||
def emojis(str=''):
|
||||
|
||||
Reference in new issue
Block a user