Search is not available for this dataset
identifier
stringlengths
1
155
parameters
stringlengths
2
6.09k
docstring
stringlengths
11
63.4k
docstring_summary
stringlengths
0
63.4k
function
stringlengths
29
99.8k
function_tokens
list
start_point
list
end_point
list
language
stringclasses
1 value
docstring_language
stringlengths
2
7
docstring_language_predictions
stringlengths
18
23
is_langid_reliable
stringclasses
2 values
Funnelarea.domain
(self)
The 'domain' property is an instance of Domain that may be specified as: - An instance of :class:`plotly.graph_objs.funnelarea.Domain` - A dict of string/value properties that will be passed to the Domain constructor Supported dict properties: ...
The 'domain' property is an instance of Domain that may be specified as: - An instance of :class:`plotly.graph_objs.funnelarea.Domain` - A dict of string/value properties that will be passed to the Domain constructor Supported dict properties: ...
def domain(self): """ The 'domain' property is an instance of Domain that may be specified as: - An instance of :class:`plotly.graph_objs.funnelarea.Domain` - A dict of string/value properties that will be passed to the Domain constructor Supporte...
[ "def", "domain", "(", "self", ")", ":", "return", "self", "[", "\"domain\"", "]" ]
[ 163, 4 ]
[ 192, 29 ]
python
en
['en', 'error', 'th']
False
Funnelarea.hoverinfo
(self)
Determines which trace information appear on hover. If `none` or `skip` are set, no information is displayed upon hovering. But, if `none` is set, click and hover events are still fired. The 'hoverinfo' property is a flaglist and may be specified as a string containing: ...
Determines which trace information appear on hover. If `none` or `skip` are set, no information is displayed upon hovering. But, if `none` is set, click and hover events are still fired. The 'hoverinfo' property is a flaglist and may be specified as a string containing: ...
def hoverinfo(self): """ Determines which trace information appear on hover. If `none` or `skip` are set, no information is displayed upon hovering. But, if `none` is set, click and hover events are still fired. The 'hoverinfo' property is a flaglist and may be specified ...
[ "def", "hoverinfo", "(", "self", ")", ":", "return", "self", "[", "\"hoverinfo\"", "]" ]
[ 201, 4 ]
[ 218, 32 ]
python
en
['en', 'error', 'th']
False
Funnelarea.hoverinfosrc
(self)
Sets the source reference on Chart Studio Cloud for hoverinfo . The 'hoverinfosrc' property must be specified as a string or as a plotly.grid_objs.Column object Returns ------- str
Sets the source reference on Chart Studio Cloud for hoverinfo . The 'hoverinfosrc' property must be specified as a string or as a plotly.grid_objs.Column object
def hoverinfosrc(self): """ Sets the source reference on Chart Studio Cloud for hoverinfo . The 'hoverinfosrc' property must be specified as a string or as a plotly.grid_objs.Column object Returns ------- str """ return self["hoverin...
[ "def", "hoverinfosrc", "(", "self", ")", ":", "return", "self", "[", "\"hoverinfosrc\"", "]" ]
[ 227, 4 ]
[ 239, 35 ]
python
en
['en', 'error', 'th']
False
Funnelarea.hoverlabel
(self)
The 'hoverlabel' property is an instance of Hoverlabel that may be specified as: - An instance of :class:`plotly.graph_objs.funnelarea.Hoverlabel` - A dict of string/value properties that will be passed to the Hoverlabel constructor Supported dict proper...
The 'hoverlabel' property is an instance of Hoverlabel that may be specified as: - An instance of :class:`plotly.graph_objs.funnelarea.Hoverlabel` - A dict of string/value properties that will be passed to the Hoverlabel constructor Supported dict proper...
def hoverlabel(self): """ The 'hoverlabel' property is an instance of Hoverlabel that may be specified as: - An instance of :class:`plotly.graph_objs.funnelarea.Hoverlabel` - A dict of string/value properties that will be passed to the Hoverlabel constructor ...
[ "def", "hoverlabel", "(", "self", ")", ":", "return", "self", "[", "\"hoverlabel\"", "]" ]
[ 248, 4 ]
[ 298, 33 ]
python
en
['en', 'error', 'th']
False
Funnelarea.hovertemplate
(self)
Template string used for rendering the information that appear on hover box. Note that this will override `hoverinfo`. Variables are inserted using %{variable}, for example "y: %{y}". Numbers are formatted using d3-format's syntax %{variable:d3-format}, for example "Price: %{y:$...
Template string used for rendering the information that appear on hover box. Note that this will override `hoverinfo`. Variables are inserted using %{variable}, for example "y: %{y}". Numbers are formatted using d3-format's syntax %{variable:d3-format}, for example "Price: %{y:$...
def hovertemplate(self): """ Template string used for rendering the information that appear on hover box. Note that this will override `hoverinfo`. Variables are inserted using %{variable}, for example "y: %{y}". Numbers are formatted using d3-format's syntax %{variable:d...
[ "def", "hovertemplate", "(", "self", ")", ":", "return", "self", "[", "\"hovertemplate\"", "]" ]
[ 307, 4 ]
[ 340, 36 ]
python
en
['en', 'error', 'th']
False
Funnelarea.hovertemplatesrc
(self)
Sets the source reference on Chart Studio Cloud for hovertemplate . The 'hovertemplatesrc' property must be specified as a string or as a plotly.grid_objs.Column object Returns ------- str
Sets the source reference on Chart Studio Cloud for hovertemplate . The 'hovertemplatesrc' property must be specified as a string or as a plotly.grid_objs.Column object
def hovertemplatesrc(self): """ Sets the source reference on Chart Studio Cloud for hovertemplate . The 'hovertemplatesrc' property must be specified as a string or as a plotly.grid_objs.Column object Returns ------- str """ return se...
[ "def", "hovertemplatesrc", "(", "self", ")", ":", "return", "self", "[", "\"hovertemplatesrc\"", "]" ]
[ 349, 4 ]
[ 361, 39 ]
python
en
['en', 'error', 'th']
False
Funnelarea.hovertext
(self)
Sets hover text elements associated with each sector. If a single string, the same string appears for all data points. If an array of string, the items are mapped in order of this trace's sectors. To be seen, trace `hoverinfo` must contain a "text" flag. The 'hovert...
Sets hover text elements associated with each sector. If a single string, the same string appears for all data points. If an array of string, the items are mapped in order of this trace's sectors. To be seen, trace `hoverinfo` must contain a "text" flag. The 'hovert...
def hovertext(self): """ Sets hover text elements associated with each sector. If a single string, the same string appears for all data points. If an array of string, the items are mapped in order of this trace's sectors. To be seen, trace `hoverinfo` must contain a "text...
[ "def", "hovertext", "(", "self", ")", ":", "return", "self", "[", "\"hovertext\"", "]" ]
[ 370, 4 ]
[ 387, 32 ]
python
en
['en', 'error', 'th']
False
Funnelarea.hovertextsrc
(self)
Sets the source reference on Chart Studio Cloud for hovertext . The 'hovertextsrc' property must be specified as a string or as a plotly.grid_objs.Column object Returns ------- str
Sets the source reference on Chart Studio Cloud for hovertext . The 'hovertextsrc' property must be specified as a string or as a plotly.grid_objs.Column object
def hovertextsrc(self): """ Sets the source reference on Chart Studio Cloud for hovertext . The 'hovertextsrc' property must be specified as a string or as a plotly.grid_objs.Column object Returns ------- str """ return self["hoverte...
[ "def", "hovertextsrc", "(", "self", ")", ":", "return", "self", "[", "\"hovertextsrc\"", "]" ]
[ 396, 4 ]
[ 408, 35 ]
python
en
['en', 'error', 'th']
False
Funnelarea.ids
(self)
Assigns id labels to each datum. These ids for object constancy of data points during animation. Should be an array of strings, not numbers or any other type. The 'ids' property is an array that may be specified as a tuple, list, numpy array, or pandas Series Retur...
Assigns id labels to each datum. These ids for object constancy of data points during animation. Should be an array of strings, not numbers or any other type. The 'ids' property is an array that may be specified as a tuple, list, numpy array, or pandas Series
def ids(self): """ Assigns id labels to each datum. These ids for object constancy of data points during animation. Should be an array of strings, not numbers or any other type. The 'ids' property is an array that may be specified as a tuple, list, numpy array, or pa...
[ "def", "ids", "(", "self", ")", ":", "return", "self", "[", "\"ids\"", "]" ]
[ 417, 4 ]
[ 430, 26 ]
python
en
['en', 'error', 'th']
False
Funnelarea.idssrc
(self)
Sets the source reference on Chart Studio Cloud for ids . The 'idssrc' property must be specified as a string or as a plotly.grid_objs.Column object Returns ------- str
Sets the source reference on Chart Studio Cloud for ids . The 'idssrc' property must be specified as a string or as a plotly.grid_objs.Column object
def idssrc(self): """ Sets the source reference on Chart Studio Cloud for ids . The 'idssrc' property must be specified as a string or as a plotly.grid_objs.Column object Returns ------- str """ return self["idssrc"]
[ "def", "idssrc", "(", "self", ")", ":", "return", "self", "[", "\"idssrc\"", "]" ]
[ 439, 4 ]
[ 450, 29 ]
python
en
['en', 'error', 'th']
False
Funnelarea.insidetextfont
(self)
Sets the font used for `textinfo` lying inside the sector. The 'insidetextfont' property is an instance of Insidetextfont that may be specified as: - An instance of :class:`plotly.graph_objs.funnelarea.Insidetextfont` - A dict of string/value properties that will be pas...
Sets the font used for `textinfo` lying inside the sector. The 'insidetextfont' property is an instance of Insidetextfont that may be specified as: - An instance of :class:`plotly.graph_objs.funnelarea.Insidetextfont` - A dict of string/value properties that will be pas...
def insidetextfont(self): """ Sets the font used for `textinfo` lying inside the sector. The 'insidetextfont' property is an instance of Insidetextfont that may be specified as: - An instance of :class:`plotly.graph_objs.funnelarea.Insidetextfont` - A dict of str...
[ "def", "insidetextfont", "(", "self", ")", ":", "return", "self", "[", "\"insidetextfont\"", "]" ]
[ 459, 4 ]
[ 506, 37 ]
python
en
['en', 'error', 'th']
False
Funnelarea.label0
(self)
Alternate to `labels`. Builds a numeric set of labels. Use with `dlabel` where `label0` is the starting label and `dlabel` the step. The 'label0' property is a number and may be specified as: - An int or float Returns ------- int|float
Alternate to `labels`. Builds a numeric set of labels. Use with `dlabel` where `label0` is the starting label and `dlabel` the step. The 'label0' property is a number and may be specified as: - An int or float
def label0(self): """ Alternate to `labels`. Builds a numeric set of labels. Use with `dlabel` where `label0` is the starting label and `dlabel` the step. The 'label0' property is a number and may be specified as: - An int or float Returns ------- ...
[ "def", "label0", "(", "self", ")", ":", "return", "self", "[", "\"label0\"", "]" ]
[ 515, 4 ]
[ 528, 29 ]
python
en
['en', 'error', 'th']
False
Funnelarea.labels
(self)
Sets the sector labels. If `labels` entries are duplicated, we sum associated `values` or simply count occurrences if `values` is not provided. For other array attributes (including color) we use the first non-empty entry among all occurrences of the label. The 'lab...
Sets the sector labels. If `labels` entries are duplicated, we sum associated `values` or simply count occurrences if `values` is not provided. For other array attributes (including color) we use the first non-empty entry among all occurrences of the label. The 'lab...
def labels(self): """ Sets the sector labels. If `labels` entries are duplicated, we sum associated `values` or simply count occurrences if `values` is not provided. For other array attributes (including color) we use the first non-empty entry among all occurrences of the ...
[ "def", "labels", "(", "self", ")", ":", "return", "self", "[", "\"labels\"", "]" ]
[ 537, 4 ]
[ 552, 29 ]
python
en
['en', 'error', 'th']
False
Funnelarea.labelssrc
(self)
Sets the source reference on Chart Studio Cloud for labels . The 'labelssrc' property must be specified as a string or as a plotly.grid_objs.Column object Returns ------- str
Sets the source reference on Chart Studio Cloud for labels . The 'labelssrc' property must be specified as a string or as a plotly.grid_objs.Column object
def labelssrc(self): """ Sets the source reference on Chart Studio Cloud for labels . The 'labelssrc' property must be specified as a string or as a plotly.grid_objs.Column object Returns ------- str """ return self["labelssrc"]
[ "def", "labelssrc", "(", "self", ")", ":", "return", "self", "[", "\"labelssrc\"", "]" ]
[ 561, 4 ]
[ 572, 32 ]
python
en
['en', 'error', 'th']
False
Funnelarea.legendgroup
(self)
Sets the legend group for this trace. Traces part of the same legend group hide/show at the same time when toggling legend items. The 'legendgroup' property is a string and must be specified as: - A string - A number that will be converted to a string R...
Sets the legend group for this trace. Traces part of the same legend group hide/show at the same time when toggling legend items. The 'legendgroup' property is a string and must be specified as: - A string - A number that will be converted to a string
def legendgroup(self): """ Sets the legend group for this trace. Traces part of the same legend group hide/show at the same time when toggling legend items. The 'legendgroup' property is a string and must be specified as: - A string - A number that will b...
[ "def", "legendgroup", "(", "self", ")", ":", "return", "self", "[", "\"legendgroup\"", "]" ]
[ 581, 4 ]
[ 595, 34 ]
python
en
['en', 'error', 'th']
False
Funnelarea.marker
(self)
The 'marker' property is an instance of Marker that may be specified as: - An instance of :class:`plotly.graph_objs.funnelarea.Marker` - A dict of string/value properties that will be passed to the Marker constructor Supported dict properties: ...
The 'marker' property is an instance of Marker that may be specified as: - An instance of :class:`plotly.graph_objs.funnelarea.Marker` - A dict of string/value properties that will be passed to the Marker constructor Supported dict properties: ...
def marker(self): """ The 'marker' property is an instance of Marker that may be specified as: - An instance of :class:`plotly.graph_objs.funnelarea.Marker` - A dict of string/value properties that will be passed to the Marker constructor Supporte...
[ "def", "marker", "(", "self", ")", ":", "return", "self", "[", "\"marker\"", "]" ]
[ 604, 4 ]
[ 630, 29 ]
python
en
['en', 'error', 'th']
False
Funnelarea.meta
(self)
Assigns extra meta information associated with this trace that can be used in various text attributes. Attributes such as trace `name`, graph, axis and colorbar `title.text`, annotation `text` `rangeselector`, `updatemenues` and `sliders` `label` text all support `meta`. To acce...
Assigns extra meta information associated with this trace that can be used in various text attributes. Attributes such as trace `name`, graph, axis and colorbar `title.text`, annotation `text` `rangeselector`, `updatemenues` and `sliders` `label` text all support `meta`. To acce...
def meta(self): """ Assigns extra meta information associated with this trace that can be used in various text attributes. Attributes such as trace `name`, graph, axis and colorbar `title.text`, annotation `text` `rangeselector`, `updatemenues` and `sliders` `label` text ...
[ "def", "meta", "(", "self", ")", ":", "return", "self", "[", "\"meta\"", "]" ]
[ 639, 4 ]
[ 658, 27 ]
python
en
['en', 'error', 'th']
False
Funnelarea.metasrc
(self)
Sets the source reference on Chart Studio Cloud for meta . The 'metasrc' property must be specified as a string or as a plotly.grid_objs.Column object Returns ------- str
Sets the source reference on Chart Studio Cloud for meta . The 'metasrc' property must be specified as a string or as a plotly.grid_objs.Column object
def metasrc(self): """ Sets the source reference on Chart Studio Cloud for meta . The 'metasrc' property must be specified as a string or as a plotly.grid_objs.Column object Returns ------- str """ return self["metasrc"]
[ "def", "metasrc", "(", "self", ")", ":", "return", "self", "[", "\"metasrc\"", "]" ]
[ 667, 4 ]
[ 678, 30 ]
python
en
['en', 'error', 'th']
False
Funnelarea.name
(self)
Sets the trace name. The trace name appear as the legend item and on hover. The 'name' property is a string and must be specified as: - A string - A number that will be converted to a string Returns ------- str
Sets the trace name. The trace name appear as the legend item and on hover. The 'name' property is a string and must be specified as: - A string - A number that will be converted to a string
def name(self): """ Sets the trace name. The trace name appear as the legend item and on hover. The 'name' property is a string and must be specified as: - A string - A number that will be converted to a string Returns ------- str ...
[ "def", "name", "(", "self", ")", ":", "return", "self", "[", "\"name\"", "]" ]
[ 687, 4 ]
[ 700, 27 ]
python
en
['en', 'error', 'th']
False
Funnelarea.opacity
(self)
Sets the opacity of the trace. The 'opacity' property is a number and may be specified as: - An int or float in the interval [0, 1] Returns ------- int|float
Sets the opacity of the trace. The 'opacity' property is a number and may be specified as: - An int or float in the interval [0, 1]
def opacity(self): """ Sets the opacity of the trace. The 'opacity' property is a number and may be specified as: - An int or float in the interval [0, 1] Returns ------- int|float """ return self["opacity"]
[ "def", "opacity", "(", "self", ")", ":", "return", "self", "[", "\"opacity\"", "]" ]
[ 709, 4 ]
[ 720, 30 ]
python
en
['en', 'error', 'th']
False
Funnelarea.scalegroup
(self)
If there are multiple funnelareas that should be sized according to their totals, link them by providing a non-empty group id here shared by every trace in the same group. The 'scalegroup' property is a string and must be specified as: - A string - A number that...
If there are multiple funnelareas that should be sized according to their totals, link them by providing a non-empty group id here shared by every trace in the same group. The 'scalegroup' property is a string and must be specified as: - A string - A number that...
def scalegroup(self): """ If there are multiple funnelareas that should be sized according to their totals, link them by providing a non-empty group id here shared by every trace in the same group. The 'scalegroup' property is a string and must be specified as: - A...
[ "def", "scalegroup", "(", "self", ")", ":", "return", "self", "[", "\"scalegroup\"", "]" ]
[ 729, 4 ]
[ 743, 33 ]
python
en
['en', 'error', 'th']
False
Funnelarea.showlegend
(self)
Determines whether or not an item corresponding to this trace is shown in the legend. The 'showlegend' property must be specified as a bool (either True, or False) Returns ------- bool
Determines whether or not an item corresponding to this trace is shown in the legend. The 'showlegend' property must be specified as a bool (either True, or False)
def showlegend(self): """ Determines whether or not an item corresponding to this trace is shown in the legend. The 'showlegend' property must be specified as a bool (either True, or False) Returns ------- bool """ return self["showle...
[ "def", "showlegend", "(", "self", ")", ":", "return", "self", "[", "\"showlegend\"", "]" ]
[ 752, 4 ]
[ 764, 33 ]
python
en
['en', 'error', 'th']
False
Funnelarea.stream
(self)
The 'stream' property is an instance of Stream that may be specified as: - An instance of :class:`plotly.graph_objs.funnelarea.Stream` - A dict of string/value properties that will be passed to the Stream constructor Supported dict properties: ...
The 'stream' property is an instance of Stream that may be specified as: - An instance of :class:`plotly.graph_objs.funnelarea.Stream` - A dict of string/value properties that will be passed to the Stream constructor Supported dict properties: ...
def stream(self): """ The 'stream' property is an instance of Stream that may be specified as: - An instance of :class:`plotly.graph_objs.funnelarea.Stream` - A dict of string/value properties that will be passed to the Stream constructor Supporte...
[ "def", "stream", "(", "self", ")", ":", "return", "self", "[", "\"stream\"", "]" ]
[ 773, 4 ]
[ 797, 29 ]
python
en
['en', 'error', 'th']
False
Funnelarea.text
(self)
Sets text elements associated with each sector. If trace `textinfo` contains a "text" flag, these elements will be seen on the chart. If trace `hoverinfo` contains a "text" flag and "hovertext" is not set, these elements will be seen in the hover labels. The 'text' ...
Sets text elements associated with each sector. If trace `textinfo` contains a "text" flag, these elements will be seen on the chart. If trace `hoverinfo` contains a "text" flag and "hovertext" is not set, these elements will be seen in the hover labels. The 'text' ...
def text(self): """ Sets text elements associated with each sector. If trace `textinfo` contains a "text" flag, these elements will be seen on the chart. If trace `hoverinfo` contains a "text" flag and "hovertext" is not set, these elements will be seen in the hover label...
[ "def", "text", "(", "self", ")", ":", "return", "self", "[", "\"text\"", "]" ]
[ 806, 4 ]
[ 821, 27 ]
python
en
['en', 'error', 'th']
False
Funnelarea.textfont
(self)
Sets the font used for `textinfo`. The 'textfont' property is an instance of Textfont that may be specified as: - An instance of :class:`plotly.graph_objs.funnelarea.Textfont` - A dict of string/value properties that will be passed to the Textfont constructo...
Sets the font used for `textinfo`. The 'textfont' property is an instance of Textfont that may be specified as: - An instance of :class:`plotly.graph_objs.funnelarea.Textfont` - A dict of string/value properties that will be passed to the Textfont constructo...
def textfont(self): """ Sets the font used for `textinfo`. The 'textfont' property is an instance of Textfont that may be specified as: - An instance of :class:`plotly.graph_objs.funnelarea.Textfont` - A dict of string/value properties that will be passed ...
[ "def", "textfont", "(", "self", ")", ":", "return", "self", "[", "\"textfont\"", "]" ]
[ 830, 4 ]
[ 877, 31 ]
python
en
['en', 'error', 'th']
False
Funnelarea.textinfo
(self)
Determines which trace information appear on the graph. The 'textinfo' property is a flaglist and may be specified as a string containing: - Any combination of ['label', 'text', 'value', 'percent'] joined with '+' characters (e.g. 'label+text') OR exactly ...
Determines which trace information appear on the graph. The 'textinfo' property is a flaglist and may be specified as a string containing: - Any combination of ['label', 'text', 'value', 'percent'] joined with '+' characters (e.g. 'label+text') OR exactly ...
def textinfo(self): """ Determines which trace information appear on the graph. The 'textinfo' property is a flaglist and may be specified as a string containing: - Any combination of ['label', 'text', 'value', 'percent'] joined with '+' characters (e.g. 'label...
[ "def", "textinfo", "(", "self", ")", ":", "return", "self", "[", "\"textinfo\"", "]" ]
[ 886, 4 ]
[ 900, 31 ]
python
en
['en', 'error', 'th']
False
Funnelarea.textposition
(self)
Specifies the location of the `textinfo`. The 'textposition' property is an enumeration that may be specified as: - One of the following enumeration values: ['inside', 'none'] - A tuple, list, or one-dimensional numpy array of the above Returns ...
Specifies the location of the `textinfo`. The 'textposition' property is an enumeration that may be specified as: - One of the following enumeration values: ['inside', 'none'] - A tuple, list, or one-dimensional numpy array of the above
def textposition(self): """ Specifies the location of the `textinfo`. The 'textposition' property is an enumeration that may be specified as: - One of the following enumeration values: ['inside', 'none'] - A tuple, list, or one-dimensional numpy array of ...
[ "def", "textposition", "(", "self", ")", ":", "return", "self", "[", "\"textposition\"", "]" ]
[ 909, 4 ]
[ 922, 35 ]
python
en
['en', 'error', 'th']
False
Funnelarea.textpositionsrc
(self)
Sets the source reference on Chart Studio Cloud for textposition . The 'textpositionsrc' property must be specified as a string or as a plotly.grid_objs.Column object Returns ------- str
Sets the source reference on Chart Studio Cloud for textposition . The 'textpositionsrc' property must be specified as a string or as a plotly.grid_objs.Column object
def textpositionsrc(self): """ Sets the source reference on Chart Studio Cloud for textposition . The 'textpositionsrc' property must be specified as a string or as a plotly.grid_objs.Column object Returns ------- str """ return self[...
[ "def", "textpositionsrc", "(", "self", ")", ":", "return", "self", "[", "\"textpositionsrc\"", "]" ]
[ 931, 4 ]
[ 943, 38 ]
python
en
['en', 'error', 'th']
False
Funnelarea.textsrc
(self)
Sets the source reference on Chart Studio Cloud for text . The 'textsrc' property must be specified as a string or as a plotly.grid_objs.Column object Returns ------- str
Sets the source reference on Chart Studio Cloud for text . The 'textsrc' property must be specified as a string or as a plotly.grid_objs.Column object
def textsrc(self): """ Sets the source reference on Chart Studio Cloud for text . The 'textsrc' property must be specified as a string or as a plotly.grid_objs.Column object Returns ------- str """ return self["textsrc"]
[ "def", "textsrc", "(", "self", ")", ":", "return", "self", "[", "\"textsrc\"", "]" ]
[ 952, 4 ]
[ 963, 30 ]
python
en
['en', 'error', 'th']
False
Funnelarea.texttemplate
(self)
Template string used for rendering the information text that appear on points. Note that this will override `textinfo`. Variables are inserted using %{variable}, for example "y: %{y}". Numbers are formatted using d3-format's syntax %{variable:d3-format}, for example "Price: %{y:...
Template string used for rendering the information text that appear on points. Note that this will override `textinfo`. Variables are inserted using %{variable}, for example "y: %{y}". Numbers are formatted using d3-format's syntax %{variable:d3-format}, for example "Price: %{y:...
def texttemplate(self): """ Template string used for rendering the information text that appear on points. Note that this will override `textinfo`. Variables are inserted using %{variable}, for example "y: %{y}". Numbers are formatted using d3-format's syntax %{variable:d...
[ "def", "texttemplate", "(", "self", ")", ":", "return", "self", "[", "\"texttemplate\"", "]" ]
[ 972, 4 ]
[ 999, 35 ]
python
en
['en', 'error', 'th']
False
Funnelarea.texttemplatesrc
(self)
Sets the source reference on Chart Studio Cloud for texttemplate . The 'texttemplatesrc' property must be specified as a string or as a plotly.grid_objs.Column object Returns ------- str
Sets the source reference on Chart Studio Cloud for texttemplate . The 'texttemplatesrc' property must be specified as a string or as a plotly.grid_objs.Column object
def texttemplatesrc(self): """ Sets the source reference on Chart Studio Cloud for texttemplate . The 'texttemplatesrc' property must be specified as a string or as a plotly.grid_objs.Column object Returns ------- str """ return self[...
[ "def", "texttemplatesrc", "(", "self", ")", ":", "return", "self", "[", "\"texttemplatesrc\"", "]" ]
[ 1008, 4 ]
[ 1020, 38 ]
python
en
['en', 'error', 'th']
False
Funnelarea.title
(self)
The 'title' property is an instance of Title that may be specified as: - An instance of :class:`plotly.graph_objs.funnelarea.Title` - A dict of string/value properties that will be passed to the Title constructor Supported dict properties: ...
The 'title' property is an instance of Title that may be specified as: - An instance of :class:`plotly.graph_objs.funnelarea.Title` - A dict of string/value properties that will be passed to the Title constructor Supported dict properties: ...
def title(self): """ The 'title' property is an instance of Title that may be specified as: - An instance of :class:`plotly.graph_objs.funnelarea.Title` - A dict of string/value properties that will be passed to the Title constructor Supported dic...
[ "def", "title", "(", "self", ")", ":", "return", "self", "[", "\"title\"", "]" ]
[ 1029, 4 ]
[ 1058, 28 ]
python
en
['en', 'error', 'th']
False
Funnelarea.uid
(self)
Assign an id to this trace, Use this to provide object constancy between traces during animations and transitions. The 'uid' property is a string and must be specified as: - A string - A number that will be converted to a string Returns ------- ...
Assign an id to this trace, Use this to provide object constancy between traces during animations and transitions. The 'uid' property is a string and must be specified as: - A string - A number that will be converted to a string
def uid(self): """ Assign an id to this trace, Use this to provide object constancy between traces during animations and transitions. The 'uid' property is a string and must be specified as: - A string - A number that will be converted to a string Return...
[ "def", "uid", "(", "self", ")", ":", "return", "self", "[", "\"uid\"", "]" ]
[ 1067, 4 ]
[ 1080, 26 ]
python
en
['en', 'error', 'th']
False
Funnelarea.uirevision
(self)
Controls persistence of some user-driven changes to the trace: `constraintrange` in `parcoords` traces, as well as some `editable: true` modifications such as `name` and `colorbar.title`. Defaults to `layout.uirevision`. Note that other user-driven trace attribute changes are co...
Controls persistence of some user-driven changes to the trace: `constraintrange` in `parcoords` traces, as well as some `editable: true` modifications such as `name` and `colorbar.title`. Defaults to `layout.uirevision`. Note that other user-driven trace attribute changes are co...
def uirevision(self): """ Controls persistence of some user-driven changes to the trace: `constraintrange` in `parcoords` traces, as well as some `editable: true` modifications such as `name` and `colorbar.title`. Defaults to `layout.uirevision`. Note that other user-driv...
[ "def", "uirevision", "(", "self", ")", ":", "return", "self", "[", "\"uirevision\"", "]" ]
[ 1089, 4 ]
[ 1113, 33 ]
python
en
['en', 'error', 'th']
False
Funnelarea.values
(self)
Sets the values of the sectors. If omitted, we count occurrences of each label. The 'values' property is an array that may be specified as a tuple, list, numpy array, or pandas Series Returns ------- numpy.ndarray
Sets the values of the sectors. If omitted, we count occurrences of each label. The 'values' property is an array that may be specified as a tuple, list, numpy array, or pandas Series
def values(self): """ Sets the values of the sectors. If omitted, we count occurrences of each label. The 'values' property is an array that may be specified as a tuple, list, numpy array, or pandas Series Returns ------- numpy.ndarray """ ...
[ "def", "values", "(", "self", ")", ":", "return", "self", "[", "\"values\"", "]" ]
[ 1122, 4 ]
[ 1134, 29 ]
python
en
['en', 'error', 'th']
False
Funnelarea.valuessrc
(self)
Sets the source reference on Chart Studio Cloud for values . The 'valuessrc' property must be specified as a string or as a plotly.grid_objs.Column object Returns ------- str
Sets the source reference on Chart Studio Cloud for values . The 'valuessrc' property must be specified as a string or as a plotly.grid_objs.Column object
def valuessrc(self): """ Sets the source reference on Chart Studio Cloud for values . The 'valuessrc' property must be specified as a string or as a plotly.grid_objs.Column object Returns ------- str """ return self["valuessrc"]
[ "def", "valuessrc", "(", "self", ")", ":", "return", "self", "[", "\"valuessrc\"", "]" ]
[ 1143, 4 ]
[ 1154, 32 ]
python
en
['en', 'error', 'th']
False
Funnelarea.visible
(self)
Determines whether or not this trace is visible. If "legendonly", the trace is not drawn, but can appear as a legend item (provided that the legend itself is visible). The 'visible' property is an enumeration that may be specified as: - One of the following enumeration va...
Determines whether or not this trace is visible. If "legendonly", the trace is not drawn, but can appear as a legend item (provided that the legend itself is visible). The 'visible' property is an enumeration that may be specified as: - One of the following enumeration va...
def visible(self): """ Determines whether or not this trace is visible. If "legendonly", the trace is not drawn, but can appear as a legend item (provided that the legend itself is visible). The 'visible' property is an enumeration that may be specified as: - One o...
[ "def", "visible", "(", "self", ")", ":", "return", "self", "[", "\"visible\"", "]" ]
[ 1163, 4 ]
[ 1177, 30 ]
python
en
['en', 'error', 'th']
False
Funnelarea.__init__
( self, arg=None, aspectratio=None, baseratio=None, customdata=None, customdatasrc=None, dlabel=None, domain=None, hoverinfo=None, hoverinfosrc=None, hoverlabel=None, hovertemplate=None, hovertemplatesrc=None, ...
Construct a new Funnelarea object Visualize stages in a process using area-encoded trapezoids. This trace can be used to show data in a part-to-whole representation similar to a "pie" trace, wherein each item appears in a single stage. See also the "funnel" trace type f...
Construct a new Funnelarea object Visualize stages in a process using area-encoded trapezoids. This trace can be used to show data in a part-to-whole representation similar to a "pie" trace, wherein each item appears in a single stage. See also the "funnel" trace type f...
def __init__( self, arg=None, aspectratio=None, baseratio=None, customdata=None, customdatasrc=None, dlabel=None, domain=None, hoverinfo=None, hoverinfosrc=None, hoverlabel=None, hovertemplate=None, hovertemplatesrc=...
[ "def", "__init__", "(", "self", ",", "arg", "=", "None", ",", "aspectratio", "=", "None", ",", "baseratio", "=", "None", ",", "customdata", "=", "None", ",", "customdatasrc", "=", "None", ",", "dlabel", "=", "None", ",", "domain", "=", "None", ",", "...
[ 1398, 4 ]
[ 1876, 34 ]
python
en
['en', 'error', 'th']
False
test_state_proof_returned_for_missing_attr
(looper, nodeSetWithOneNodeResponding, attributeName, sdk_pool_handle, sdk_wallet_endorser)
Tests that state proof is returned in the reply for GET_ATTR transactions
Tests that state proof is returned in the reply for GET_ATTR transactions
def test_state_proof_returned_for_missing_attr(looper, nodeSetWithOneNodeResponding, attributeName, sdk_pool_handle, sdk_wallet_endorser): """ Tests that state proof is re...
[ "def", "test_state_proof_returned_for_missing_attr", "(", "looper", ",", "nodeSetWithOneNodeResponding", ",", "attributeName", ",", "sdk_pool_handle", ",", "sdk_wallet_endorser", ")", ":", "_", ",", "dest", "=", "sdk_wallet_endorser", "get_attr_operation", "=", "{", "TARG...
[ 24, 0 ]
[ 40, 41 ]
python
en
['en', 'error', 'th']
False
test_state_proof_returned_for_missing_nym
(looper, nodeSetWithOneNodeResponding, sdk_pool_handle, sdk_wallet_endorser, sdk_user_wallet_a)
Tests that state proof is returned in the reply for GET_NYM transactions
Tests that state proof is returned in the reply for GET_NYM transactions
def test_state_proof_returned_for_missing_nym(looper, nodeSetWithOneNodeResponding, sdk_pool_handle, sdk_wallet_endorser, sdk_user_wallet_a): """ Tests that state proof is re...
[ "def", "test_state_proof_returned_for_missing_nym", "(", "looper", ",", "nodeSetWithOneNodeResponding", ",", "sdk_pool_handle", ",", "sdk_wallet_endorser", ",", "sdk_user_wallet_a", ")", ":", "# Make not existing id", "_", ",", "dest", "=", "sdk_user_wallet_a", "dest", "=",...
[ 43, 0 ]
[ 62, 41 ]
python
en
['en', 'error', 'th']
False
test_state_proof_returned_for_missing_schema
(looper, nodeSetWithOneNodeResponding, sdk_pool_handle, sdk_wallet_endorser)
Tests that state proof is returned in the reply for GET_SCHEMA transactions
Tests that state proof is returned in the reply for GET_SCHEMA transactions
def test_state_proof_returned_for_missing_schema(looper, nodeSetWithOneNodeResponding, sdk_pool_handle, sdk_wallet_endorser): """ Tests that state proof is returned in the reply for GET_SCHEMA transactions """ ...
[ "def", "test_state_proof_returned_for_missing_schema", "(", "looper", ",", "nodeSetWithOneNodeResponding", ",", "sdk_pool_handle", ",", "sdk_wallet_endorser", ")", ":", "_", ",", "dest", "=", "sdk_wallet_endorser", "schema_name", "=", "\"test_schema\"", "schema_version", "=...
[ 65, 0 ]
[ 86, 29 ]
python
en
['en', 'error', 'th']
False
test_state_proof_returned_for_missing_claim_def
(looper, nodeSetWithOneNodeResponding, sdk_pool_handle, sdk_wallet_endorser)
Tests that state proof is returned in the reply for GET_CLAIM_DEF transactions
Tests that state proof is returned in the reply for GET_CLAIM_DEF transactions
def test_state_proof_returned_for_missing_claim_def(looper, nodeSetWithOneNodeResponding, sdk_pool_handle, sdk_wallet_endorser): """ Tests that state proof is returned in the reply for GET_CLAIM_DEF trans...
[ "def", "test_state_proof_returned_for_missing_claim_def", "(", "looper", ",", "nodeSetWithOneNodeResponding", ",", "sdk_pool_handle", ",", "sdk_wallet_endorser", ")", ":", "_", ",", "dest", "=", "sdk_wallet_endorser", "get_claim_def_operation", "=", "{", "CLAIM_DEF_FROM", "...
[ 89, 0 ]
[ 106, 41 ]
python
en
['en', 'error', 'th']
False
test_state_proof_returned_for_missing_get_rich_schema_obj_by_id
(looper, nodeSetWithOneNodeResponding, sdk_wallet_endorser, sdk_pool_handle, ...
Tests that state proof is returned in the reply for GET_RICH_SCHEMA_OBJECT_BY_ID. Use different submitter and reader!
Tests that state proof is returned in the reply for GET_RICH_SCHEMA_OBJECT_BY_ID. Use different submitter and reader!
def test_state_proof_returned_for_missing_get_rich_schema_obj_by_id(looper, nodeSetWithOneNodeResponding, sdk_wallet_endorser, ...
[ "def", "test_state_proof_returned_for_missing_get_rich_schema_obj_by_id", "(", "looper", ",", "nodeSetWithOneNodeResponding", ",", "sdk_wallet_endorser", ",", "sdk_pool_handle", ",", "sdk_wallet_client", ")", ":", "rs_id", "=", "randomString", "(", ")", "get_rich_schema_by_id_o...
[ 112, 0 ]
[ 130, 41 ]
python
en
['en', 'error', 'th']
False
test_state_proof_returned_for_missing_get_rich_schema_obj_by_metadata
(looper, nodeSetWithOneNodeResponding, sdk_wallet_endorser, sdk_pool_handle, ...
Tests that state proof is returned in the reply for GET_RICH_SCHEMA_OBJECT_BY_ID. Use different submitter and reader!
Tests that state proof is returned in the reply for GET_RICH_SCHEMA_OBJECT_BY_ID. Use different submitter and reader!
def test_state_proof_returned_for_missing_get_rich_schema_obj_by_metadata(looper, nodeSetWithOneNodeResponding, sdk_wallet_endorser, ...
[ "def", "test_state_proof_returned_for_missing_get_rich_schema_obj_by_metadata", "(", "looper", ",", "nodeSetWithOneNodeResponding", ",", "sdk_wallet_endorser", ",", "sdk_pool_handle", ",", "sdk_wallet_client", ",", "rs_type", ")", ":", "rs_name", "=", "randomString", "(", ")"...
[ 139, 0 ]
[ 160, 41 ]
python
en
['en', 'error', 'th']
False
map_face2color
(face, colormap, scale, vmin, vmax)
Normalize facecolor values by vmin/vmax and return rgb-color strings This function takes a tuple color along with a colormap and a minimum (vmin) and maximum (vmax) range of possible mean distances for the given parametrized surface. It returns an rgb color based on the mean distance between vmin ...
Normalize facecolor values by vmin/vmax and return rgb-color strings
def map_face2color(face, colormap, scale, vmin, vmax): """ Normalize facecolor values by vmin/vmax and return rgb-color strings This function takes a tuple color along with a colormap and a minimum (vmin) and maximum (vmax) range of possible mean distances for the given parametrized surface. It ret...
[ "def", "map_face2color", "(", "face", ",", "colormap", ",", "scale", ",", "vmin", ",", "vmax", ")", ":", "if", "vmin", ">=", "vmax", ":", "raise", "exceptions", ".", "PlotlyError", "(", "\"Incorrect relation between vmin \"", "\"and vmax. The vmin value cannot be \"...
[ 9, 0 ]
[ 74, 25 ]
python
en
['en', 'error', 'th']
False
trisurf
( x, y, z, simplices, show_colorbar, edges_color, scale, colormap=None, color_func=None, plot_edges=False, x_edge=None, y_edge=None, z_edge=None, facecolor=None, )
Refer to FigureFactory.create_trisurf() for docstring
Refer to FigureFactory.create_trisurf() for docstring
def trisurf( x, y, z, simplices, show_colorbar, edges_color, scale, colormap=None, color_func=None, plot_edges=False, x_edge=None, y_edge=None, z_edge=None, facecolor=None, ): """ Refer to FigureFactory.create_trisurf() for docstring """ # numpy im...
[ "def", "trisurf", "(", "x", ",", "y", ",", "z", ",", "simplices", ",", "show_colorbar", ",", "edges_color", ",", "scale", ",", "colormap", "=", "None", ",", "color_func", "=", "None", ",", "plot_edges", "=", "False", ",", "x_edge", "=", "None", ",", ...
[ 77, 0 ]
[ 243, 33 ]
python
en
['en', 'error', 'th']
False
create_trisurf
( x, y, z, simplices, colormap=None, show_colorbar=True, scale=None, color_func=None, title="Trisurf Plot", plot_edges=True, showbackground=True, backgroundcolor="rgb(230, 230, 230)", gridcolor="rgb(255, 255, 255)", zerolinecolor="rgb(255, 255, 255)", edges_co...
Returns figure for a triangulated surface plot :param (array) x: data values of x in a 1D array :param (array) y: data values of y in a 1D array :param (array) z: data values of z in a 1D array :param (array) simplices: an array of shape (ntri, 3) where ntri is the number of triangles in t...
Returns figure for a triangulated surface plot
def create_trisurf( x, y, z, simplices, colormap=None, show_colorbar=True, scale=None, color_func=None, title="Trisurf Plot", plot_edges=True, showbackground=True, backgroundcolor="rgb(230, 230, 230)", gridcolor="rgb(255, 255, 255)", zerolinecolor="rgb(255, 255, 2...
[ "def", "create_trisurf", "(", "x", ",", "y", ",", "z", ",", "simplices", ",", "colormap", "=", "None", ",", "show_colorbar", "=", "True", ",", "scale", "=", "None", ",", "color_func", "=", "None", ",", "title", "=", "\"Trisurf Plot\"", ",", "plot_edges",...
[ 246, 0 ]
[ 510, 55 ]
python
en
['en', 'error', 'th']
False
Line.color
(self)
Sets the color of the contour level. Has no effect if `contours.coloring` is set to "lines". The 'color' property is a color and may be specified as: - A hex string (e.g. '#ff0000') - An rgb/rgba string (e.g. 'rgb(255,0,0)') - An hsl/hsla string (e.g. 'hsl(0,1...
Sets the color of the contour level. Has no effect if `contours.coloring` is set to "lines". The 'color' property is a color and may be specified as: - A hex string (e.g. '#ff0000') - An rgb/rgba string (e.g. 'rgb(255,0,0)') - An hsl/hsla string (e.g. 'hsl(0,1...
def color(self): """ Sets the color of the contour level. Has no effect if `contours.coloring` is set to "lines". The 'color' property is a color and may be specified as: - A hex string (e.g. '#ff0000') - An rgb/rgba string (e.g. 'rgb(255,0,0)') - An hs...
[ "def", "color", "(", "self", ")", ":", "return", "self", "[", "\"color\"", "]" ]
[ 15, 4 ]
[ 66, 28 ]
python
en
['en', 'error', 'th']
False
Line.dash
(self)
Sets the dash style of lines. Set to a dash type string ("solid", "dot", "dash", "longdash", "dashdot", or "longdashdot") or a dash length list in px (eg "5px,10px,2px,2px"). The 'dash' property is an enumeration that may be specified as: - One of the following da...
Sets the dash style of lines. Set to a dash type string ("solid", "dot", "dash", "longdash", "dashdot", or "longdashdot") or a dash length list in px (eg "5px,10px,2px,2px"). The 'dash' property is an enumeration that may be specified as: - One of the following da...
def dash(self): """ Sets the dash style of lines. Set to a dash type string ("solid", "dot", "dash", "longdash", "dashdot", or "longdashdot") or a dash length list in px (eg "5px,10px,2px,2px"). The 'dash' property is an enumeration that may be specified as: ...
[ "def", "dash", "(", "self", ")", ":", "return", "self", "[", "\"dash\"", "]" ]
[ 75, 4 ]
[ 92, 27 ]
python
en
['en', 'error', 'th']
False
Line.smoothing
(self)
Sets the amount of smoothing for the contour lines, where 0 corresponds to no smoothing. The 'smoothing' property is a number and may be specified as: - An int or float in the interval [0, 1.3] Returns ------- int|float
Sets the amount of smoothing for the contour lines, where 0 corresponds to no smoothing. The 'smoothing' property is a number and may be specified as: - An int or float in the interval [0, 1.3]
def smoothing(self): """ Sets the amount of smoothing for the contour lines, where 0 corresponds to no smoothing. The 'smoothing' property is a number and may be specified as: - An int or float in the interval [0, 1.3] Returns ------- int|float ...
[ "def", "smoothing", "(", "self", ")", ":", "return", "self", "[", "\"smoothing\"", "]" ]
[ 101, 4 ]
[ 113, 32 ]
python
en
['en', 'error', 'th']
False
Line.width
(self)
Sets the contour line width in (in px) The 'width' property is a number and may be specified as: - An int or float in the interval [0, inf] Returns ------- int|float
Sets the contour line width in (in px) The 'width' property is a number and may be specified as: - An int or float in the interval [0, inf]
def width(self): """ Sets the contour line width in (in px) The 'width' property is a number and may be specified as: - An int or float in the interval [0, inf] Returns ------- int|float """ return self["width"]
[ "def", "width", "(", "self", ")", ":", "return", "self", "[", "\"width\"", "]" ]
[ 122, 4 ]
[ 133, 28 ]
python
en
['en', 'error', 'th']
False
Line.__init__
( self, arg=None, color=None, dash=None, smoothing=None, width=None, **kwargs )
Construct a new Line object Parameters ---------- arg dict of properties compatible with this constructor or an instance of :class:`plotly.graph_objs.histogram2dcontour.Line` color Sets the color of the contour level. Has ...
Construct a new Line object Parameters ---------- arg dict of properties compatible with this constructor or an instance of :class:`plotly.graph_objs.histogram2dcontour.Line` color Sets the color of the contour level. Has ...
def __init__( self, arg=None, color=None, dash=None, smoothing=None, width=None, **kwargs ): """ Construct a new Line object Parameters ---------- arg dict of properties compatible with this constructor or an instance of :c...
[ "def", "__init__", "(", "self", ",", "arg", "=", "None", ",", "color", "=", "None", ",", "dash", "=", "None", ",", "smoothing", "=", "None", ",", "width", "=", "None", ",", "*", "*", "kwargs", ")", ":", "super", "(", "Line", ",", "self", ")", "...
[ 159, 4 ]
[ 241, 34 ]
python
en
['en', 'error', 'th']
False
create_quiver
( x, y, u, v, scale=0.1, arrow_scale=0.3, angle=math.pi / 9, scaleratio=None, **kwargs )
Returns data for a quiver plot. :param (list|ndarray) x: x coordinates of the arrow locations :param (list|ndarray) y: y coordinates of the arrow locations :param (list|ndarray) u: x components of the arrow vectors :param (list|ndarray) v: y components of the arrow vectors :param (float in [0,...
Returns data for a quiver plot.
def create_quiver( x, y, u, v, scale=0.1, arrow_scale=0.3, angle=math.pi / 9, scaleratio=None, **kwargs ): """ Returns data for a quiver plot. :param (list|ndarray) x: x coordinates of the arrow locations :param (list|ndarray) y: y coordinates of the arrow locations :param (list|ndarray) u: x c...
[ "def", "create_quiver", "(", "x", ",", "y", ",", "u", ",", "v", ",", "scale", "=", "0.1", ",", "arrow_scale", "=", "0.3", ",", "angle", "=", "math", ".", "pi", "/", "9", ",", "scaleratio", "=", "None", ",", "*", "*", "kwargs", ")", ":", "utils"...
[ 9, 0 ]
[ 123, 54 ]
python
en
['en', 'error', 'th']
False
_Quiver.scale_uv
(self)
Scales u and v to avoid overlap of the arrows. u and v are added to x and y to get the endpoints of the arrows so a smaller scale value will result in less overlap of arrows.
Scales u and v to avoid overlap of the arrows.
def scale_uv(self): """ Scales u and v to avoid overlap of the arrows. u and v are added to x and y to get the endpoints of the arrows so a smaller scale value will result in less overlap of arrows. """ self.u = [i * self.scale * self.scaleratio for i in self.u] ...
[ "def", "scale_uv", "(", "self", ")", ":", "self", ".", "u", "=", "[", "i", "*", "self", ".", "scale", "*", "self", ".", "scaleratio", "for", "i", "in", "self", ".", "u", "]", "self", ".", "v", "=", "[", "i", "*", "self", ".", "scale", "for", ...
[ 166, 4 ]
[ 175, 49 ]
python
en
['en', 'error', 'th']
False
_Quiver.get_barbs
(self)
Creates x and y startpoint and endpoint pairs After finding the endpoint of each barb this zips startpoint and endpoint pairs to create 2 lists: x_values for barbs and y values for barbs :rtype: (list, list) barb_x, barb_y: list of startpoint and endpoint x_value p...
Creates x and y startpoint and endpoint pairs
def get_barbs(self): """ Creates x and y startpoint and endpoint pairs After finding the endpoint of each barb this zips startpoint and endpoint pairs to create 2 lists: x_values for barbs and y values for barbs :rtype: (list, list) barb_x, barb_y: list of startpoint an...
[ "def", "get_barbs", "(", "self", ")", ":", "self", ".", "end_x", "=", "[", "i", "+", "j", "for", "i", ",", "j", "in", "zip", "(", "self", ".", "x", ",", "self", ".", "u", ")", "]", "self", ".", "end_y", "=", "[", "i", "+", "j", "for", "i"...
[ 177, 4 ]
[ 195, 29 ]
python
en
['en', 'error', 'th']
False
_Quiver.get_quiver_arrows
(self)
Creates lists of x and y values to plot the arrows Gets length of each barb then calculates the length of each side of the arrow. Gets angle of barb and applies angle to each side of the arrowhead. Next uses arrow_scale to scale the length of arrowhead and creates x and y value...
Creates lists of x and y values to plot the arrows
def get_quiver_arrows(self): """ Creates lists of x and y values to plot the arrows Gets length of each barb then calculates the length of each side of the arrow. Gets angle of barb and applies angle to each side of the arrowhead. Next uses arrow_scale to scale the length of arr...
[ "def", "get_quiver_arrows", "(", "self", ")", ":", "dif_x", "=", "[", "i", "-", "j", "for", "i", ",", "j", "in", "zip", "(", "self", ".", "end_x", ",", "self", ".", "x", ")", "]", "dif_y", "=", "[", "i", "-", "j", "for", "i", ",", "j", "in"...
[ 197, 4 ]
[ 266, 31 ]
python
en
['en', 'error', 'th']
False
Tickfont.color
(self)
The 'color' property is a color and may be specified as: - A hex string (e.g. '#ff0000') - An rgb/rgba string (e.g. 'rgb(255,0,0)') - An hsl/hsla string (e.g. 'hsl(0,100%,50%)') - An hsv/hsva string (e.g. 'hsv(0,100%,100%)') - A named CSS color: ...
The 'color' property is a color and may be specified as: - A hex string (e.g. '#ff0000') - An rgb/rgba string (e.g. 'rgb(255,0,0)') - An hsl/hsla string (e.g. 'hsl(0,100%,50%)') - An hsv/hsva string (e.g. 'hsv(0,100%,100%)') - A named CSS color: ...
def color(self): """ The 'color' property is a color and may be specified as: - A hex string (e.g. '#ff0000') - An rgb/rgba string (e.g. 'rgb(255,0,0)') - An hsl/hsla string (e.g. 'hsl(0,100%,50%)') - An hsv/hsva string (e.g. 'hsv(0,100%,100%)') - A name...
[ "def", "color", "(", "self", ")", ":", "return", "self", "[", "\"color\"", "]" ]
[ 15, 4 ]
[ 63, 28 ]
python
en
['en', 'error', 'th']
False
Tickfont.family
(self)
HTML font family - the typeface that will be applied by the web browser. The web browser will only be able to apply a font if it is available on the system which it operates. Provide multiple font families, separated by commas, to indicate the preference in which to apply fonts ...
HTML font family - the typeface that will be applied by the web browser. The web browser will only be able to apply a font if it is available on the system which it operates. Provide multiple font families, separated by commas, to indicate the preference in which to apply fonts ...
def family(self): """ HTML font family - the typeface that will be applied by the web browser. The web browser will only be able to apply a font if it is available on the system which it operates. Provide multiple font families, separated by commas, to indicate the prefer...
[ "def", "family", "(", "self", ")", ":", "return", "self", "[", "\"family\"", "]" ]
[ 72, 4 ]
[ 94, 29 ]
python
en
['en', 'error', 'th']
False
Tickfont.size
(self)
The 'size' property is a number and may be specified as: - An int or float in the interval [1, inf] Returns ------- int|float
The 'size' property is a number and may be specified as: - An int or float in the interval [1, inf]
def size(self): """ The 'size' property is a number and may be specified as: - An int or float in the interval [1, inf] Returns ------- int|float """ return self["size"]
[ "def", "size", "(", "self", ")", ":", "return", "self", "[", "\"size\"", "]" ]
[ 103, 4 ]
[ 112, 27 ]
python
en
['en', 'error', 'th']
False
Tickfont.__init__
(self, arg=None, color=None, family=None, size=None, **kwargs)
Construct a new Tickfont object Sets the color bar's tick label font Parameters ---------- arg dict of properties compatible with this constructor or an instance of :class:`plotly.graph_objs.surface.colorbar.Tickfont` color ...
Construct a new Tickfont object Sets the color bar's tick label font
def __init__(self, arg=None, color=None, family=None, size=None, **kwargs): """ Construct a new Tickfont object Sets the color bar's tick label font Parameters ---------- arg dict of properties compatible with this constructor or an insta...
[ "def", "__init__", "(", "self", ",", "arg", "=", "None", ",", "color", "=", "None", ",", "family", "=", "None", ",", "size", "=", "None", ",", "*", "*", "kwargs", ")", ":", "super", "(", "Tickfont", ",", "self", ")", ".", "__init__", "(", "\"tick...
[ 143, 4 ]
[ 226, 34 ]
python
en
['en', 'error', 'th']
False
OeTeacher.next_example
(self)
Returns the next example from this dataset after starting to queue up the next example.
Returns the next example from this dataset after starting to queue up the next example.
def next_example(self): """ Returns the next example from this dataset after starting to queue up the next example. """ ready = None # pull up the currently queued example if self.example is not None: if self.image_mode != 'no_image_model': ...
[ "def", "next_example", "(", "self", ")", ":", "ready", "=", "None", "# pull up the currently queued example", "if", "self", ".", "example", "is", "not", "None", ":", "if", "self", ".", "image_mode", "!=", "'no_image_model'", ":", "# move the image we loaded in the b...
[ 108, 4 ]
[ 131, 24 ]
python
en
['en', 'error', 'th']
False
_get_rand_id
()
:return: The string of a random id using uuid4
:return: The string of a random id using uuid4
def _get_rand_id(): """ :return: The string of a random id using uuid4 """ return str(uuid.uuid4())
[ "def", "_get_rand_id", "(", ")", ":", "return", "str", "(", "uuid", ".", "uuid4", "(", ")", ")" ]
[ 14, 0 ]
[ 18, 28 ]
python
en
['en', 'error', 'th']
False
_prBlueBG
(text)
Print given in text with a blue background. :param text: The text to be printed
Print given in text with a blue background.
def _prBlueBG(text): """ Print given in text with a blue background. :param text: The text to be printed """ print("\033[44m{}\033[0m".format(text), sep="")
[ "def", "_prBlueBG", "(", "text", ")", ":", "print", "(", "\"\\033[44m{}\\033[0m\"", ".", "format", "(", "text", ")", ",", "sep", "=", "\"\"", ")" ]
[ 21, 0 ]
[ 27, 51 ]
python
en
['en', 'error', 'th']
False
on_message
(ws, message)
Prints the incoming message from the server. :param ws: a WebSocketApp :param message: json with 'text' field to be printed
Prints the incoming message from the server.
def on_message(ws, message): """ Prints the incoming message from the server. :param ws: a WebSocketApp :param message: json with 'text' field to be printed """ incoming_message = json.loads(message) print("\033[0m\n") print("Bot: " + incoming_message['text']) quick_replies = incomi...
[ "def", "on_message", "(", "ws", ",", "message", ")", ":", "incoming_message", "=", "json", ".", "loads", "(", "message", ")", "print", "(", "\"\\033[0m\\n\"", ")", "print", "(", "\"Bot: \"", "+", "incoming_message", "[", "'text'", "]", ")", "quick_replies", ...
[ 30, 0 ]
[ 43, 23 ]
python
en
['en', 'error', 'th']
False
on_error
(ws, error)
Prints an error, if occurs. :param ws: WebSocketApp :param error: An error
Prints an error, if occurs.
def on_error(ws, error): """ Prints an error, if occurs. :param ws: WebSocketApp :param error: An error """ print(error)
[ "def", "on_error", "(", "ws", ",", "error", ")", ":", "print", "(", "error", ")" ]
[ 46, 0 ]
[ 53, 16 ]
python
en
['en', 'error', 'th']
False
on_close
(ws)
Cleanup before closing connection. :param ws: WebSocketApp
Cleanup before closing connection.
def on_close(ws): """ Cleanup before closing connection. :param ws: WebSocketApp """ # Reset color formatting if necessary print("\033[0m") print("Connection closed")
[ "def", "on_close", "(", "ws", ")", ":", "# Reset color formatting if necessary", "print", "(", "\"\\033[0m\"", ")", "print", "(", "\"Connection closed\"", ")" ]
[ 56, 0 ]
[ 64, 30 ]
python
en
['en', 'error', 'th']
False
_run
(ws, id)
Takes user input and sends it to a websocket. :param ws: websocket.WebSocketApp
Takes user input and sends it to a websocket.
def _run(ws, id): """ Takes user input and sends it to a websocket. :param ws: websocket.WebSocketApp """ while True: x = input("\033[44m Me: ") print("\033[0m", end="") data = {} data['id'] = id data['text'] = x json_data = json.dumps(data) w...
[ "def", "_run", "(", "ws", ",", "id", ")", ":", "while", "True", ":", "x", "=", "input", "(", "\"\\033[44m Me: \"", ")", "print", "(", "\"\\033[0m\"", ",", "end", "=", "\"\"", ")", "data", "=", "{", "}", "data", "[", "'id'", "]", "=", "id", "data"...
[ 67, 0 ]
[ 84, 14 ]
python
en
['en', 'error', 'th']
False
on_open
(ws)
Starts a new thread that loops, taking user input and sending it to the websocket. :param ws: websocket.WebSocketApp that sends messages to a terminal_manager
Starts a new thread that loops, taking user input and sending it to the websocket.
def on_open(ws): """ Starts a new thread that loops, taking user input and sending it to the websocket. :param ws: websocket.WebSocketApp that sends messages to a terminal_manager """ id = _get_rand_id() threading.Thread(target=_run, args=(ws, id)).start()
[ "def", "on_open", "(", "ws", ")", ":", "id", "=", "_get_rand_id", "(", ")", "threading", ".", "Thread", "(", "target", "=", "_run", ",", "args", "=", "(", "ws", ",", "id", ")", ")", ".", "start", "(", ")" ]
[ 87, 0 ]
[ 94, 56 ]
python
en
['en', 'error', 'th']
False
setup_args
()
Set up args, specifically for the port number. :return: A parser that parses the port from commandline arguments.
Set up args, specifically for the port number.
def setup_args(): """ Set up args, specifically for the port number. :return: A parser that parses the port from commandline arguments. """ parser = ParlaiParser(False, False) parser_grp = parser.add_argument_group('Terminal Chat') parser_grp.add_argument( '--port', default=35496, t...
[ "def", "setup_args", "(", ")", ":", "parser", "=", "ParlaiParser", "(", "False", ",", "False", ")", "parser_grp", "=", "parser", ".", "add_argument_group", "(", "'Terminal Chat'", ")", "parser_grp", ".", "add_argument", "(", "'--port'", ",", "default", "=", ...
[ 97, 0 ]
[ 108, 30 ]
python
en
['en', 'error', 'th']
False
Line.color
(self)
Sets the line color of all decreasing values. The 'color' property is a color and may be specified as: - A hex string (e.g. '#ff0000') - An rgb/rgba string (e.g. 'rgb(255,0,0)') - An hsl/hsla string (e.g. 'hsl(0,100%,50%)') - An hsv/hsva string (e.g. 'hsv(0,...
Sets the line color of all decreasing values. The 'color' property is a color and may be specified as: - A hex string (e.g. '#ff0000') - An rgb/rgba string (e.g. 'rgb(255,0,0)') - An hsl/hsla string (e.g. 'hsl(0,100%,50%)') - An hsv/hsva string (e.g. 'hsv(0,...
def color(self): """ Sets the line color of all decreasing values. The 'color' property is a color and may be specified as: - A hex string (e.g. '#ff0000') - An rgb/rgba string (e.g. 'rgb(255,0,0)') - An hsl/hsla string (e.g. 'hsl(0,100%,50%)') - An h...
[ "def", "color", "(", "self", ")", ":", "return", "self", "[", "\"color\"", "]" ]
[ 15, 4 ]
[ 65, 28 ]
python
en
['en', 'error', 'th']
False
Line.width
(self)
Sets the line width of all decreasing values. The 'width' property is a number and may be specified as: - An int or float in the interval [0, inf] Returns ------- int|float
Sets the line width of all decreasing values. The 'width' property is a number and may be specified as: - An int or float in the interval [0, inf]
def width(self): """ Sets the line width of all decreasing values. The 'width' property is a number and may be specified as: - An int or float in the interval [0, inf] Returns ------- int|float """ return self["width"]
[ "def", "width", "(", "self", ")", ":", "return", "self", "[", "\"width\"", "]" ]
[ 74, 4 ]
[ 85, 28 ]
python
en
['en', 'error', 'th']
False
Line.__init__
(self, arg=None, color=None, width=None, **kwargs)
Construct a new Line object Parameters ---------- arg dict of properties compatible with this constructor or an instance of :class:`plotly.graph_objs.waterfall.decr easing.marker.Line` color Sets the line color of all decr...
Construct a new Line object Parameters ---------- arg dict of properties compatible with this constructor or an instance of :class:`plotly.graph_objs.waterfall.decr easing.marker.Line` color Sets the line color of all decr...
def __init__(self, arg=None, color=None, width=None, **kwargs): """ Construct a new Line object Parameters ---------- arg dict of properties compatible with this constructor or an instance of :class:`plotly.graph_objs.waterfall.decr ea...
[ "def", "__init__", "(", "self", ",", "arg", "=", "None", ",", "color", "=", "None", ",", "width", "=", "None", ",", "*", "*", "kwargs", ")", ":", "super", "(", "Line", ",", "self", ")", ".", "__init__", "(", "\"line\"", ")", "if", "\"_parent\"", ...
[ 102, 4 ]
[ 165, 34 ]
python
en
['en', 'error', 'th']
False
Hoverlabel.align
(self)
Sets the horizontal alignment of the text content within hover label box. Has an effect only if the hover label text spans more two or more lines The 'align' property is an enumeration that may be specified as: - One of the following enumeration values: ['...
Sets the horizontal alignment of the text content within hover label box. Has an effect only if the hover label text spans more two or more lines The 'align' property is an enumeration that may be specified as: - One of the following enumeration values: ['...
def align(self): """ Sets the horizontal alignment of the text content within hover label box. Has an effect only if the hover label text spans more two or more lines The 'align' property is an enumeration that may be specified as: - One of the following enumeratio...
[ "def", "align", "(", "self", ")", ":", "return", "self", "[", "\"align\"", "]" ]
[ 25, 4 ]
[ 40, 28 ]
python
en
['en', 'error', 'th']
False
Hoverlabel.alignsrc
(self)
Sets the source reference on Chart Studio Cloud for align . The 'alignsrc' property must be specified as a string or as a plotly.grid_objs.Column object Returns ------- str
Sets the source reference on Chart Studio Cloud for align . The 'alignsrc' property must be specified as a string or as a plotly.grid_objs.Column object
def alignsrc(self): """ Sets the source reference on Chart Studio Cloud for align . The 'alignsrc' property must be specified as a string or as a plotly.grid_objs.Column object Returns ------- str """ return self["alignsrc"]
[ "def", "alignsrc", "(", "self", ")", ":", "return", "self", "[", "\"alignsrc\"", "]" ]
[ 49, 4 ]
[ 60, 31 ]
python
en
['en', 'error', 'th']
False
Hoverlabel.bgcolor
(self)
Sets the background color of the hover labels for this trace The 'bgcolor' property is a color and may be specified as: - A hex string (e.g. '#ff0000') - An rgb/rgba string (e.g. 'rgb(255,0,0)') - An hsl/hsla string (e.g. 'hsl(0,100%,50%)') - An hsv/hsva str...
Sets the background color of the hover labels for this trace The 'bgcolor' property is a color and may be specified as: - A hex string (e.g. '#ff0000') - An rgb/rgba string (e.g. 'rgb(255,0,0)') - An hsl/hsla string (e.g. 'hsl(0,100%,50%)') - An hsv/hsva str...
def bgcolor(self): """ Sets the background color of the hover labels for this trace The 'bgcolor' property is a color and may be specified as: - A hex string (e.g. '#ff0000') - An rgb/rgba string (e.g. 'rgb(255,0,0)') - An hsl/hsla string (e.g. 'hsl(0,100%,50%)...
[ "def", "bgcolor", "(", "self", ")", ":", "return", "self", "[", "\"bgcolor\"", "]" ]
[ 69, 4 ]
[ 120, 30 ]
python
en
['en', 'error', 'th']
False
Hoverlabel.bgcolorsrc
(self)
Sets the source reference on Chart Studio Cloud for bgcolor . The 'bgcolorsrc' property must be specified as a string or as a plotly.grid_objs.Column object Returns ------- str
Sets the source reference on Chart Studio Cloud for bgcolor . The 'bgcolorsrc' property must be specified as a string or as a plotly.grid_objs.Column object
def bgcolorsrc(self): """ Sets the source reference on Chart Studio Cloud for bgcolor . The 'bgcolorsrc' property must be specified as a string or as a plotly.grid_objs.Column object Returns ------- str """ return self["bgcolorsrc"]
[ "def", "bgcolorsrc", "(", "self", ")", ":", "return", "self", "[", "\"bgcolorsrc\"", "]" ]
[ 129, 4 ]
[ 140, 33 ]
python
en
['en', 'error', 'th']
False
Hoverlabel.bordercolor
(self)
Sets the border color of the hover labels for this trace. The 'bordercolor' property is a color and may be specified as: - A hex string (e.g. '#ff0000') - An rgb/rgba string (e.g. 'rgb(255,0,0)') - An hsl/hsla string (e.g. 'hsl(0,100%,50%)') - An hsv/hsva st...
Sets the border color of the hover labels for this trace. The 'bordercolor' property is a color and may be specified as: - A hex string (e.g. '#ff0000') - An rgb/rgba string (e.g. 'rgb(255,0,0)') - An hsl/hsla string (e.g. 'hsl(0,100%,50%)') - An hsv/hsva st...
def bordercolor(self): """ Sets the border color of the hover labels for this trace. The 'bordercolor' property is a color and may be specified as: - A hex string (e.g. '#ff0000') - An rgb/rgba string (e.g. 'rgb(255,0,0)') - An hsl/hsla string (e.g. 'hsl(0,100%...
[ "def", "bordercolor", "(", "self", ")", ":", "return", "self", "[", "\"bordercolor\"", "]" ]
[ 149, 4 ]
[ 200, 34 ]
python
en
['en', 'error', 'th']
False
Hoverlabel.bordercolorsrc
(self)
Sets the source reference on Chart Studio Cloud for bordercolor . The 'bordercolorsrc' property must be specified as a string or as a plotly.grid_objs.Column object Returns ------- str
Sets the source reference on Chart Studio Cloud for bordercolor . The 'bordercolorsrc' property must be specified as a string or as a plotly.grid_objs.Column object
def bordercolorsrc(self): """ Sets the source reference on Chart Studio Cloud for bordercolor . The 'bordercolorsrc' property must be specified as a string or as a plotly.grid_objs.Column object Returns ------- str """ return self["bo...
[ "def", "bordercolorsrc", "(", "self", ")", ":", "return", "self", "[", "\"bordercolorsrc\"", "]" ]
[ 209, 4 ]
[ 221, 37 ]
python
en
['en', 'error', 'th']
False
Hoverlabel.font
(self)
Sets the font used in hover labels. The 'font' property is an instance of Font that may be specified as: - An instance of :class:`plotly.graph_objs.cone.hoverlabel.Font` - A dict of string/value properties that will be passed to the Font constructor ...
Sets the font used in hover labels. The 'font' property is an instance of Font that may be specified as: - An instance of :class:`plotly.graph_objs.cone.hoverlabel.Font` - A dict of string/value properties that will be passed to the Font constructor ...
def font(self): """ Sets the font used in hover labels. The 'font' property is an instance of Font that may be specified as: - An instance of :class:`plotly.graph_objs.cone.hoverlabel.Font` - A dict of string/value properties that will be passed to th...
[ "def", "font", "(", "self", ")", ":", "return", "self", "[", "\"font\"", "]" ]
[ 230, 4 ]
[ 277, 27 ]
python
en
['en', 'error', 'th']
False
Hoverlabel.namelength
(self)
Sets the default length (in number of characters) of the trace name in the hover labels for all traces. -1 shows the whole name regardless of length. 0-3 shows the first 0-3 characters, and an integer >3 will show the whole name if it is less than that many characters, but if it...
Sets the default length (in number of characters) of the trace name in the hover labels for all traces. -1 shows the whole name regardless of length. 0-3 shows the first 0-3 characters, and an integer >3 will show the whole name if it is less than that many characters, but if it...
def namelength(self): """ Sets the default length (in number of characters) of the trace name in the hover labels for all traces. -1 shows the whole name regardless of length. 0-3 shows the first 0-3 characters, and an integer >3 will show the whole name if it is less than ...
[ "def", "namelength", "(", "self", ")", ":", "return", "self", "[", "\"namelength\"", "]" ]
[ 286, 4 ]
[ 304, 33 ]
python
en
['en', 'error', 'th']
False
Hoverlabel.namelengthsrc
(self)
Sets the source reference on Chart Studio Cloud for namelength . The 'namelengthsrc' property must be specified as a string or as a plotly.grid_objs.Column object Returns ------- str
Sets the source reference on Chart Studio Cloud for namelength . The 'namelengthsrc' property must be specified as a string or as a plotly.grid_objs.Column object
def namelengthsrc(self): """ Sets the source reference on Chart Studio Cloud for namelength . The 'namelengthsrc' property must be specified as a string or as a plotly.grid_objs.Column object Returns ------- str """ return self["name...
[ "def", "namelengthsrc", "(", "self", ")", ":", "return", "self", "[", "\"namelengthsrc\"", "]" ]
[ 313, 4 ]
[ 325, 36 ]
python
en
['en', 'error', 'th']
False
Hoverlabel.__init__
( self, arg=None, align=None, alignsrc=None, bgcolor=None, bgcolorsrc=None, bordercolor=None, bordercolorsrc=None, font=None, namelength=None, namelengthsrc=None, **kwargs )
Construct a new Hoverlabel object Parameters ---------- arg dict of properties compatible with this constructor or an instance of :class:`plotly.graph_objs.cone.Hoverlabel` align Sets the horizontal alignment of the text c...
Construct a new Hoverlabel object Parameters ---------- arg dict of properties compatible with this constructor or an instance of :class:`plotly.graph_objs.cone.Hoverlabel` align Sets the horizontal alignment of the text c...
def __init__( self, arg=None, align=None, alignsrc=None, bgcolor=None, bgcolorsrc=None, bordercolor=None, bordercolorsrc=None, font=None, namelength=None, namelengthsrc=None, **kwargs ): """ Construct a n...
[ "def", "__init__", "(", "self", ",", "arg", "=", "None", ",", "align", "=", "None", ",", "alignsrc", "=", "None", ",", "bgcolor", "=", "None", ",", "bgcolorsrc", "=", "None", ",", "bordercolor", "=", "None", ",", "bordercolorsrc", "=", "None", ",", "...
[ 370, 4 ]
[ 502, 34 ]
python
en
['en', 'error', 'th']
False
async_to_sync
(func: Awaitable[R])
Wraps `asyncio.run` on an async function making it sync callable.
Wraps `asyncio.run` on an async function making it sync callable.
def async_to_sync(func: Awaitable[R]) -> R: '''Wraps `asyncio.run` on an async function making it sync callable.''' if not asyncio.iscoroutinefunction(func): raise TypeError(f"{func} is not a coroutine function") @wraps(func) def wrapper(*args, **kwargs): return asyncio.run(func(*args, ...
[ "def", "async_to_sync", "(", "func", ":", "Awaitable", "[", "R", "]", ")", "->", "R", ":", "if", "not", "asyncio", ".", "iscoroutinefunction", "(", "func", ")", ":", "raise", "TypeError", "(", "f\"{func} is not a coroutine function\"", ")", "@", "wraps", "("...
[ 192, 0 ]
[ 200, 18 ]
python
en
['en', 'gl', 'en']
True
check_if_url
(possible_url: str)
checks if input `possible_url` is and valid url. Appends "https://" in front of it beforehand. (maybe not necessary). Args: possible_url `str`: The string to check. Returns: `bool`: `True` if it is and valid url.
checks if input `possible_url` is and valid url.
def check_if_url(possible_url: str): """ checks if input `possible_url` is and valid url. Appends "https://" in front of it beforehand. (maybe not necessary). Args: possible_url `str`: The string to check. Returns: `bool`: `True` if it is and valid url. """ possible_url = ...
[ "def", "check_if_url", "(", "possible_url", ":", "str", ")", ":", "possible_url", "=", "fix_url_prefix", "(", "possible_url", ")", "try", ":", "validators", ".", "url", "(", "possible_url", ")", "return", "True", "except", "validator_collection", ".", "errors", ...
[ 459, 0 ]
[ 476, 20 ]
python
en
['en', 'error', 'th']
False
help_to_file
(in_object, out_file=None)
redirects the output of the `help` built-in function to a file. https://gist.github.com/abingham/e19cfd042fefcd11ba60 Args: in_object (`object`): the object to use as argument for `help()` out_file (`str`, optional): filepath where the output should be redirected to. Defaults to `[class_n...
redirects the output of the `help` built-in function to a file.
def help_to_file(in_object, out_file=None): """ redirects the output of the `help` built-in function to a file. https://gist.github.com/abingham/e19cfd042fefcd11ba60 Args: in_object (`object`): the object to use as argument for `help()` out_file (`str`, optional): filepath where the ou...
[ "def", "help_to_file", "(", "in_object", ",", "out_file", "=", "None", ")", ":", "out_file", "=", "f'{in_object.__class__.__name__}_help.txt'", "if", "out_file", "is", "None", "else", "pathmaker", "(", "out_file", ")", "import", "sys", "# Temporarily redirect stdout t...
[ 628, 0 ]
[ 648, 27 ]
python
en
['en', 'error', 'th']
False
BaseCache.__init__
(self)
Initialize the cache instance.
Initialize the cache instance.
def __init__(self): """Initialize the cache instance.""" self._key_locks = {}
[ "def", "__init__", "(", "self", ")", ":", "self", ".", "_key_locks", "=", "{", "}" ]
[ 16, 4 ]
[ 18, 28 ]
python
en
['en', 'en', 'en']
True
BaseCache.get
(self, key: Text)
Get an item from the cache. Args: key: the key to retrieve an item for Returns: The record found or `None`
Get an item from the cache.
async def get(self, key: Text): """ Get an item from the cache. Args: key: the key to retrieve an item for Returns: The record found or `None` """
[ "async", "def", "get", "(", "self", ",", "key", ":", "Text", ")", ":" ]
[ 21, 4 ]
[ 31, 11 ]
python
en
['en', 'error', 'th']
False
BaseCache.set
(self, keys: Union[Text, Sequence[Text]], value: Any, ttl: int = None)
Add an item to the cache with an optional ttl. Args: keys: the key or keys for which to set an item value: the value to store in the cache ttl: number of second that the record should persist
Add an item to the cache with an optional ttl.
async def set(self, keys: Union[Text, Sequence[Text]], value: Any, ttl: int = None): """ Add an item to the cache with an optional ttl. Args: keys: the key or keys for which to set an item value: the value to store in the cache ttl: number of second that the ...
[ "async", "def", "set", "(", "self", ",", "keys", ":", "Union", "[", "Text", ",", "Sequence", "[", "Text", "]", "]", ",", "value", ":", "Any", ",", "ttl", ":", "int", "=", "None", ")", ":" ]
[ 34, 4 ]
[ 43, 11 ]
python
en
['en', 'error', 'th']
False
BaseCache.clear
(self, key: Text)
Remove an item from the cache, if present. Args: key: the key to remove
Remove an item from the cache, if present.
async def clear(self, key: Text): """ Remove an item from the cache, if present. Args: key: the key to remove """
[ "async", "def", "clear", "(", "self", ",", "key", ":", "Text", ")", ":" ]
[ 46, 4 ]
[ 53, 11 ]
python
en
['en', 'error', 'th']
False
BaseCache.flush
(self)
Remove all items from the cache.
Remove all items from the cache.
async def flush(self): """Remove all items from the cache."""
[ "async", "def", "flush", "(", "self", ")", ":" ]
[ 56, 4 ]
[ 57, 46 ]
python
en
['en', 'en', 'en']
True
BaseCache.acquire
(self, key: Text)
Acquire a lock on a given cache key.
Acquire a lock on a given cache key.
def acquire(self, key: Text): """Acquire a lock on a given cache key.""" result = CacheKeyLock(self, key) first = self._key_locks.setdefault(key, result) if first is not result: result.parent = first return result
[ "def", "acquire", "(", "self", ",", "key", ":", "Text", ")", ":", "result", "=", "CacheKeyLock", "(", "self", ",", "key", ")", "first", "=", "self", ".", "_key_locks", ".", "setdefault", "(", "key", ",", "result", ")", "if", "first", "is", "not", "...
[ 59, 4 ]
[ 65, 21 ]
python
en
['en', 'en', 'en']
True
BaseCache.release
(self, key: Text)
Release the lock on a given cache key.
Release the lock on a given cache key.
def release(self, key: Text): """Release the lock on a given cache key.""" if key in self._key_locks: del self._key_locks[key]
[ "def", "release", "(", "self", ",", "key", ":", "Text", ")", ":", "if", "key", "in", "self", ".", "_key_locks", ":", "del", "self", ".", "_key_locks", "[", "key", "]" ]
[ 67, 4 ]
[ 70, 36 ]
python
en
['en', 'en', 'en']
True
BaseCache.__repr__
(self)
Human readable representation of `BaseStorageRecordSearch`.
Human readable representation of `BaseStorageRecordSearch`.
def __repr__(self) -> str: """Human readable representation of `BaseStorageRecordSearch`.""" return "<{}>".format(self.__class__.__name__)
[ "def", "__repr__", "(", "self", ")", "->", "str", ":", "return", "\"<{}>\"", ".", "format", "(", "self", ".", "__class__", ".", "__name__", ")" ]
[ 72, 4 ]
[ 74, 53 ]
python
en
['en', 'en', 'en']
True
CacheKeyLock.__init__
(self, cache: BaseCache, key: Text)
Initialize the key lock.
Initialize the key lock.
def __init__(self, cache: BaseCache, key: Text): """Initialize the key lock.""" self.cache = cache self.exception: BaseException = None self.key = key self.released = False self._future: asyncio.Future = asyncio.get_event_loop().create_future() self._parent: "Cach...
[ "def", "__init__", "(", "self", ",", "cache", ":", "BaseCache", ",", "key", ":", "Text", ")", ":", "self", ".", "cache", "=", "cache", "self", ".", "exception", ":", "BaseException", "=", "None", "self", ".", "key", "=", "key", "self", ".", "released...
[ 85, 4 ]
[ 92, 43 ]
python
en
['en', 'pl', 'en']
True
CacheKeyLock.done
(self)
Accessor for the done state.
Accessor for the done state.
def done(self) -> bool: """Accessor for the done state.""" return self._future.done()
[ "def", "done", "(", "self", ")", "->", "bool", ":", "return", "self", ".", "_future", ".", "done", "(", ")" ]
[ 95, 4 ]
[ 97, 34 ]
python
en
['en', 'en', 'en']
True
CacheKeyLock.future
(self)
Fetch the result in the form of an awaitable future.
Fetch the result in the form of an awaitable future.
def future(self) -> asyncio.Future: """Fetch the result in the form of an awaitable future.""" return self._future
[ "def", "future", "(", "self", ")", "->", "asyncio", ".", "Future", ":", "return", "self", ".", "_future" ]
[ 100, 4 ]
[ 102, 27 ]
python
en
['en', 'en', 'en']
True
CacheKeyLock.result
(self)
Fetch the current result, if any.
Fetch the current result, if any.
def result(self) -> Any: """Fetch the current result, if any.""" if self.done: return self._future.result()
[ "def", "result", "(", "self", ")", "->", "Any", ":", "if", "self", ".", "done", ":", "return", "self", ".", "_future", ".", "result", "(", ")" ]
[ 105, 4 ]
[ 108, 40 ]
python
en
['en', 'en', 'en']
True
CacheKeyLock.parent
(self)
Accessor for the parent key lock, if any.
Accessor for the parent key lock, if any.
def parent(self) -> "CacheKeyLock": """Accessor for the parent key lock, if any.""" return self._parent
[ "def", "parent", "(", "self", ")", "->", "\"CacheKeyLock\"", ":", "return", "self", ".", "_parent" ]
[ 111, 4 ]
[ 113, 27 ]
python
en
['en', 'en', 'en']
True
CacheKeyLock.parent
(self, parent: "CacheKeyLock")
Setter for the parent lock.
Setter for the parent lock.
def parent(self, parent: "CacheKeyLock"): """Setter for the parent lock.""" self._parent = parent parent._future.add_done_callback(self._handle_parent_done)
[ "def", "parent", "(", "self", ",", "parent", ":", "\"CacheKeyLock\"", ")", ":", "self", ".", "_parent", "=", "parent", "parent", ".", "_future", ".", "add_done_callback", "(", "self", ".", "_handle_parent_done", ")" ]
[ 116, 4 ]
[ 119, 66 ]
python
en
['en', 'en', 'en']
True
CacheKeyLock._handle_parent_done
(self, fut: asyncio.Future)
Handle completion of parent's future.
Handle completion of parent's future.
def _handle_parent_done(self, fut: asyncio.Future): """Handle completion of parent's future.""" result = fut.result() if result: self._future.set_result(fut.result())
[ "def", "_handle_parent_done", "(", "self", ",", "fut", ":", "asyncio", ".", "Future", ")", ":", "result", "=", "fut", ".", "result", "(", ")", "if", "result", ":", "self", ".", "_future", ".", "set_result", "(", "fut", ".", "result", "(", ")", ")" ]
[ 121, 4 ]
[ 125, 49 ]
python
en
['en', 'en', 'en']
True