Warning: file_get_contents(/data/phpspider/zhask/data//catemap/2/python/322.json): failed to open stream: No such file or directory in /data/phpspider/zhask/libs/function.php on line 167

Warning: Invalid argument supplied for foreach() in /data/phpspider/zhask/libs/tag.function.php on line 1116

Notice: Undefined index: in /data/phpspider/zhask/libs/function.php on line 180

Warning: array_chunk() expects parameter 1 to be array, null given in /data/phpspider/zhask/libs/function.php on line 181
Python kwargs什么都不做_Python_Keyword Argument - Fatal编程技术网

Python kwargs什么都不做

Python kwargs什么都不做,python,keyword-argument,Python,Keyword Argument,你能帮我理解为什么这些关键字参数在图表上没有任何作用吗? 我的代码没有返回任何错误,但它没有考虑这些参数 plot_kwargs = ({'marker': 'o', 'color': 'w', 'mec': 'b', 'linestyle': '-'}) annotate_kwargs = ({'text': 'illuminant'}) plot_planckian_locus_in_chromaticity_diagram(xy, method='CIE 1960 UCS', **pl

你能帮我理解为什么这些关键字参数在图表上没有任何作用吗? 我的代码没有返回任何错误,但它没有考虑这些参数

plot_kwargs = ({'marker': 'o', 'color': 'w', 'mec': 'b', 'linestyle': '-'})

annotate_kwargs = ({'text': 'illuminant'})

plot_planckian_locus_in_chromaticity_diagram(xy, method='CIE 1960 UCS', **plot_kwargs, **annotate_kwargs)

假设您正在使用颜色,则不应使用dict解包来传递plot_kwargs和NOTATION_kwargs

从:

在色度图中绘制普朗克轨迹 [A',B',C'], annotate_kwargs=annotate_kwargs, plot_kwargs=plot_kwargs
是的,我已经尝试过了,但是它返回了一个错误,定义了多个关键字参数,但是它们与预期的计数不匹配!