ONNX compatibility updates
This commit is contained in:
parent
d1951c1868
commit
cc018c73ad
|
@ -22,9 +22,9 @@ def load_classes(path):
|
||||||
"""
|
"""
|
||||||
Loads class labels at 'path'
|
Loads class labels at 'path'
|
||||||
"""
|
"""
|
||||||
fp = open(path, 'r')
|
fp = open('data/coco.names', 'r')
|
||||||
names = fp.read().split('\n')[:-1]
|
names = fp.read().split('\n')
|
||||||
return names
|
return list(filter(None, names)) # filter removes empty strings (such as last line)
|
||||||
|
|
||||||
|
|
||||||
def model_info(model): # Plots a line-by-line description of a PyTorch model
|
def model_info(model): # Plots a line-by-line description of a PyTorch model
|
||||||
|
|
Loading…
Reference in New Issue