成功解决TypeError: Scalar value for argument 'color' is not numeric

简介: 成功解决TypeError: Scalar value for argument 'color' is not numeric

解决问题


TypeError: Scalar value for argument 'color' is not numeric





解决思路


类型错误:参数“color”的标量值不是数字





解决方法


颜色参数不是不是数字类型可知,该函数需要颜色是数值型而不是类似red的字符串型,改为颜色对应的RGB数值即可!

image.png





相关文章
|
6月前
|
数据处理 开发者 Python
【Python】已解决:ValueError: Length mismatch: Expected axis has 5 elements, new values have 4 elements
【Python】已解决:ValueError: Length mismatch: Expected axis has 5 elements, new values have 4 elements
452 9
|
6月前
|
机器学习/深度学习 Python
【Python】已解决TypeError: init() got an unexpected keyword argument ‘threshold’
【Python】已解决TypeError: init() got an unexpected keyword argument ‘threshold’
315 0
|
算法框架/工具
Keras报错:TypeError: (‘Keyword argument not understood:‘, ‘offset‘)
Keras报错:TypeError: (‘Keyword argument not understood:‘, ‘offset‘)
216 0
|
机器学习/深度学习 PyTorch 算法框架/工具
解决Pytorch中RuntimeError: expected scalar type Double but found Float
解决Pytorch中RuntimeError: expected scalar type Double but found Float
2761 0
error: implicit declaration of function ‘RAND_egd’ [-Werror=implicit-function-declaration]
error: implicit declaration of function ‘RAND_egd’ [-Werror=implicit-function-declaration]
137 0
|
Python
TypeError: img is not a numpy array, neither a scalar
TypeError: img is not a numpy array, neither a scalar
295 0
|
Python
成功解决TypeError: concat() got an unexpected keyword argument ‘join_axes‘
成功解决TypeError: concat() got an unexpected keyword argument ‘join_axes‘
成功解决ValueError: Dimension 1 in both shapes must be equal, but are 1034 and 1024. Shapes are [100,103
成功解决ValueError: Dimension 1 in both shapes must be equal, but are 1034 and 1024. Shapes are [100,103