open_model_zoo icon indicating copy to clipboard operation
open_model_zoo copied to clipboard

FutureWarning: elementwise comparison failed; returning scalar instead, but in the future will perform elementwise comparison

Open kmanisai opened this issue 3 years ago • 0 comments

Hi I am running colorization demo with colorization-siggraph.xml. python colorization_demo.py -i ./download.jpg -m ./model/colorization-siggraph.xml -o output%03d.jpg_ I am getting this output, i am not getting why this error is coming.

[ INFO ] OpenVINO Runtime [ INFO ] build: 2022.1.0-7019-cdb9bec7210-releases/2022/1 [ INFO ] Reading model model/colorization-siggraph.xml [ INFO ] The model model/colorization-siggraph.xml is loaded to CPU [ DEBUG ] Loaded backend agg version unknown. [ DEBUG ] findfont: Matching sans-serif:style=normal:variant=normal:weight=normal:stretch=normal:size=10.0. [ DEBUG ] findfont: score(FontEntry(fname='/root/.local/lib/python3.8/site-packages/matplotlib/mpl-data/fonts/ttf/STIXNonUni.ttf', name='STIXNonUnicode', style='normal', variant='normal', weight=400, stretch='normal', size='scalable')) = 10.05 [ DEBUG ] findfont: score(FontEntry(fname='/root/.local/lib/python3.8/site-packages/matplotlib/mpl-data/fonts/ttf/DejaVuSansMono-Bold.ttf', name='DejaVu Sans Mono', style='normal', variant='normal', weight=700, stretch='normal', size='scalable')) = 10.335 [ DEBUG ] findfont: score(FontEntry(fname='/root/.local/lib/python3.8/site-packages/matplotlib/mpl-data/fonts/ttf/STIXNonUniBol.ttf', name='STIXNonUnicode', style='normal', variant='normal', weight=700, stretch='normal', size='scalable')) = 10.335 [ DEBUG ] findfont: score(FontEntry(fname='/root/.local/lib/python3.8/site-packages/matplotlib/mpl-data/fonts/ttf/DejaVuSans-BoldOblique.ttf', name='DejaVu Sans', style='oblique', variant='normal', weight=700, stretch='normal', size='scalable')) = 1.335 [ DEBUG ] findfont: score(FontEntry(fname='/root/.local/lib/python3.8/site-packages/matplotlib/mpl-data/fonts/ttf/STIXSizOneSymReg.ttf', name='STIXSizeOneSym', style='normal', variant='normal', weight=400, stretch='normal', size='scalable')) = 10.05 [ DEBUG ] findfont: score(FontEntry(fname='/root/.local/lib/python3.8/site-packages/matplotlib/mpl-data/fonts/ttf/STIXNonUniIta.ttf', name='STIXNonUnicode', style='italic', variant='normal', weight=400, stretch='normal', size='scalable')) = 11.05 [ DEBUG ] findfont: score(FontEntry(fname='/root/.local/lib/python3.8/site-packages/matplotlib/mpl-data/fonts/ttf/DejaVuSans-Bold.ttf', name='DejaVu Sans', style='normal', variant='normal', weight=700, stretch='normal', size='scalable')) = 0.33499999999999996 [ DEBUG ] findfont: score(FontEntry(fname='/root/.local/lib/python3.8/site-packages/matplotlib/mpl-data/fonts/ttf/DejaVuSans-Oblique.ttf', name='DejaVu Sans', style='oblique', variant='normal', weight=400, stretch='normal', size='scalable')) = 1.05 [ DEBUG ] findfont: score(FontEntry(fname='/root/.local/lib/python3.8/site-packages/matplotlib/mpl-data/fonts/ttf/DejaVuSerif-BoldItalic.ttf', name='DejaVu Serif', style='italic', variant='normal', weight=700, stretch='normal', size='scalable')) = 11.335 [ DEBUG ] findfont: score(FontEntry(fname='/root/.local/lib/python3.8/site-packages/matplotlib/mpl-data/fonts/ttf/cmtt10.ttf', name='cmtt10', style='normal', variant='normal', weight=400, stretch='normal', size='scalable')) = 10.05 [ DEBUG ] findfont: score(FontEntry(fname='/root/.local/lib/python3.8/site-packages/matplotlib/mpl-data/fonts/ttf/DejaVuSansMono-BoldOblique.ttf', name='DejaVu Sans Mono', style='oblique', variant='normal', weight=700, stretch='normal', size='scalable')) = 11.335 [ DEBUG ] findfont: score(FontEntry(fname='/root/.local/lib/python3.8/site-packages/matplotlib/mpl-data/fonts/ttf/DejaVuSansMono-Oblique.ttf', name='DejaVu Sans Mono', style='oblique', variant='normal', weight=400, stretch='normal', size='scalable')) = 11.05 [ DEBUG ] findfont: score(FontEntry(fname='/root/.local/lib/python3.8/site-packages/matplotlib/mpl-data/fonts/ttf/STIXNonUniBolIta.ttf', name='STIXNonUnicode', style='italic', variant='normal', weight=700, stretch='normal', size='scalable')) = 11.335 [ DEBUG ] findfont: score(FontEntry(fname='/root/.local/lib/python3.8/site-packages/matplotlib/mpl-data/fonts/ttf/DejaVuSerif.ttf', name='DejaVu Serif', style='normal', variant='normal', weight=400, stretch='normal', size='scalable')) = 10.05 [ DEBUG ] findfont: score(FontEntry(fname='/root/.local/lib/python3.8/site-packages/matplotlib/mpl-data/fonts/ttf/STIXSizThreeSymReg.ttf', name='STIXSizeThreeSym', style='normal', variant='normal', weight=400, stretch='normal', size='scalable')) = 10.05 [ DEBUG ] findfont: score(FontEntry(fname='/root/.local/lib/python3.8/site-packages/matplotlib/mpl-data/fonts/ttf/DejaVuSerifDisplay.ttf', name='DejaVu Serif Display', style='normal', variant='normal', weight=400, stretch='normal', size='scalable')) = 10.05 [ DEBUG ] findfont: score(FontEntry(fname='/root/.local/lib/python3.8/site-packages/matplotlib/mpl-data/fonts/ttf/STIXSizTwoSymReg.ttf', name='STIXSizeTwoSym', style='normal', variant='normal', weight=400, stretch='normal', size='scalable')) = 10.05 [ DEBUG ] findfont: score(FontEntry(fname='/root/.local/lib/python3.8/site-packages/matplotlib/mpl-data/fonts/ttf/STIXSizOneSymBol.ttf', name='STIXSizeOneSym', style='normal', variant='normal', weight=700, stretch='normal', size='scalable')) = 10.335 [ DEBUG ] findfont: score(FontEntry(fname='/root/.local/lib/python3.8/site-packages/matplotlib/mpl-data/fonts/ttf/cmss10.ttf', name='cmss10', style='normal', variant='normal', weight=400, stretch='normal', size='scalable')) = 10.05 [ DEBUG ] findfont: score(FontEntry(fname='/root/.local/lib/python3.8/site-packages/matplotlib/mpl-data/fonts/ttf/STIXGeneral.ttf', name='STIXGeneral', style='normal', variant='normal', weight=400, stretch='normal', size='scalable')) = 10.05 [ DEBUG ] findfont: score(FontEntry(fname='/root/.local/lib/python3.8/site-packages/matplotlib/mpl-data/fonts/ttf/STIXGeneralItalic.ttf', name='STIXGeneral', style='italic', variant='normal', weight=400, stretch='normal', size='scalable')) = 11.05 [ DEBUG ] findfont: score(FontEntry(fname='/root/.local/lib/python3.8/site-packages/matplotlib/mpl-data/fonts/ttf/STIXGeneralBolIta.ttf', name='STIXGeneral', style='italic', variant='normal', weight=700, stretch='normal', size='scalable')) = 11.335 [ DEBUG ] findfont: score(FontEntry(fname='/root/.local/lib/python3.8/site-packages/matplotlib/mpl-data/fonts/ttf/STIXSizFourSymBol.ttf', name='STIXSizeFourSym', style='normal', variant='normal', weight=700, stretch='normal', size='scalable')) = 10.335 [ DEBUG ] findfont: score(FontEntry(fname='/root/.local/lib/python3.8/site-packages/matplotlib/mpl-data/fonts/ttf/STIXSizFiveSymReg.ttf', name='STIXSizeFiveSym', style='normal', variant='normal', weight=400, stretch='normal', size='scalable')) = 10.05 [ DEBUG ] findfont: score(FontEntry(fname='/root/.local/lib/python3.8/site-packages/matplotlib/mpl-data/fonts/ttf/DejaVuSansDisplay.ttf', name='DejaVu Sans Display', style='normal', variant='normal', weight=400, stretch='normal', size='scalable')) = 10.05 [ DEBUG ] findfont: score(FontEntry(fname='/root/.local/lib/python3.8/site-packages/matplotlib/mpl-data/fonts/ttf/DejaVuSerif-Bold.ttf', name='DejaVu Serif', style='normal', variant='normal', weight=700, stretch='normal', size='scalable')) = 10.335 [ DEBUG ] findfont: score(FontEntry(fname='/root/.local/lib/python3.8/site-packages/matplotlib/mpl-data/fonts/ttf/STIXGeneralBol.ttf', name='STIXGeneral', style='normal', variant='normal', weight=700, stretch='normal', size='scalable')) = 10.335 [ DEBUG ] findfont: score(FontEntry(fname='/root/.local/lib/python3.8/site-packages/matplotlib/mpl-data/fonts/ttf/DejaVuSansMono.ttf', name='DejaVu Sans Mono', style='normal', variant='normal', weight=400, stretch='normal', size='scalable')) = 10.05 [ DEBUG ] findfont: score(FontEntry(fname='/root/.local/lib/python3.8/site-packages/matplotlib/mpl-data/fonts/ttf/DejaVuSans.ttf', name='DejaVu Sans', style='normal', variant='normal', weight=400, stretch='normal', size='scalable')) = 0.05 [ DEBUG ] findfont: score(FontEntry(fname='/root/.local/lib/python3.8/site-packages/matplotlib/mpl-data/fonts/ttf/cmb10.ttf', name='cmb10', style='normal', variant='normal', weight=400, stretch='normal', size='scalable')) = 10.05 [ DEBUG ] findfont: score(FontEntry(fname='/root/.local/lib/python3.8/site-packages/matplotlib/mpl-data/fonts/ttf/cmr10.ttf', name='cmr10', style='normal', variant='normal', weight=400, stretch='normal', size='scalable')) = 10.05 [ DEBUG ] findfont: score(FontEntry(fname='/root/.local/lib/python3.8/site-packages/matplotlib/mpl-data/fonts/ttf/DejaVuSerif-Italic.ttf', name='DejaVu Serif', style='italic', variant='normal', weight=400, stretch='normal', size='scalable')) = 11.05 [ DEBUG ] findfont: score(FontEntry(fname='/root/.local/lib/python3.8/site-packages/matplotlib/mpl-data/fonts/ttf/cmmi10.ttf', name='cmmi10', style='normal', variant='normal', weight=400, stretch='normal', size='scalable')) = 10.05 [ DEBUG ] findfont: score(FontEntry(fname='/root/.local/lib/python3.8/site-packages/matplotlib/mpl-data/fonts/ttf/STIXSizFourSymReg.ttf', name='STIXSizeFourSym', style='normal', variant='normal', weight=400, stretch='normal', size='scalable')) = 10.05 [ DEBUG ] findfont: score(FontEntry(fname='/root/.local/lib/python3.8/site-packages/matplotlib/mpl-data/fonts/ttf/STIXSizThreeSymBol.ttf', name='STIXSizeThreeSym', style='normal', variant='normal', weight=700, stretch='normal', size='scalable')) = 10.335 [ DEBUG ] findfont: score(FontEntry(fname='/root/.local/lib/python3.8/site-packages/matplotlib/mpl-data/fonts/ttf/cmex10.ttf', name='cmex10', style='normal', variant='normal', weight=400, stretch='normal', size='scalable')) = 10.05 [ DEBUG ] findfont: score(FontEntry(fname='/root/.local/lib/python3.8/site-packages/matplotlib/mpl-data/fonts/ttf/STIXSizTwoSymBol.ttf', name='STIXSizeTwoSym', style='normal', variant='normal', weight=700, stretch='normal', size='scalable')) = 10.335 [ DEBUG ] findfont: score(FontEntry(fname='/root/.local/lib/python3.8/site-packages/matplotlib/mpl-data/fonts/ttf/cmsy10.ttf', name='cmsy10', style='normal', variant='normal', weight=400, stretch='normal', size='scalable')) = 10.05 [ DEBUG ] findfont: score(FontEntry(fname='/usr/share/fonts/truetype/dejavu/DejaVuSansMono-Bold.ttf', name='DejaVu Sans Mono', style='normal', variant='normal', weight=700, stretch='normal', size='scalable')) = 10.335 [ DEBUG ] findfont: score(FontEntry(fname='/usr/share/fonts/truetype/dejavu/DejaVuSerif-Bold.ttf', name='DejaVu Serif', style='normal', variant='normal', weight=700, stretch='normal', size='scalable')) = 10.335 [ DEBUG ] findfont: score(FontEntry(fname='/usr/share/fonts/truetype/dejavu/DejaVuSans.ttf', name='DejaVu Sans', style='normal', variant='normal', weight=400, stretch='normal', size='scalable')) = 0.05 [ DEBUG ] findfont: score(FontEntry(fname='/usr/share/fonts/truetype/dejavu/DejaVuSans-Bold.ttf', name='DejaVu Sans', style='normal', variant='normal', weight=700, stretch='normal', size='scalable')) = 0.33499999999999996 [ DEBUG ] findfont: score(FontEntry(fname='/usr/share/fonts/truetype/dejavu/DejaVuSerif.ttf', name='DejaVu Serif', style='normal', variant='normal', weight=400, stretch='normal', size='scalable')) = 10.05 [ DEBUG ] findfont: score(FontEntry(fname='/usr/share/fonts/truetype/dejavu/DejaVuSansMono.ttf', name='DejaVu Sans Mono', style='normal', variant='normal', weight=400, stretch='normal', size='scalable')) = 10.05 [ DEBUG ] findfont: Matching sans-serif:style=normal:variant=normal:weight=normal:stretch=normal:size=10.0 to DejaVu Sans ('/root/.local/lib/python3.8/site-packages/matplotlib/mpl-data/fonts/ttf/DejaVuSans.ttf') with score of 0.050000. /root/.local/lib/python3.8/site-packages/matplotlib/_api/init.py:125: FutureWarning: elementwise comparison failed; returning scalar instead, but in the future will perform elementwise comparison if val not in values: Traceback (most recent call last): File "colorization_demo.py", line 169, in sys.exit(main(args) or 0) File "colorization_demo.py", line 155, in main plt.imshow('Colorization Demo', final_image) File "/root/.local/lib/python3.8/site-packages/matplotlib/_api/deprecation.py", line 459, in wrapper return func(*args, **kwargs) File "/root/.local/lib/python3.8/site-packages/matplotlib/pyplot.py", line 2652, in imshow __ret = gca().imshow( File "/root/.local/lib/python3.8/site-packages/matplotlib/_api/deprecation.py", line 459, in wrapper return func(*args, **kwargs) File "/root/.local/lib/python3.8/site-packages/matplotlib/init.py", line 1412, in inner return func(ax, *map(sanitize_sequence, args), **kwargs) File "/root/.local/lib/python3.8/site-packages/matplotlib/axes/_axes.py", line 5475, in imshow im = mimage.AxesImage(self, cmap, norm, interpolation, File "/root/.local/lib/python3.8/site-packages/matplotlib/image.py", line 929, in init super().init( File "/root/.local/lib/python3.8/site-packages/matplotlib/image.py", line 246, in init cm.ScalarMappable.init(self, norm, cmap) File "/root/.local/lib/python3.8/site-packages/matplotlib/cm.py", line 359, in init self.set_cmap(cmap) # The Colormap instance of this ScalarMappable. File "/root/.local/lib/python3.8/site-packages/matplotlib/cm.py", line 546, in set_cmap cmap = get_cmap(cmap) File "/root/.local/lib/python3.8/site-packages/matplotlib/cm.py", line 286, in get_cmap _api.check_in_list(sorted(_cmap_registry), name=name) File "/root/.local/lib/python3.8/site-packages/matplotlib/_api/init.py", line 129, in check_in_list raise ValueError(msg) ValueError: array([[[ 33, 29, 28], [ 33, 29, 28], [ 33, 29, 28], ..., [ 19, 19, 19], [ 19, 19, 19], [ 19, 19, 19]],

   [[ 33,  29,  28],
    [ 33,  29,  28],
    [ 33,  29,  28],
    ...,
    [ 19,  19,  19],
    [ 19,  19,  19],
    [ 19,  19,  19]],

   [[ 33,  29,  28],
    [ 33,  29,  28],
    [ 33,  29,  28],
    ...,
    [ 19,  19,  19],
    [ 19,  19,  19],
    [ 19,  19,  19]],

   ...,

   [[ 81,   0,   1],
    [ 80,   0,   1],
    [ 79,   0,   1],
    ...,
    [163, 162, 160],
    [163, 162, 159],
    [163, 162, 159]],

   [[ 82,   0,   1],
    [ 82,   0,   1],
    [ 80,   0,   1],
    ...,
    [165, 165, 163],
    [165, 165, 163],
    [165, 165, 163]],

   [[ 83,   0,   1],
    [ 82,   0,   1],
    [ 80,   0,   1],
    ...,
    [166, 166, 164],
    [166, 166, 163],
    [166, 166, 163]]], dtype=uint8) is not a valid value for name; supported values are 'Accent', 'Accent_r', 'Blues', 'Blues_r', 'BrBG', 'BrBG_r', 'BuGn', 'BuGn_r', 'BuPu', 'BuPu_r', 'CMRmap', 'CMRmap_r', 'Dark2', 'Dark2_r', 'GnBu', 'GnBu_r', 'Greens', 'Greens_r', 'Greys', 'Greys_r', 'OrRd', 'OrRd_r', 'Oranges', 'Oranges_r', 'PRGn', 'PRGn_r', 'Paired', 'Paired_r', 'Pastel1', 'Pastel1_r', 'Pastel2', 'Pastel2_r', 'PiYG', 'PiYG_r', 'PuBu', 'PuBuGn', 'PuBuGn_r', 'PuBu_r', 'PuOr', 'PuOr_r', 'PuRd', 'PuRd_r', 'Purples', 'Purples_r', 'RdBu', 'RdBu_r', 'RdGy', 'RdGy_r', 'RdPu', 'RdPu_r', 'RdYlBu', 'RdYlBu_r', 'RdYlGn', 'RdYlGn_r', 'Reds', 'Reds_r', 'Set1', 'Set1_r', 'Set2', 'Set2_r', 'Set3', 'Set3_r', 'Spectral', 'Spectral_r', 'Wistia', 'Wistia_r', 'YlGn', 'YlGnBu', 'YlGnBu_r', 'YlGn_r', 'YlOrBr', 'YlOrBr_r', 'YlOrRd', 'YlOrRd_r', 'afmhot', 'afmhot_r', 'autumn', 'autumn_r', 'binary', 'binary_r', 'bone', 'bone_r', 'brg', 'brg_r', 'bwr', 'bwr_r', 'cividis', 'cividis_r', 'cool', 'cool_r', 'coolwarm', 'coolwarm_r', 'copper', 'copper_r', 'cubehelix', 'cubehelix_r', 'flag', 'flag_r', 'gist_earth', 'gist_earth_r', 'gist_gray', 'gist_gray_r', 'gist_heat', 'gist_heat_r', 'gist_ncar', 'gist_ncar_r', 'gist_rainbow', 'gist_rainbow_r', 'gist_stern', 'gist_stern_r', 'gist_yarg', 'gist_yarg_r', 'gnuplot', 'gnuplot2', 'gnuplot2_r', 'gnuplot_r', 'gray', 'gray_r', 'hot', 'hot_r', 'hsv', 'hsv_r', 'inferno', 'inferno_r', 'jet', 'jet_r', 'magma', 'magma_r', 'nipy_spectral', 'nipy_spectral_r', 'ocean', 'ocean_r', 'pink', 'pink_r', 'plasma', 'plasma_r', 'prism', 'prism_r', 'rainbow', 'rainbow_r', 'seismic', 'seismic_r', 'spring', 'spring_r', 'summer', 'summer_r', 'tab10', 'tab10_r', 'tab20', 'tab20_r', 'tab20b', 'tab20b_r', 'tab20c', 'tab20c_r', 'terrain', 'terrain_r', 'turbo', 'turbo_r', 'twilight', 'twilight_r', 'twilight_shifted', 'twilight_shifted_r', 'viridis', 'viridis_r', 'winter', 'winter_r'

kmanisai avatar Aug 11 '22 04:08 kmanisai