neulab/docprompting-conala huggingface dataset:
set(*, agg_filter=<UNSET>, alpha=<UNSET>, animated=<UNSET>, anncoords=<UNSET>, annotation_clip=<UNSET>, backgroundcolor=<UNSET>, bbox=<UNSET>, clip_box=<UNSET>, clip_on=<UNSET>, clip_path=<UNSET>, color=<UNSET>, fontfamily=<UNSET>, fontproperties=<UNSET>, fontsize=<UNSET>, fontstretch=<UNSET>, fontstyle=<UNSET>, fontvariant=<UNSET>, fontweight=<UNSET>, gid=<UNSET>, horizontalalignment=<UNSET>, in_layout=<UNSET>, label=<UNSET>, linespacing=<UNSET>, math_fontfamily=<UNSET>, multialignment=<UNSET>, parse_math=<UNSET>, path_effects=<UNSET>, picker=<UNSET>, position=<UNSET>, rasterized=<UNSET>, rotation=<UNSET>, rotation_mode=<UNSET>, sketch_params=<UNSET>, snap=<UNSET>, text=<UNSET>, transform=<UNSET>, transform_rotates_text=<UNSET>, url=<UNSET>, usetex=<UNSET>, verticalalignment=<UNSET>, visible=<UNSET>, wrap=<UNSET>, x=<UNSET>, y=<UNSET>, zorder=<UNSET>)[source]
 
Set multiple properties at once. Supported properties are   
Property Description   
agg_filter a filter function, which takes a (m, n, 3) float array and a dpi value, and returns a (m, n, 3) array  
alpha scalar or None  
animated bool  
anncoords unknown  
annotation_clip bool or None  
backgroundcolor color  
bbox dict with properties for patches.FancyBboxPatch  
clip_box Bbox  
clip_on bool  
clip_path Patch or (Path, Transform) or None  
color or c color  
figure unknown  
fontfamily or family {FONTNAME, 'serif', 'sans-serif', 'cursive', 'fantasy', 'monospace'}  
fontproperties or font or font_properties font_manager.FontProperties or str or pathlib.Path  
fontsize or size float or {'xx-small', 'x-small', 'small', 'medium', 'large', 'x-large', 'xx-large'}  
fontstretch or stretch {a numeric value in range 0-1000, 'ultra-condensed', 'extra-condensed', 'condensed', 'semi-condensed', 'normal', 'semi-expanded', 'expanded', 'extra-expanded', 'ultra-expanded'}  
fontstyle or style {'normal', 'italic', 'oblique'}  
fontvariant or variant {'normal', 'small-caps'}  
fontweight or weight {a numeric value in range 0-1000, 'ultralight', 'light', 'normal', 'regular', 'book', 'medium', 'roman', 'semibold', 'demibold', 'demi', 'bold', 'heavy', 'extra bold', 'black'}  
gid str  
horizontalalignment or ha {'center', 'right', 'left'}  
in_layout bool  
label object  
linespacing float (multiple of font size)  
math_fontfamily str  
multialignment or ma {'left', 'right', 'center'}  
parse_math bool  
path_effects AbstractPathEffect  
picker None or bool or float or callable  
position (float, float)  
rasterized bool  
rotation float or {'vertical', 'horizontal'}  
rotation_mode {None, 'default', 'anchor'}  
sketch_params (scale: float, length: float, randomness: float)  
snap bool or None  
text object  
transform Transform  
transform_rotates_text bool  
url str  
usetex bool or None  
verticalalignment or va {'center', 'top', 'bottom', 'baseline', 'center_baseline'}  
visible bool  
wrap bool  
x float  
y float  
zorder float
set_anncoords(coords)[source]
 
Set the coordinate system to use for Annotation.xyann. See also xycoords in Annotation.
update_positions(renderer)[source]
 
Update the pixel positions of the annotation text and the arrow patch.
matplotlib.text.get_rotation(rotation)[source]
 
Return rotation normalized to an angle between 0 and 360 degrees.  Parameters 
 
rotationfloat or {None, 'horizontal', 'vertical'}


Rotation angle in degrees. None and 'horizontal' equal 0, 'vertical' equals 90.    Returns 
 float
classmatplotlib.text.OffsetFrom(artist, ref_coord, unit='points')[source]
 
Bases: object Callable helper class for working with Annotation.  Parameters 
 
artistArtist or BboxBase or Transform


The object to compute the offset from.  
ref_coord(float, float)


If artist is an Artist or BboxBase, this values is the location to of the offset origin in fractions of the artist bounding box. If artist is a transform, the offset origin is the transform applied to this value.  
unit{'points, 'pixels'}, default: 'points'


The screen units to use (pixels or points) for the offset input.       get_unit()[source]
 
Return the unit for input to the transform used by __call__. 
   set_unit(unit)[source]
 
Set the unit for input to the transform used by __call__.  Parameters 
 
unit{'points', 'pixels'}
get_unit()[source]
 
Return the unit for input to the transform used by __call__.
set_unit(unit)[source]
 
Set the unit for input to the transform used by __call__.  Parameters 
 
unit{'points', 'pixels'}
contains(mouseevent)[source]
 
Return whether the mouse event occurred inside the axis-aligned bounding-box of the text.
get_bbox_patch()[source]
 
Return the bbox Patch, or None if the patches.FancyBboxPatch is not made.
get_font_properties()[source]
 
Alias for get_fontproperties.
get_fontfamily()[source]
 
Return the list of font families used for font lookup.  See also  font_manager.FontProperties.get_family
get_fontname()[source]
 
Return the font name as a string.  See also  font_manager.FontProperties.get_name
get_fontproperties()[source]
 
Return the font_manager.FontProperties.
get_fontsize()[source]
 
Return the font size as an integer.  See also  font_manager.FontProperties.get_size_in_points
get_fontstyle()[source]
 
Return the font style as a string.  See also  font_manager.FontProperties.get_style
get_fontvariant()[source]
 
Return the font variant as a string.  See also  font_manager.FontProperties.get_variant
get_fontweight()[source]
 
Return the font weight as a string or a number.  See also  font_manager.FontProperties.get_weight
get_horizontalalignment()[source]
 
Return the horizontal alignment as a string. Will be one of 'left', 'center' or 'right'.
get_math_fontfamily()[source]
 
Return the font family name for math text rendered by Matplotlib. The default value is rcParams["mathtext.fontset"] (default: 'dejavusans').  See also  set_math_fontfamily
get_parse_math()[source]
 
Return whether mathtext parsing is considered for this Text.
get_position()[source]
 
Return the (x, y) position of the text.
get_prop_tup(renderer=None)[source]
 
[Deprecated] Return a hashable tuple of properties. Not intended to be human readable, but useful for backends who want to cache derived information about text (e.g., layouts) and need to know if the text has changed. Notes  Deprecated since version 3.5.
get_stretch()[source]
 
Return the font stretch as a string or a number.  See also  font_manager.FontProperties.get_stretch
get_transform_rotates_text()[source]
 
Return whether rotations of the transform affect the text direction.
get_unitless_position()[source]
 
Return the (x, y) unitless position of the text.
get_usetex()[source]
 
Return whether this Text object uses TeX for rendering.
get_verticalalignment()[source]
 
Return the vertical alignment as a string. Will be one of 'top', 'center', 'bottom', 'baseline' or 'center_baseline'.
get_window_extent(renderer=None, dpi=None)[source]
 
Return the Bbox bounding the text, in display units. In addition to being used internally, this is useful for specifying clickable regions in a png file on a web page.  Parameters 
 
rendererRenderer, optional


A renderer is needed to compute the bounding box. If the artist has already been drawn, the renderer is cached; thus, it is only necessary to pass this argument when calling get_window_extent before the first draw. In practice, it is usually easier to trigger a draw first (e.g. by saving the figure).  
dpifloat, optional


The dpi value for computing the bbox, defaults to self.figure.dpi (not the renderer dpi); should be set e.g. if to match regions with a figure saved with a custom dpi value.
set(*, agg_filter=<UNSET>, alpha=<UNSET>, animated=<UNSET>, backgroundcolor=<UNSET>, bbox=<UNSET>, clip_box=<UNSET>, clip_on=<UNSET>, clip_path=<UNSET>, color=<UNSET>, fontfamily=<UNSET>, fontproperties=<UNSET>, fontsize=<UNSET>, fontstretch=<UNSET>, fontstyle=<UNSET>, fontvariant=<UNSET>, fontweight=<UNSET>, gid=<UNSET>, horizontalalignment=<UNSET>, in_layout=<UNSET>, label=<UNSET>, linespacing=<UNSET>, math_fontfamily=<UNSET>, multialignment=<UNSET>, parse_math=<UNSET>, path_effects=<UNSET>, picker=<UNSET>, position=<UNSET>, rasterized=<UNSET>, rotation=<UNSET>, rotation_mode=<UNSET>, sketch_params=<UNSET>, snap=<UNSET>, text=<UNSET>, transform=<UNSET>, transform_rotates_text=<UNSET>, url=<UNSET>, usetex=<UNSET>, verticalalignment=<UNSET>, visible=<UNSET>, wrap=<UNSET>, x=<UNSET>, y=<UNSET>, zorder=<UNSET>)[source]
 
Set multiple properties at once. Supported properties are   
Property Description   
agg_filter a filter function, which takes a (m, n, 3) float array and a dpi value, and returns a (m, n, 3) array  
alpha scalar or None  
animated bool  
backgroundcolor color  
bbox dict with properties for patches.FancyBboxPatch  
clip_box unknown  
clip_on unknown  
clip_path unknown  
color color  
figure Figure  
fontfamily {FONTNAME, 'serif', 'sans-serif', 'cursive', 'fantasy', 'monospace'}  
fontproperties font_manager.FontProperties or str or pathlib.Path  
fontsize float or {'xx-small', 'x-small', 'small', 'medium', 'large', 'x-large', 'xx-large'}  
fontstretch {a numeric value in range 0-1000, 'ultra-condensed', 'extra-condensed', 'condensed', 'semi-condensed', 'normal', 'semi-expanded', 'expanded', 'extra-expanded', 'ultra-expanded'}  
fontstyle {'normal', 'italic', 'oblique'}  
fontvariant {'normal', 'small-caps'}  
fontweight {a numeric value in range 0-1000, 'ultralight', 'light', 'normal', 'regular', 'book', 'medium', 'roman', 'semibold', 'demibold', 'demi', 'bold', 'heavy', 'extra bold', 'black'}  
gid str  
horizontalalignment {'center', 'right', 'left'}  
in_layout bool  
label object  
linespacing float (multiple of font size)  
math_fontfamily str  
multialignment {'left', 'right', 'center'}  
parse_math bool  
path_effects AbstractPathEffect  
picker None or bool or float or callable  
position (float, float)  
rasterized bool  
rotation float or {'vertical', 'horizontal'}  
rotation_mode {None, 'default', 'anchor'}  
sketch_params (scale: float, length: float, randomness: float)  
snap bool or None  
text object  
transform Transform  
transform_rotates_text bool  
url str  
usetex bool or None  
verticalalignment {'center', 'top', 'bottom', 'baseline', 'center_baseline'}  
visible bool  
wrap bool  
x float  
y float  
zorder float
set_backgroundcolor(color)[source]
 
Set the background color of the text by updating the bbox.  Parameters 
 
colorcolor

    See also  set_bbox

To change the position of the bounding box
set_bbox(rectprops)[source]
 
Draw a bounding box around self.  Parameters 
 
rectpropsdict with properties for patches.FancyBboxPatch


The default boxstyle is 'square'. The mutation scale of the patches.FancyBboxPatch is set to the fontsize.     Examples t.set_bbox(dict(facecolor='red', alpha=0.5))
set_color(color)[source]
 
Set the foreground color of the text  Parameters 
 
colorcolor
set_family(fontname)[source]
 
Alias for set_fontfamily.
set_font(fp)[source]
 
Alias for set_fontproperties.
set_font_properties(fp)[source]
 
Alias for set_fontproperties.
set_fontfamily(fontname)[source]
 
Set the font family. May be either a single string, or a list of strings in decreasing priority. Each string may be either a real font name or a generic font class name. If the latter, the specific font names will be looked up in the corresponding rcParams. If a Text instance is constructed with fontfamily=None, then the font is set to rcParams["font.family"] (default: ['sans-serif']), and the same is done when set_fontfamily() is called on an existing Text instance.  Parameters 
 
fontname{FONTNAME, 'serif', 'sans-serif', 'cursive', 'fantasy', 'monospace'}

    See also  font_manager.FontProperties.set_family
set_fontname(fontname)[source]
 
Alias for set_family. One-way alias only: the getter differs.  Parameters 
 
fontname{FONTNAME, 'serif', 'sans-serif', 'cursive', 'fantasy', 'monospace'}

    See also  font_manager.FontProperties.set_family
set_fontproperties(fp)[source]
 
Set the font properties that control the text.  Parameters 
 
fpfont_manager.FontProperties or str or pathlib.Path


If a str, it is interpreted as a fontconfig pattern parsed by FontProperties. If a pathlib.Path, it is interpreted as the absolute path to a font file.
set_fontsize(fontsize)[source]
 
Set the font size.  Parameters 
 
fontsizefloat or {'xx-small', 'x-small', 'small', 'medium', 'large', 'x-large', 'xx-large'}


If float, the fontsize in points. The string values denote sizes relative to the default font size.      See also  font_manager.FontProperties.set_size
set_fontstretch(stretch)[source]
 
Set the font stretch (horizontal condensation or expansion).  Parameters 
 
stretch{a numeric value in range 0-1000, 'ultra-condensed', 'extra-condensed', 'condensed', 'semi-condensed', 'normal', 'semi-expanded', 'expanded', 'extra-expanded', 'ultra-expanded'}

    See also  font_manager.FontProperties.set_stretch
set_fontstyle(fontstyle)[source]
 
Set the font style.  Parameters 
 
fontstyle{'normal', 'italic', 'oblique'}

    See also  font_manager.FontProperties.set_style
set_fontvariant(variant)[source]
 
Set the font variant.  Parameters 
 
variant{'normal', 'small-caps'}

    See also  font_manager.FontProperties.set_variant
set_fontweight(weight)[source]
 
Set the font weight.  Parameters 
 
weight{a numeric value in range 0-1000, 'ultralight', 'light', 'normal', 'regular', 'book', 'medium', 'roman', 'semibold', 'demibold', 'demi', 'bold', 'heavy', 'extra bold', 'black'}

    See also  font_manager.FontProperties.set_weight
set_horizontalalignment(align)[source]
 
Set the horizontal alignment to one of  Parameters 
 
align{'center', 'right', 'left'}
set_linespacing(spacing)[source]
 
Set the line spacing as a multiple of the font size. The default line spacing is 1.2.  Parameters 
 
spacingfloat (multiple of font size)
set_math_fontfamily(fontfamily)[source]
 
Set the font family for math text rendered by Matplotlib. This does only affect Matplotlib's own math renderer. It has no effect when rendering with TeX (usetex=True).  Parameters 
 
fontfamilystr


The name of the font family. Available font families are defined in the matplotlibrc.template file.      See also  get_math_fontfamily
set_multialignment(align)[source]
 
Set the text alignment for multiline texts. The layout of the bounding box of all the lines is determined by the horizontalalignment and verticalalignment properties. This property controls the alignment of the text lines within that box.  Parameters 
 
align{'left', 'right', 'center'}
set_parse_math(parse_math)[source]
 
Override switch to disable any mathtext parsing for this Text.  Parameters 
 
parse_mathbool


If False, this Text will never use mathtext. If True, mathtext will be used if there is an even number of unescaped dollar signs.
set_position(xy)[source]
 
Set the (x, y) position of the text.  Parameters 
 
xy(float, float)
set_rotation(s)[source]
 
Set the rotation of the text.  Parameters 
 
sfloat or {'vertical', 'horizontal'}


The rotation angle in degrees in mathematically positive direction (counterclockwise). 'horizontal' equals 0, 'vertical' equals 90.
set_rotation_mode(m)[source]
 
Set text rotation mode.  Parameters 
 
m{None, 'default', 'anchor'}


If None or "default", the text will be first rotated, then aligned according to their horizontal and vertical alignments. If "anchor", then alignment occurs before rotation.
set_style(fontstyle)[source]
 
Alias for set_fontstyle.
set_text(s)[source]
 
Set the text string s. It may contain newlines (\n) or math in LaTeX syntax.  Parameters 
 
sobject


Any object gets converted to its str representation, except for None which is converted to an empty string.
set_transform_rotates_text(t)[source]
 
Whether rotations of the transform affect the text direction.  Parameters 
 
tbool
set_usetex(usetex)[source]
 
 Parameters 
 
usetexbool or None


Whether to render using TeX, None means to use rcParams["text.usetex"] (default: False).
set_verticalalignment(align)[source]
 
Set the vertical alignment.  Parameters 
 
align{'center', 'top', 'bottom', 'baseline', 'center_baseline'}
set_wrap(wrap)[source]
 
Set whether the text can be wrapped.  Parameters 
 
wrapbool

   Notes Wrapping does not work together with savefig(..., bbox_inches='tight') (which is also used internally by %matplotlib inline in IPython/Jupyter). The 'tight' setting rescales the canvas to accommodate all content and happens before wrapping.
set_x(x)[source]
 
Set the x position of the text.  Parameters 
 
xfloat
set_y(y)[source]
 
Set the y position of the text.  Parameters 
 
yfloat
update(kwargs)[source]
 
Update this artist's properties from the dict props.  Parameters 
 
propsdict
update_bbox_position_size(renderer)[source]
 
Update the location and the size of the bbox. This method should be used when the position and size of the bbox needs to be updated before actually drawing the bbox.
matplotlib.textpath   classmatplotlib.textpath.TextPath(xy, s, size=None, prop=None, _interpolation_steps=1, usetex=False)[source]
 
Bases: matplotlib.path.Path Create a path from the text. Create a path from the text. Note that it simply is a path, not an artist. You need to use the PathPatch (or other artists) to draw this path onto the canvas.  Parameters 
 
xytuple or array of two float values


Position of the text. For no offset, use xy=(0, 0).  
sstr


The text to convert to a path.  
sizefloat, optional


Font size in points. Defaults to the size specified via the font properties prop.  
propmatplotlib.font_manager.FontProperties, optional


Font property. If not provided, will use a default FontProperties with parameters from the rcParams.  
_interpolation_stepsint, optional


(Currently ignored)  
usetexbool, default: False


Whether to use tex rendering.     Examples The following creates a path from the string "ABC" with Helvetica font face; and another path from the latex fraction 1/2: from matplotlib.textpath import TextPath
from matplotlib.font_manager import FontProperties

fp = FontProperties(family="Helvetica", style="italic")
path1 = TextPath((12, 12), "ABC", size=12, prop=fp)
path2 = TextPath((0, 0), r"$\frac{1}{2}$", size=12, usetex=True)
 Also see Using a text as a Path.   propertycodes
 
Return the codes 
   get_size()[source]
 
Get the text size. 
   set_size(size)[source]
 
Set the text size. 
   propertyvertices
 
Return the cached path after updating it if necessary. 
 
   classmatplotlib.textpath.TextToPath[source]
 
Bases: object A class that converts strings to paths.   DPI=72

   FONT_SCALE=100.0

   get_glyphs_mathtext(prop, s, glyph_map=None, return_new_glyphs_only=False)[source]
 
Parse mathtext string s and convert it to a (vertices, codes) pair. 
   get_glyphs_tex(prop, s, glyph_map=None, return_new_glyphs_only=False)[source]
 
Convert the string s to vertices and codes using usetex mode. 
   get_glyphs_with_font(font, s, glyph_map=None, return_new_glyphs_only=False)[source]
 
Convert string s to vertices and codes using the provided ttf font. 
   get_texmanager()[source]
 
Return the cached TexManager instance. 
   get_text_path(prop, s, ismath=False)[source]
 
Convert text s to path (a tuple of vertices and codes for matplotlib.path.Path).  Parameters 
 
propFontProperties


The font properties for the text.  
sstr


The text to be converted.  
ismath{False, True, "TeX"}


If True, use mathtext parser. If "TeX", use tex for rendering.    Returns 
 
vertslist


A list of numpy arrays containing the x and y coordinates of the vertices.  
codeslist


A list of path codes.     Examples Create a list of vertices and codes from a text, and create a Path from those: from matplotlib.path import Path
from matplotlib.textpath import TextToPath
from matplotlib.font_manager import FontProperties

fp = FontProperties(family="Humor Sans", style="italic")
verts, codes = TextToPath().get_text_path(fp, "ABC")
path = Path(verts, codes, closed=False)
 Also see TextPath for a more direct way to create a path from a text. 
   get_text_width_height_descent(s, prop, ismath)[source]
classmatplotlib.textpath.TextPath(xy, s, size=None, prop=None, _interpolation_steps=1, usetex=False)[source]
 
Bases: matplotlib.path.Path Create a path from the text. Create a path from the text. Note that it simply is a path, not an artist. You need to use the PathPatch (or other artists) to draw this path onto the canvas.  Parameters 
 
xytuple or array of two float values


Position of the text. For no offset, use xy=(0, 0).  
sstr


The text to convert to a path.  
sizefloat, optional


Font size in points. Defaults to the size specified via the font properties prop.  
propmatplotlib.font_manager.FontProperties, optional


Font property. If not provided, will use a default FontProperties with parameters from the rcParams.  
_interpolation_stepsint, optional


(Currently ignored)  
usetexbool, default: False


Whether to use tex rendering.     Examples The following creates a path from the string "ABC" with Helvetica font face; and another path from the latex fraction 1/2: from matplotlib.textpath import TextPath
from matplotlib.font_manager import FontProperties

fp = FontProperties(family="Helvetica", style="italic")
path1 = TextPath((12, 12), "ABC", size=12, prop=fp)
path2 = TextPath((0, 0), r"$\frac{1}{2}$", size=12, usetex=True)
 Also see Using a text as a Path.   propertycodes
 
Return the codes 
   get_size()[source]
 
Get the text size. 
   set_size(size)[source]
 
Set the text size. 
   propertyvertices
 
Return the cached path after updating it if necessary.
classmatplotlib.textpath.TextToPath[source]
 
Bases: object A class that converts strings to paths.   DPI=72

   FONT_SCALE=100.0

   get_glyphs_mathtext(prop, s, glyph_map=None, return_new_glyphs_only=False)[source]
 
Parse mathtext string s and convert it to a (vertices, codes) pair. 
   get_glyphs_tex(prop, s, glyph_map=None, return_new_glyphs_only=False)[source]
 
Convert the string s to vertices and codes using usetex mode. 
   get_glyphs_with_font(font, s, glyph_map=None, return_new_glyphs_only=False)[source]
 
Convert string s to vertices and codes using the provided ttf font. 
   get_texmanager()[source]
 
Return the cached TexManager instance. 
   get_text_path(prop, s, ismath=False)[source]
 
Convert text s to path (a tuple of vertices and codes for matplotlib.path.Path).  Parameters 
 
propFontProperties


The font properties for the text.  
sstr


The text to be converted.  
ismath{False, True, "TeX"}


If True, use mathtext parser. If "TeX", use tex for rendering.    Returns 
 
vertslist


A list of numpy arrays containing the x and y coordinates of the vertices.  
codeslist


A list of path codes.     Examples Create a list of vertices and codes from a text, and create a Path from those: from matplotlib.path import Path
from matplotlib.textpath import TextToPath
from matplotlib.font_manager import FontProperties

fp = FontProperties(family="Humor Sans", style="italic")
verts, codes = TextToPath().get_text_path(fp, "ABC")
path = Path(verts, codes, closed=False)
 Also see TextPath for a more direct way to create a path from a text. 
   get_text_width_height_descent(s, prop, ismath)[source]
get_glyphs_mathtext(prop, s, glyph_map=None, return_new_glyphs_only=False)[source]
 
Parse mathtext string s and convert it to a (vertices, codes) pair.
get_glyphs_tex(prop, s, glyph_map=None, return_new_glyphs_only=False)[source]
 
Convert the string s to vertices and codes using usetex mode.
get_glyphs_with_font(font, s, glyph_map=None, return_new_glyphs_only=False)[source]
 
Convert string s to vertices and codes using the provided ttf font.