mindelec.vision.print_graph_2d
- mindelec.vision.print_graph_2d(name, x, y, path, clear=True)[source]
Draw 2d scatter image
- Parameters
name (str) – name of the graph.
x (numpy.ndarray) – data x to draw (shape (dim_print,)).
y (numpy.ndarray) – data y to draw (shape (dim_print,)).
path (str) – save path of the graph.
clear (bool) – specifies whether clear the current axes. Default: True.
- Supported Platforms:
Ascend
Examples
>>> import numpy as np >>> from mindelec.vision import print_graph_2d >>> name = "output.jpg" >>> x = np.ones(10) >>> y = np.ones(10) >>> path = "./graph_2d" >>> clear = True >>> print_graph_2d(name, x, y, path, clear)