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 |
|---|---|---|---|---|---|---|---|---|---|---|---|
Forward.__init__ | (self, *, to: str = None, msg: str = None, **kwargs) |
Initialize forward message object.
Args:
to (str): Recipient DID
msg (str): Message content
|
Initialize forward message object. | def __init__(self, *, to: str = None, msg: str = None, **kwargs):
"""
Initialize forward message object.
Args:
to (str): Recipient DID
msg (str): Message content
"""
super(Forward, self).__init__(**kwargs)
self.to = to
self.msg = msg | [
"def",
"__init__",
"(",
"self",
",",
"*",
",",
"to",
":",
"str",
"=",
"None",
",",
"msg",
":",
"str",
"=",
"None",
",",
"*",
"*",
"kwargs",
")",
":",
"super",
"(",
"Forward",
",",
"self",
")",
".",
"__init__",
"(",
"*",
"*",
"kwargs",
")",
"s... | [
21,
4
] | [
31,
22
] | python | en | ['en', 'error', 'th'] | False |
c_login | (client) | logins to the game | logins to the game | def c_login(client):
"logins to the game"
# we always use a new client name
cname = DUMMY_NAME % client.gid
cpwd = DUMMY_PWD % client.gid
# set up for digging a first room (to move to and keep the
# login room clean)
roomname = ROOM_TEMPLATE % client.counter()
exitname1 = EXIT_TEMPLATE ... | [
"def",
"c_login",
"(",
"client",
")",
":",
"# we always use a new client name",
"cname",
"=",
"DUMMY_NAME",
"%",
"client",
".",
"gid",
"cpwd",
"=",
"DUMMY_PWD",
"%",
"client",
".",
"gid",
"# set up for digging a first room (to move to and keep the",
"# login room clean)",... | [
91,
0
] | [
110,
15
] | python | en | ['en', 'en', 'en'] | True |
c_login_nodig | (client) | logins, don't dig its own room | logins, don't dig its own room | def c_login_nodig(client):
"logins, don't dig its own room"
cname = DUMMY_NAME % client.gid
cpwd = DUMMY_PWD % client.gid
cmds = ('create %s %s' % (cname, cpwd),
'connect %s %s' % (cname, cpwd))
return cmds | [
"def",
"c_login_nodig",
"(",
"client",
")",
":",
"cname",
"=",
"DUMMY_NAME",
"%",
"client",
".",
"gid",
"cpwd",
"=",
"DUMMY_PWD",
"%",
"client",
".",
"gid",
"cmds",
"=",
"(",
"'create %s %s'",
"%",
"(",
"cname",
",",
"cpwd",
")",
",",
"'connect %s %s'",
... | [
113,
0
] | [
120,
15
] | python | en | ['en', 'da', 'en'] | True |
c_logout | (client) | logouts of the game | logouts of the game | def c_logout(client):
"logouts of the game"
return "@quit" | [
"def",
"c_logout",
"(",
"client",
")",
":",
"return",
"\"@quit\""
] | [
123,
0
] | [
125,
18
] | python | en | ['en', 'en', 'en'] | True |
c_looks | (client) | looks at various objects | looks at various objects | def c_looks(client):
"looks at various objects"
cmds = ["look %s" % obj for obj in client.objs]
if not cmds:
cmds = ["look %s" % exi for exi in client.exits]
if not cmds:
cmds = "look"
return cmds | [
"def",
"c_looks",
"(",
"client",
")",
":",
"cmds",
"=",
"[",
"\"look %s\"",
"%",
"obj",
"for",
"obj",
"in",
"client",
".",
"objs",
"]",
"if",
"not",
"cmds",
":",
"cmds",
"=",
"[",
"\"look %s\"",
"%",
"exi",
"for",
"exi",
"in",
"client",
".",
"exits... | [
130,
0
] | [
137,
15
] | python | en | ['en', 'en', 'en'] | True |
c_examines | (client) | examines various objects | examines various objects | def c_examines(client):
"examines various objects"
cmds = ["examine %s" % obj for obj in client.objs]
if not cmds:
cmds = ["examine %s" % exi for exi in client.exits]
if not cmds:
cmds = "examine me"
return cmds | [
"def",
"c_examines",
"(",
"client",
")",
":",
"cmds",
"=",
"[",
"\"examine %s\"",
"%",
"obj",
"for",
"obj",
"in",
"client",
".",
"objs",
"]",
"if",
"not",
"cmds",
":",
"cmds",
"=",
"[",
"\"examine %s\"",
"%",
"exi",
"for",
"exi",
"in",
"client",
".",... | [
140,
0
] | [
147,
15
] | python | en | ['en', 'en', 'en'] | True |
c_help | (client) | reads help files | reads help files | def c_help(client):
"reads help files"
cmds = ('help',
'help @teleport',
'help look',
'help @tunnel',
'help @dig')
return cmds | [
"def",
"c_help",
"(",
"client",
")",
":",
"cmds",
"=",
"(",
"'help'",
",",
"'help @teleport'",
",",
"'help look'",
",",
"'help @tunnel'",
",",
"'help @dig'",
")",
"return",
"cmds"
] | [
156,
0
] | [
163,
15
] | python | en | ['en', 'en', 'en'] | True |
c_digs | (client) | digs a new room, storing exit names on client | digs a new room, storing exit names on client | def c_digs(client):
"digs a new room, storing exit names on client"
roomname = ROOM_TEMPLATE % client.counter()
exitname1 = EXIT_TEMPLATE % client.counter()
exitname2 = EXIT_TEMPLATE % client.counter()
client.exits.extend([exitname1, exitname2])
return '@dig/tel %s = %s, %s' % (roomname, exitnam... | [
"def",
"c_digs",
"(",
"client",
")",
":",
"roomname",
"=",
"ROOM_TEMPLATE",
"%",
"client",
".",
"counter",
"(",
")",
"exitname1",
"=",
"EXIT_TEMPLATE",
"%",
"client",
".",
"counter",
"(",
")",
"exitname2",
"=",
"EXIT_TEMPLATE",
"%",
"client",
".",
"counter... | [
166,
0
] | [
172,
68
] | python | en | ['en', 'en', 'en'] | True |
c_creates_obj | (client) | creates normal objects, storing their name on client | creates normal objects, storing their name on client | def c_creates_obj(client):
"creates normal objects, storing their name on client"
objname = OBJ_TEMPLATE % client.counter()
client.objs.append(objname)
cmds = ('@create %s' % objname,
'@desc %s = "this is a test object' % objname,
'@set %s/testattr = this is a test attribute valu... | [
"def",
"c_creates_obj",
"(",
"client",
")",
":",
"objname",
"=",
"OBJ_TEMPLATE",
"%",
"client",
".",
"counter",
"(",
")",
"client",
".",
"objs",
".",
"append",
"(",
"objname",
")",
"cmds",
"=",
"(",
"'@create %s'",
"%",
"objname",
",",
"'@desc %s = \"this ... | [
175,
0
] | [
183,
15
] | python | en | ['en', 'en', 'en'] | True |
c_creates_button | (client) | creates example button, storing name on client | creates example button, storing name on client | def c_creates_button(client):
"creates example button, storing name on client"
objname = TOBJ_TEMPLATE % client.counter()
client.objs.append(objname)
cmds = ('@create %s:%s' % (objname, TOBJ_TYPECLASS),
'@desc %s = test red button!' % objname)
return cmds | [
"def",
"c_creates_button",
"(",
"client",
")",
":",
"objname",
"=",
"TOBJ_TEMPLATE",
"%",
"client",
".",
"counter",
"(",
")",
"client",
".",
"objs",
".",
"append",
"(",
"objname",
")",
"cmds",
"=",
"(",
"'@create %s:%s'",
"%",
"(",
"objname",
",",
"TOBJ_... | [
186,
0
] | [
192,
15
] | python | en | ['en', 'en', 'en'] | True |
c_socialize | (client) | socializechats on channel | socializechats on channel | def c_socialize(client):
"socializechats on channel"
cmds = ('ooc Hello!',
'ooc Testing ...',
'ooc Testing ... times 2',
'say Yo!',
'emote stands looking around.')
return cmds | [
"def",
"c_socialize",
"(",
"client",
")",
":",
"cmds",
"=",
"(",
"'ooc Hello!'",
",",
"'ooc Testing ...'",
",",
"'ooc Testing ... times 2'",
",",
"'say Yo!'",
",",
"'emote stands looking around.'",
")",
"return",
"cmds"
] | [
195,
0
] | [
202,
15
] | python | en | ['en', 'en', 'en'] | True |
c_moves | (client) | moves to a previously created room, using the stored exits | moves to a previously created room, using the stored exits | def c_moves(client):
"moves to a previously created room, using the stored exits"
cmds = client.exits # try all exits - finally one will work
return "look" if not cmds else cmds | [
"def",
"c_moves",
"(",
"client",
")",
":",
"cmds",
"=",
"client",
".",
"exits",
"# try all exits - finally one will work",
"return",
"\"look\"",
"if",
"not",
"cmds",
"else",
"cmds"
] | [
205,
0
] | [
208,
39
] | python | en | ['en', 'en', 'en'] | True |
c_moves_n | (client) | move through north exit if available | move through north exit if available | def c_moves_n(client):
"move through north exit if available"
return "north" | [
"def",
"c_moves_n",
"(",
"client",
")",
":",
"return",
"\"north\""
] | [
211,
0
] | [
213,
18
] | python | en | ['en', 'en', 'en'] | True |
c_moves_s | (client) | move through south exit if available | move through south exit if available | def c_moves_s(client):
"move through south exit if available"
return "south" | [
"def",
"c_moves_s",
"(",
"client",
")",
":",
"return",
"\"south\""
] | [
216,
0
] | [
218,
18
] | python | en | ['en', 'en', 'en'] | True |
Font.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
] | [
64,
28
] | python | en | ['en', 'error', 'th'] | False |
Font.colorsrc | (self) |
Sets the source reference on Chart Studio Cloud for color .
The 'colorsrc' 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 color .
The 'colorsrc' property must be specified as a string or
as a plotly.grid_objs.Column object | def colorsrc(self):
"""
Sets the source reference on Chart Studio Cloud for color .
The 'colorsrc' property must be specified as a string or
as a plotly.grid_objs.Column object
Returns
-------
str
"""
return self["colorsrc"] | [
"def",
"colorsrc",
"(",
"self",
")",
":",
"return",
"self",
"[",
"\"colorsrc\"",
"]"
] | [
73,
4
] | [
84,
31
] | python | en | ['en', 'error', 'th'] | False |
Font.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\"",
"]"
] | [
93,
4
] | [
116,
29
] | python | en | ['en', 'error', 'th'] | False |
Font.familysrc | (self) |
Sets the source reference on Chart Studio Cloud for family .
The 'familysrc' 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 family .
The 'familysrc' property must be specified as a string or
as a plotly.grid_objs.Column object | def familysrc(self):
"""
Sets the source reference on Chart Studio Cloud for family .
The 'familysrc' property must be specified as a string or
as a plotly.grid_objs.Column object
Returns
-------
str
"""
return self["familysrc"] | [
"def",
"familysrc",
"(",
"self",
")",
":",
"return",
"self",
"[",
"\"familysrc\"",
"]"
] | [
125,
4
] | [
136,
32
] | python | en | ['en', 'error', 'th'] | False |
Font.size | (self) |
The 'size' property is a number and may be specified as:
- An int or float in the interval [1, inf]
- A tuple, list, or one-dimensional numpy array of the above
Returns
-------
int|float|numpy.ndarray
|
The 'size' property is a number and may be specified as:
- An int or float in the interval [1, inf]
- A tuple, list, or one-dimensional numpy array of the above | def size(self):
"""
The 'size' property is a number and may be specified as:
- An int or float in the interval [1, inf]
- A tuple, list, or one-dimensional numpy array of the above
Returns
-------
int|float|numpy.ndarray
"""
return self["size"... | [
"def",
"size",
"(",
"self",
")",
":",
"return",
"self",
"[",
"\"size\"",
"]"
] | [
145,
4
] | [
155,
27
] | python | en | ['en', 'error', 'th'] | False |
Font.sizesrc | (self) |
Sets the source reference on Chart Studio Cloud for size .
The 'sizesrc' 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 size .
The 'sizesrc' property must be specified as a string or
as a plotly.grid_objs.Column object | def sizesrc(self):
"""
Sets the source reference on Chart Studio Cloud for size .
The 'sizesrc' property must be specified as a string or
as a plotly.grid_objs.Column object
Returns
-------
str
"""
return self["sizesrc"] | [
"def",
"sizesrc",
"(",
"self",
")",
":",
"return",
"self",
"[",
"\"sizesrc\"",
"]"
] | [
164,
4
] | [
175,
30
] | python | en | ['en', 'error', 'th'] | False |
Font.__init__ | (
self,
arg=None,
color=None,
colorsrc=None,
family=None,
familysrc=None,
size=None,
sizesrc=None,
**kwargs
) |
Construct a new Font object
Sets the font used in hover labels.
Parameters
----------
arg
dict of properties compatible with this constructor or
an instance of
:class:`plotly.graph_objs.histogram2d.hoverlabel.Font`
color
... |
Construct a new Font object
Sets the font used in hover labels. | def __init__(
self,
arg=None,
color=None,
colorsrc=None,
family=None,
familysrc=None,
size=None,
sizesrc=None,
**kwargs
):
"""
Construct a new Font object
Sets the font used in hover labels.
Parameters
... | [
"def",
"__init__",
"(",
"self",
",",
"arg",
"=",
"None",
",",
"color",
"=",
"None",
",",
"colorsrc",
"=",
"None",
",",
"family",
"=",
"None",
",",
"familysrc",
"=",
"None",
",",
"size",
"=",
"None",
",",
"sizesrc",
"=",
"None",
",",
"*",
"*",
"kw... | [
215,
4
] | [
329,
34
] | python | en | ['en', 'error', 'th'] | False |
deny | () |
Deny, that is stop, the callback here.
Notes:
This function will raise an exception to terminate the callback
in a controlled way. If you use this function in an event called
prior to a command, the command will be cancelled as well. Good
situations to use the `deny()` functi... |
Deny, that is stop, the callback here. | def deny():
"""
Deny, that is stop, the callback here.
Notes:
This function will raise an exception to terminate the callback
in a controlled way. If you use this function in an event called
prior to a command, the command will be cancelled as well. Good
situations to use ... | [
"def",
"deny",
"(",
")",
":",
"raise",
"InterruptEvent"
] | [
11,
0
] | [
23,
24
] | python | en | ['en', 'error', 'th'] | False |
get | (**kwargs) |
Return an object with the given search option or None if None is found.
Kwargs:
Any searchable data or property (id, db_key, db_location...).
Returns:
The object found that meet these criteria for research, or
None if none is found.
Notes:
This function is very useful... |
Return an object with the given search option or None if None is found. | def get(**kwargs):
"""
Return an object with the given search option or None if None is found.
Kwargs:
Any searchable data or property (id, db_key, db_location...).
Returns:
The object found that meet these criteria for research, or
None if none is found.
Notes:
Th... | [
"def",
"get",
"(",
"*",
"*",
"kwargs",
")",
":",
"try",
":",
"object",
"=",
"ObjectDB",
".",
"objects",
".",
"get",
"(",
"*",
"*",
"kwargs",
")",
"except",
"ObjectDB",
".",
"DoesNotExist",
":",
"object",
"=",
"None",
"return",
"object"
] | [
26,
0
] | [
55,
17
] | python | en | ['en', 'error', 'th'] | False |
call_event | (obj, event_name, seconds=0) |
Call the specified event in X seconds.
Args:
obj (Object): the typeclassed object containing the event.
event_name (str): the event name to be called.
seconds (int or float): the number of seconds to wait before calling
the event.
Notes:
This eventfunc can ... |
Call the specified event in X seconds. | def call_event(obj, event_name, seconds=0):
"""
Call the specified event in X seconds.
Args:
obj (Object): the typeclassed object containing the event.
event_name (str): the event name to be called.
seconds (int or float): the number of seconds to wait before calling
... | [
"def",
"call_event",
"(",
"obj",
",",
"event_name",
",",
"seconds",
"=",
"0",
")",
":",
"script",
"=",
"type",
"(",
"obj",
".",
"callbacks",
")",
".",
"script",
"if",
"script",
":",
"# If seconds is 0, call the event immediately",
"if",
"seconds",
"==",
"0",... | [
58,
0
] | [
90,
53
] | python | en | ['en', 'error', 'th'] | False |
Stream.maxpoints | (self) |
Sets the maximum number of points to keep on the plots from an
incoming stream. If `maxpoints` is set to 50, only the newest
50 points will be displayed on the plot.
The 'maxpoints' property is a number and may be specified as:
- An int or float in the interval [0, 10000]... |
Sets the maximum number of points to keep on the plots from an
incoming stream. If `maxpoints` is set to 50, only the newest
50 points will be displayed on the plot.
The 'maxpoints' property is a number and may be specified as:
- An int or float in the interval [0, 10000] | def maxpoints(self):
"""
Sets the maximum number of points to keep on the plots from an
incoming stream. If `maxpoints` is set to 50, only the newest
50 points will be displayed on the plot.
The 'maxpoints' property is a number and may be specified as:
- An int or ... | [
"def",
"maxpoints",
"(",
"self",
")",
":",
"return",
"self",
"[",
"\"maxpoints\"",
"]"
] | [
15,
4
] | [
28,
32
] | python | en | ['en', 'error', 'th'] | False |
Stream.token | (self) |
The stream id number links a data trace on a plot with a
stream. See https://chart-studio.plotly.com/settings for more
details.
The 'token' property is a string and must be specified as:
- A non-empty string
Returns
-------
str
|
The stream id number links a data trace on a plot with a
stream. See https://chart-studio.plotly.com/settings for more
details.
The 'token' property is a string and must be specified as:
- A non-empty string | def token(self):
"""
The stream id number links a data trace on a plot with a
stream. See https://chart-studio.plotly.com/settings for more
details.
The 'token' property is a string and must be specified as:
- A non-empty string
Returns
-------
... | [
"def",
"token",
"(",
"self",
")",
":",
"return",
"self",
"[",
"\"token\"",
"]"
] | [
37,
4
] | [
50,
28
] | python | en | ['en', 'error', 'th'] | False |
Stream.__init__ | (self, arg=None, maxpoints=None, token=None, **kwargs) |
Construct a new Stream object
Parameters
----------
arg
dict of properties compatible with this constructor or
an instance of :class:`plotly.graph_objs.volume.Stream`
maxpoints
Sets the maximum number of points to keep on the plots
... |
Construct a new Stream object
Parameters
----------
arg
dict of properties compatible with this constructor or
an instance of :class:`plotly.graph_objs.volume.Stream`
maxpoints
Sets the maximum number of points to keep on the plots
... | def __init__(self, arg=None, maxpoints=None, token=None, **kwargs):
"""
Construct a new Stream object
Parameters
----------
arg
dict of properties compatible with this constructor or
an instance of :class:`plotly.graph_objs.volume.Stream`
... | [
"def",
"__init__",
"(",
"self",
",",
"arg",
"=",
"None",
",",
"maxpoints",
"=",
"None",
",",
"token",
"=",
"None",
",",
"*",
"*",
"kwargs",
")",
":",
"super",
"(",
"Stream",
",",
"self",
")",
".",
"__init__",
"(",
"\"stream\"",
")",
"if",
"\"_paren... | [
72,
4
] | [
139,
34
] | python | en | ['en', 'error', 'th'] | False |
Presentation.__init__ | (
self,
_id: str = None,
*,
comment: str = None,
presentations_attach: Sequence[AttachDecorator] = None,
**kwargs,
) |
Initialize presentation object.
Args:
presentations_attach: attachments
comment: optional comment
|
Initialize presentation object. | def __init__(
self,
_id: str = None,
*,
comment: str = None,
presentations_attach: Sequence[AttachDecorator] = None,
**kwargs,
):
"""
Initialize presentation object.
Args:
presentations_attach: attachments
comment: opti... | [
"def",
"__init__",
"(",
"self",
",",
"_id",
":",
"str",
"=",
"None",
",",
"*",
",",
"comment",
":",
"str",
"=",
"None",
",",
"presentations_attach",
":",
"Sequence",
"[",
"AttachDecorator",
"]",
"=",
"None",
",",
"*",
"*",
"kwargs",
",",
")",
":",
... | [
29,
4
] | [
49,
9
] | python | en | ['en', 'error', 'th'] | False |
Presentation.indy_proof | (self, index: int = 0) |
Retrieve and decode indy proof from attachment.
Args:
index: ordinal in attachment list to decode and return
(typically, list has length 1)
|
Retrieve and decode indy proof from attachment. | def indy_proof(self, index: int = 0):
"""
Retrieve and decode indy proof from attachment.
Args:
index: ordinal in attachment list to decode and return
(typically, list has length 1)
"""
return self.presentations_attach[index].indy_dict | [
"def",
"indy_proof",
"(",
"self",
",",
"index",
":",
"int",
"=",
"0",
")",
":",
"return",
"self",
".",
"presentations_attach",
"[",
"index",
"]",
".",
"indy_dict"
] | [
51,
4
] | [
60,
57
] | python | en | ['en', 'error', 'th'] | False |
DiscloseHandler.handle | (self, context: RequestContext, responder: BaseResponder) | Message handler implementation. | Message handler implementation. | async def handle(self, context: RequestContext, responder: BaseResponder):
"""Message handler implementation."""
self._logger.debug("DiscloseHandler called with context %s", context)
assert isinstance(context.message, Disclose)
print("Received protocols:\n{}".format(context.message.prot... | [
"async",
"def",
"handle",
"(",
"self",
",",
"context",
":",
"RequestContext",
",",
"responder",
":",
"BaseResponder",
")",
":",
"self",
".",
"_logger",
".",
"debug",
"(",
"\"DiscloseHandler called with context %s\"",
",",
"context",
")",
"assert",
"isinstance",
... | [
10,
4
] | [
15,
74
] | python | da | ['da', 'da', 'en'] | True |
_table_exists | (db_cursor, tablename) | Returns bool if table exists or not | Returns bool if table exists or not | def _table_exists(db_cursor, tablename):
"Returns bool if table exists or not"
return tablename in connection.introspection.table_names() | [
"def",
"_table_exists",
"(",
"db_cursor",
",",
"tablename",
")",
":",
"return",
"tablename",
"in",
"connection",
".",
"introspection",
".",
"table_names",
"(",
")"
] | [
7,
0
] | [
9,
62
] | python | en | ['en', 'en', 'en'] | True |
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.volume.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.volume.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.volume.hoverlabel.Font`
- A dict of string/value properties that will be passed
to ... | [
"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.volume.Hoverlabel`
align
Sets the horizontal alignment of the text... |
Construct a new Hoverlabel object
Parameters
----------
arg
dict of properties compatible with this constructor or
an instance of
:class:`plotly.graph_objs.volume.Hoverlabel`
align
Sets the horizontal alignment of the text... | 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 |
Line.autocolorscale | (self) |
Determines whether the colorscale is a default palette
(`autocolorscale: true`) or the palette determined by
`line.colorscale`. Has an effect only if in `line.color`is set
to a numerical array. In case `colorscale` is unspecified or
`autocolorscale` is true, the default palette... |
Determines whether the colorscale is a default palette
(`autocolorscale: true`) or the palette determined by
`line.colorscale`. Has an effect only if in `line.color`is set
to a numerical array. In case `colorscale` is unspecified or
`autocolorscale` is true, the default palette... | def autocolorscale(self):
"""
Determines whether the colorscale is a default palette
(`autocolorscale: true`) or the palette determined by
`line.colorscale`. Has an effect only if in `line.color`is set
to a numerical array. In case `colorscale` is unspecified or
`autocolo... | [
"def",
"autocolorscale",
"(",
"self",
")",
":",
"return",
"self",
"[",
"\"autocolorscale\"",
"]"
] | [
30,
4
] | [
47,
37
] | python | en | ['en', 'error', 'th'] | False |
Line.cauto | (self) |
Determines whether or not the color domain is computed with
respect to the input data (here in `line.color`) or the bounds
set in `line.cmin` and `line.cmax` Has an effect only if in
`line.color`is set to a numerical array. Defaults to `false`
when `line.cmin` and `line.cmax` a... |
Determines whether or not the color domain is computed with
respect to the input data (here in `line.color`) or the bounds
set in `line.cmin` and `line.cmax` Has an effect only if in
`line.color`is set to a numerical array. Defaults to `false`
when `line.cmin` and `line.cmax` a... | def cauto(self):
"""
Determines whether or not the color domain is computed with
respect to the input data (here in `line.color`) or the bounds
set in `line.cmin` and `line.cmax` Has an effect only if in
`line.color`is set to a numerical array. Defaults to `false`
when `... | [
"def",
"cauto",
"(",
"self",
")",
":",
"return",
"self",
"[",
"\"cauto\"",
"]"
] | [
56,
4
] | [
71,
28
] | python | en | ['en', 'error', 'th'] | False |
Line.cmax | (self) |
Sets the upper bound of the color domain. Has an effect only if
in `line.color`is set to a numerical array. Value should have
the same units as in `line.color` and if set, `line.cmin` must
be set as well.
The 'cmax' property is a number and may be specified as:
- ... |
Sets the upper bound of the color domain. Has an effect only if
in `line.color`is set to a numerical array. Value should have
the same units as in `line.color` and if set, `line.cmin` must
be set as well.
The 'cmax' property is a number and may be specified as:
- ... | def cmax(self):
"""
Sets the upper bound of the color domain. Has an effect only if
in `line.color`is set to a numerical array. Value should have
the same units as in `line.color` and if set, `line.cmin` must
be set as well.
The 'cmax' property is a number and may be... | [
"def",
"cmax",
"(",
"self",
")",
":",
"return",
"self",
"[",
"\"cmax\"",
"]"
] | [
80,
4
] | [
94,
27
] | python | en | ['en', 'error', 'th'] | False |
Line.cmid | (self) |
Sets the mid-point of the color domain by scaling `line.cmin`
and/or `line.cmax` to be equidistant to this point. Has an
effect only if in `line.color`is set to a numerical array.
Value should have the same units as in `line.color`. Has no
effect when `line.cauto` is `false`.
... |
Sets the mid-point of the color domain by scaling `line.cmin`
and/or `line.cmax` to be equidistant to this point. Has an
effect only if in `line.color`is set to a numerical array.
Value should have the same units as in `line.color`. Has no
effect when `line.cauto` is `false`.
... | def cmid(self):
"""
Sets the mid-point of the color domain by scaling `line.cmin`
and/or `line.cmax` to be equidistant to this point. Has an
effect only if in `line.color`is set to a numerical array.
Value should have the same units as in `line.color`. Has no
effect when ... | [
"def",
"cmid",
"(",
"self",
")",
":",
"return",
"self",
"[",
"\"cmid\"",
"]"
] | [
103,
4
] | [
118,
27
] | python | en | ['en', 'error', 'th'] | False |
Line.cmin | (self) |
Sets the lower bound of the color domain. Has an effect only if
in `line.color`is set to a numerical array. Value should have
the same units as in `line.color` and if set, `line.cmax` must
be set as well.
The 'cmin' property is a number and may be specified as:
- ... |
Sets the lower bound of the color domain. Has an effect only if
in `line.color`is set to a numerical array. Value should have
the same units as in `line.color` and if set, `line.cmax` must
be set as well.
The 'cmin' property is a number and may be specified as:
- ... | def cmin(self):
"""
Sets the lower bound of the color domain. Has an effect only if
in `line.color`is set to a numerical array. Value should have
the same units as in `line.color` and if set, `line.cmax` must
be set as well.
The 'cmin' property is a number and may be... | [
"def",
"cmin",
"(",
"self",
")",
":",
"return",
"self",
"[",
"\"cmin\"",
"]"
] | [
127,
4
] | [
141,
27
] | python | en | ['en', 'error', 'th'] | False |
Line.color | (self) |
Sets thelinecolor. It accepts either a specific color or an
array of numbers that are mapped to the colorscale relative to
the max and min values of the array or relative to `line.cmin`
and `line.cmax` if set.
The 'color' property is a color and may be specified as:
... |
Sets thelinecolor. It accepts either a specific color or an
array of numbers that are mapped to the colorscale relative to
the max and min values of the array or relative to `line.cmin`
and `line.cmax` if set.
The 'color' property is a color and may be specified as:
... | def color(self):
"""
Sets thelinecolor. It accepts either a specific color or an
array of numbers that are mapped to the colorscale relative to
the max and min values of the array or relative to `line.cmin`
and `line.cmax` if set.
The 'color' property is a color and ... | [
"def",
"color",
"(",
"self",
")",
":",
"return",
"self",
"[",
"\"color\"",
"]"
] | [
150,
4
] | [
206,
28
] | python | en | ['en', 'error', 'th'] | False |
Line.coloraxis | (self) |
Sets a reference to a shared color axis. References to these
shared color axes are "coloraxis", "coloraxis2", "coloraxis3",
etc. Settings for these shared color axes are set in the
layout, under `layout.coloraxis`, `layout.coloraxis2`, etc.
Note that multiple color scales can be... |
Sets a reference to a shared color axis. References to these
shared color axes are "coloraxis", "coloraxis2", "coloraxis3",
etc. Settings for these shared color axes are set in the
layout, under `layout.coloraxis`, `layout.coloraxis2`, etc.
Note that multiple color scales can be... | def coloraxis(self):
"""
Sets a reference to a shared color axis. References to these
shared color axes are "coloraxis", "coloraxis2", "coloraxis3",
etc. Settings for these shared color axes are set in the
layout, under `layout.coloraxis`, `layout.coloraxis2`, etc.
Note t... | [
"def",
"coloraxis",
"(",
"self",
")",
":",
"return",
"self",
"[",
"\"coloraxis\"",
"]"
] | [
215,
4
] | [
233,
32
] | python | en | ['en', 'error', 'th'] | False |
Line.colorbar | (self) |
The 'colorbar' property is an instance of ColorBar
that may be specified as:
- An instance of :class:`plotly.graph_objs.parcats.line.ColorBar`
- A dict of string/value properties that will be passed
to the ColorBar constructor
Supported dict properties:
... |
The 'colorbar' property is an instance of ColorBar
that may be specified as:
- An instance of :class:`plotly.graph_objs.parcats.line.ColorBar`
- A dict of string/value properties that will be passed
to the ColorBar constructor
Supported dict properties:
... | def colorbar(self):
"""
The 'colorbar' property is an instance of ColorBar
that may be specified as:
- An instance of :class:`plotly.graph_objs.parcats.line.ColorBar`
- A dict of string/value properties that will be passed
to the ColorBar constructor
... | [
"def",
"colorbar",
"(",
"self",
")",
":",
"return",
"self",
"[",
"\"colorbar\"",
"]"
] | [
242,
4
] | [
469,
31
] | python | en | ['en', 'error', 'th'] | False |
Line.colorscale | (self) |
Sets the colorscale. Has an effect only if in `line.color`is
set to a numerical array. The colorscale must be an array
containing arrays mapping a normalized value to an rgb, rgba,
hex, hsl, hsv, or named color string. At minimum, a mapping for
the lowest (0) and highest (1) val... |
Sets the colorscale. Has an effect only if in `line.color`is
set to a numerical array. The colorscale must be an array
containing arrays mapping a normalized value to an rgb, rgba,
hex, hsl, hsv, or named color string. At minimum, a mapping for
the lowest (0) and highest (1) val... | def colorscale(self):
"""
Sets the colorscale. Has an effect only if in `line.color`is
set to a numerical array. The colorscale must be an array
containing arrays mapping a normalized value to an rgb, rgba,
hex, hsl, hsv, or named color string. At minimum, a mapping for
t... | [
"def",
"colorscale",
"(",
"self",
")",
":",
"return",
"self",
"[",
"\"colorscale\"",
"]"
] | [
478,
4
] | [
522,
33
] | python | en | ['en', 'error', 'th'] | False |
Line.colorsrc | (self) |
Sets the source reference on Chart Studio Cloud for color .
The 'colorsrc' 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 color .
The 'colorsrc' property must be specified as a string or
as a plotly.grid_objs.Column object | def colorsrc(self):
"""
Sets the source reference on Chart Studio Cloud for color .
The 'colorsrc' property must be specified as a string or
as a plotly.grid_objs.Column object
Returns
-------
str
"""
return self["colorsrc"] | [
"def",
"colorsrc",
"(",
"self",
")",
":",
"return",
"self",
"[",
"\"colorsrc\"",
"]"
] | [
531,
4
] | [
542,
31
] | python | en | ['en', 'error', 'th'] | False |
Line.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\"",
"]"
] | [
551,
4
] | [
582,
36
] | python | en | ['en', 'error', 'th'] | False |
Line.reversescale | (self) |
Reverses the color mapping if true. Has an effect only if in
`line.color`is set to a numerical array. If true, `line.cmin`
will correspond to the last color in the array and `line.cmax`
will correspond to the first color.
The 'reversescale' property must be specified as a b... |
Reverses the color mapping if true. Has an effect only if in
`line.color`is set to a numerical array. If true, `line.cmin`
will correspond to the last color in the array and `line.cmax`
will correspond to the first color.
The 'reversescale' property must be specified as a b... | def reversescale(self):
"""
Reverses the color mapping if true. Has an effect only if in
`line.color`is set to a numerical array. If true, `line.cmin`
will correspond to the last color in the array and `line.cmax`
will correspond to the first color.
The 'reversescale... | [
"def",
"reversescale",
"(",
"self",
")",
":",
"return",
"self",
"[",
"\"reversescale\"",
"]"
] | [
591,
4
] | [
605,
35
] | python | en | ['en', 'error', 'th'] | False |
Line.shape | (self) |
Sets the shape of the paths. If `linear`, paths are composed of
straight lines. If `hspline`, paths are composed of horizontal
curved splines
The 'shape' property is an enumeration that may be specified as:
- One of the following enumeration values:
['line... |
Sets the shape of the paths. If `linear`, paths are composed of
straight lines. If `hspline`, paths are composed of horizontal
curved splines
The 'shape' property is an enumeration that may be specified as:
- One of the following enumeration values:
['line... | def shape(self):
"""
Sets the shape of the paths. If `linear`, paths are composed of
straight lines. If `hspline`, paths are composed of horizontal
curved splines
The 'shape' property is an enumeration that may be specified as:
- One of the following enumeration va... | [
"def",
"shape",
"(",
"self",
")",
":",
"return",
"self",
"[",
"\"shape\"",
"]"
] | [
614,
4
] | [
628,
28
] | python | en | ['en', 'error', 'th'] | False |
Line.showscale | (self) |
Determines whether or not a colorbar is displayed for this
trace. Has an effect only if in `line.color`is set to a
numerical array.
The 'showscale' property must be specified as a bool
(either True, or False)
Returns
-------
bool
|
Determines whether or not a colorbar is displayed for this
trace. Has an effect only if in `line.color`is set to a
numerical array.
The 'showscale' property must be specified as a bool
(either True, or False) | def showscale(self):
"""
Determines whether or not a colorbar is displayed for this
trace. Has an effect only if in `line.color`is set to a
numerical array.
The 'showscale' property must be specified as a bool
(either True, or False)
Returns
-------
... | [
"def",
"showscale",
"(",
"self",
")",
":",
"return",
"self",
"[",
"\"showscale\"",
"]"
] | [
637,
4
] | [
650,
32
] | python | en | ['en', 'error', 'th'] | False |
Line.__init__ | (
self,
arg=None,
autocolorscale=None,
cauto=None,
cmax=None,
cmid=None,
cmin=None,
color=None,
coloraxis=None,
colorbar=None,
colorscale=None,
colorsrc=None,
hovertemplate=None,
reversescale=None,
sh... |
Construct a new Line object
Parameters
----------
arg
dict of properties compatible with this constructor or
an instance of :class:`plotly.graph_objs.parcats.Line`
autocolorscale
Determines whether the colorscale is a default palette
... |
Construct a new Line object
Parameters
----------
arg
dict of properties compatible with this constructor or
an instance of :class:`plotly.graph_objs.parcats.Line`
autocolorscale
Determines whether the colorscale is a default palette
... | def __init__(
self,
arg=None,
autocolorscale=None,
cauto=None,
cmax=None,
cmid=None,
cmin=None,
color=None,
coloraxis=None,
colorbar=None,
colorscale=None,
colorsrc=None,
hovertemplate=None,
reversescale=None... | [
"def",
"__init__",
"(",
"self",
",",
"arg",
"=",
"None",
",",
"autocolorscale",
"=",
"None",
",",
"cauto",
"=",
"None",
",",
"cmax",
"=",
"None",
",",
"cmid",
"=",
"None",
",",
"cmin",
"=",
"None",
",",
"color",
"=",
"None",
",",
"coloraxis",
"=",
... | [
767,
4
] | [
995,
34
] | python | en | ['en', 'error', 'th'] | False |
escape_backticks | (text: str) |
Replace backticks with a homoglyph to prevent codeblock and inline code breakout.
Parameters
----------
text : str
The text to escape.
Returns
-------
str
The escaped text.
|
Replace backticks with a homoglyph to prevent codeblock and inline code breakout.
Parameters
----------
text : str
The text to escape.
Returns
-------
str
The escaped text.
| def escape_backticks(text: str) -> str:
"""
Replace backticks with a homoglyph to prevent codeblock and inline code breakout.
Parameters
----------
text : str
The text to escape.
Returns
-------
str
The escaped text.
"""
return text.replace('\N{GRAVE ACCENT}', '\N... | [
"def",
"escape_backticks",
"(",
"text",
":",
"str",
")",
"->",
"str",
":",
"return",
"text",
".",
"replace",
"(",
"'\\N{GRAVE ACCENT}'",
",",
"'\\N{MODIFIER LETTER GRAVE ACCENT}'",
")"
] | [
3,
0
] | [
15,
79
] | python | en | ['en', 'error', 'th'] | False |
codeblock | (code: str, *, lang: str = '', escape: bool = True) |
Construct a Markdown codeblock.
Parameters
----------
code
The code to insert into the codeblock.
lang
The string to mark as the language when formatting.
escape
Prevents the code from escaping from the codeblock.
Returns
-------
str
The formatted cod... |
Construct a Markdown codeblock.
Parameters
----------
code
The code to insert into the codeblock.
lang
The string to mark as the language when formatting.
escape
Prevents the code from escaping from the codeblock.
Returns
-------
str
The formatted cod... | def codeblock(code: str, *, lang: str = '', escape: bool = True) -> str:
"""
Construct a Markdown codeblock.
Parameters
----------
code
The code to insert into the codeblock.
lang
The string to mark as the language when formatting.
escape
Prevents the code from escapi... | [
"def",
"codeblock",
"(",
"code",
":",
"str",
",",
"*",
",",
"lang",
":",
"str",
"=",
"''",
",",
"escape",
":",
"bool",
"=",
"True",
")",
"->",
"str",
":",
"return",
"'```{}\\n{}\\n```'",
".",
"format",
"(",
"lang",
",",
"escape_backticks",
"(",
"code... | [
18,
0
] | [
37,
5
] | python | en | ['en', 'error', 'th'] | False |
cleanup_code | (code: str) |
Automatically removes code blocks from the code.
Parameters
----------
code
The code to clean.
Returns
-------
str
The cleaned code.
|
Automatically removes code blocks from the code.
Parameters
----------
code
The code to clean.
Returns
-------
str
The cleaned code.
| def cleanup_code(code: str) -> str:
"""
Automatically removes code blocks from the code.
Parameters
----------
code
The code to clean.
Returns
-------
str
The cleaned code.
"""
# remove ```py\n```
if code.startswith('```') and code.endswith('```'):
ret... | [
"def",
"cleanup_code",
"(",
"code",
":",
"str",
")",
"->",
"str",
":",
"# remove ```py\\n```",
"if",
"code",
".",
"startswith",
"(",
"'```'",
")",
"and",
"code",
".",
"endswith",
"(",
"'```'",
")",
":",
"return",
"'\\n'",
".",
"join",
"(",
"code",
".",... | [
40,
0
] | [
57,
29
] | python | en | ['en', 'error', 'th'] | False |
truncate | (text: str, desired_length: int, *, suffix: str = '…') - |
Truncates text and returns it. Three periods will be inserted as a suffix.
Parameters
----------
text
The text to truncate.
desired_length
The desired length.
suffix
The text to insert before the desired length is reached.
By default, this is '...' to indicate tr... |
Truncates text and returns it. Three periods will be inserted as a suffix.
Parameters
----------
text
The text to truncate.
desired_length
The desired length.
suffix
The text to insert before the desired length is reached.
By default, this is '...' to indicate tr... | def truncate(text: str, desired_length: int, *, suffix: str = '…') -> str:
"""
Truncates text and returns it. Three periods will be inserted as a suffix.
Parameters
----------
text
The text to truncate.
desired_length
The desired length.
suffix
The text to insert befo... | [
"def",
"truncate",
"(",
"text",
":",
"str",
",",
"desired_length",
":",
"int",
",",
"*",
",",
"suffix",
":",
"str",
"=",
"'…') ",
"-",
" s",
"r:",
"",
"if",
"len",
"(",
"text",
")",
">",
"desired_length",
":",
"return",
"text",
"[",
":",
"desired_l... | [
60,
0
] | [
76,
19
] | python | en | ['en', 'error', 'th'] | False |
pluralise | (*, with_quantity: bool = True, with_indicative: bool = False, **word) |
Pluralise a single kwarg's name depending on the value.
Example
-------
>>> pluralise(object=2)
"objects"
>>> pluralise(object=1)
"object"
|
Pluralise a single kwarg's name depending on the value.
Example
-------
>>> pluralise(object=2)
"objects"
>>> pluralise(object=1)
"object"
| def pluralise(*, with_quantity: bool = True, with_indicative: bool = False, **word) -> str:
"""
Pluralise a single kwarg's name depending on the value.
Example
-------
>>> pluralise(object=2)
"objects"
>>> pluralise(object=1)
"object"
"""
try:
items = word.items()
... | [
"def",
"pluralise",
"(",
"*",
",",
"with_quantity",
":",
"bool",
"=",
"True",
",",
"with_indicative",
":",
"bool",
"=",
"False",
",",
"*",
"*",
"word",
")",
"->",
"str",
":",
"try",
":",
"items",
"=",
"word",
".",
"items",
"(",
")",
"kwargs",
"=",
... | [
79,
0
] | [
108,
34
] | python | en | ['en', 'error', 'th'] | False |
TabularData.render | (self) | Renders a table in rST format.
Example:
+-------+-----+
| Name | Age |
+-------+-----+
| Alice | 24 |
| Bob | 19 |
+-------+-----+
| Renders a table in rST format. | def render(self):
"""Renders a table in rST format.
Example:
+-------+-----+
| Name | Age |
+-------+-----+
| Alice | 24 |
| Bob | 19 |
+-------+-----+
"""
sep = '+'.join('-' * w for w in self._widths)
sep = f'+{sep}+'
... | [
"def",
"render",
"(",
"self",
")",
":",
"sep",
"=",
"'+'",
".",
"join",
"(",
"'-'",
"*",
"w",
"for",
"w",
"in",
"self",
".",
"_widths",
")",
"sep",
"=",
"f'+{sep}+'",
"to_draw",
"=",
"[",
"sep",
"]",
"def",
"get_entry",
"(",
"d",
")",
":",
"ele... | [
147,
4
] | [
176,
33
] | python | en | ['en', 'en', 'en'] | True |
run | () | Check files checked in to git for trailing newlines at end of file. | Check files checked in to git for trailing newlines at end of file. | def run():
"""Check files checked in to git for trailing newlines at end of file."""
files = subprocess.run(
[
"git", "ls-files", "--",
"*.cpp",
"*.h",
"*.gml",
"*.html",
"*.js",
"*.css",
"*.sh",
... | [
"def",
"run",
"(",
")",
":",
"files",
"=",
"subprocess",
".",
"run",
"(",
"[",
"\"git\"",
",",
"\"ls-files\"",
",",
"\"--\"",
",",
"\"*.cpp\"",
",",
"\"*.h\"",
",",
"\"*.gml\"",
",",
"\"*.html\"",
",",
"\"*.js\"",
",",
"\"*.css\"",
",",
"\"*.sh\"",
",",
... | [
7,
0
] | [
61,
19
] | python | en | ['en', 'en', 'en'] | True |
Font.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
] | [
64,
28
] | python | en | ['en', 'error', 'th'] | False |
Font.colorsrc | (self) |
Sets the source reference on Chart Studio Cloud for color .
The 'colorsrc' 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 color .
The 'colorsrc' property must be specified as a string or
as a plotly.grid_objs.Column object | def colorsrc(self):
"""
Sets the source reference on Chart Studio Cloud for color .
The 'colorsrc' property must be specified as a string or
as a plotly.grid_objs.Column object
Returns
-------
str
"""
return self["colorsrc"] | [
"def",
"colorsrc",
"(",
"self",
")",
":",
"return",
"self",
"[",
"\"colorsrc\"",
"]"
] | [
73,
4
] | [
84,
31
] | python | en | ['en', 'error', 'th'] | False |
Font.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\"",
"]"
] | [
93,
4
] | [
116,
29
] | python | en | ['en', 'error', 'th'] | False |
Font.familysrc | (self) |
Sets the source reference on Chart Studio Cloud for family .
The 'familysrc' 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 family .
The 'familysrc' property must be specified as a string or
as a plotly.grid_objs.Column object | def familysrc(self):
"""
Sets the source reference on Chart Studio Cloud for family .
The 'familysrc' property must be specified as a string or
as a plotly.grid_objs.Column object
Returns
-------
str
"""
return self["familysrc"] | [
"def",
"familysrc",
"(",
"self",
")",
":",
"return",
"self",
"[",
"\"familysrc\"",
"]"
] | [
125,
4
] | [
136,
32
] | python | en | ['en', 'error', 'th'] | False |
Font.size | (self) |
The 'size' property is a number and may be specified as:
- An int or float in the interval [1, inf]
- A tuple, list, or one-dimensional numpy array of the above
Returns
-------
int|float|numpy.ndarray
|
The 'size' property is a number and may be specified as:
- An int or float in the interval [1, inf]
- A tuple, list, or one-dimensional numpy array of the above | def size(self):
"""
The 'size' property is a number and may be specified as:
- An int or float in the interval [1, inf]
- A tuple, list, or one-dimensional numpy array of the above
Returns
-------
int|float|numpy.ndarray
"""
return self["size"... | [
"def",
"size",
"(",
"self",
")",
":",
"return",
"self",
"[",
"\"size\"",
"]"
] | [
145,
4
] | [
155,
27
] | python | en | ['en', 'error', 'th'] | False |
Font.sizesrc | (self) |
Sets the source reference on Chart Studio Cloud for size .
The 'sizesrc' 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 size .
The 'sizesrc' property must be specified as a string or
as a plotly.grid_objs.Column object | def sizesrc(self):
"""
Sets the source reference on Chart Studio Cloud for size .
The 'sizesrc' property must be specified as a string or
as a plotly.grid_objs.Column object
Returns
-------
str
"""
return self["sizesrc"] | [
"def",
"sizesrc",
"(",
"self",
")",
":",
"return",
"self",
"[",
"\"sizesrc\"",
"]"
] | [
164,
4
] | [
175,
30
] | python | en | ['en', 'error', 'th'] | False |
Font.__init__ | (
self,
arg=None,
color=None,
colorsrc=None,
family=None,
familysrc=None,
size=None,
sizesrc=None,
**kwargs
) |
Construct a new Font object
Sets the font used in hover labels.
Parameters
----------
arg
dict of properties compatible with this constructor or
an instance of
:class:`plotly.graph_objs.scatter.hoverlabel.Font`
color
... |
Construct a new Font object
Sets the font used in hover labels. | def __init__(
self,
arg=None,
color=None,
colorsrc=None,
family=None,
familysrc=None,
size=None,
sizesrc=None,
**kwargs
):
"""
Construct a new Font object
Sets the font used in hover labels.
Parameters
... | [
"def",
"__init__",
"(",
"self",
",",
"arg",
"=",
"None",
",",
"color",
"=",
"None",
",",
"colorsrc",
"=",
"None",
",",
"family",
"=",
"None",
",",
"familysrc",
"=",
"None",
",",
"size",
"=",
"None",
",",
"sizesrc",
"=",
"None",
",",
"*",
"*",
"kw... | [
215,
4
] | [
329,
34
] | python | en | ['en', 'error', 'th'] | False |
TestScriptDB.test_delete | (self) | Check the script is removed from the database | Check the script is removed from the database | def test_delete(self):
"Check the script is removed from the database"
self.scr.delete()
self.assertFalse(self.scr in ScriptDB.objects.get_all_scripts()) | [
"def",
"test_delete",
"(",
"self",
")",
":",
"self",
".",
"scr",
".",
"delete",
"(",
")",
"self",
".",
"assertFalse",
"(",
"self",
".",
"scr",
"in",
"ScriptDB",
".",
"objects",
".",
"get_all_scripts",
"(",
")",
")"
] | [
20,
4
] | [
23,
72
] | python | en | ['en', 'en', 'en'] | True |
TestScriptDB.test_double_delete | (self) | What should happen? Isn't it already deleted? | What should happen? Isn't it already deleted? | def test_double_delete(self):
"What should happen? Isn't it already deleted?"
with self.assertRaises(ObjectDoesNotExist):
self.scr.delete()
self.scr.delete() | [
"def",
"test_double_delete",
"(",
"self",
")",
":",
"with",
"self",
".",
"assertRaises",
"(",
"ObjectDoesNotExist",
")",
":",
"self",
".",
"scr",
".",
"delete",
"(",
")",
"self",
".",
"scr",
".",
"delete",
"(",
")"
] | [
25,
4
] | [
29,
29
] | python | en | ['en', 'en', 'en'] | True |
TestScriptDB.test_deleted_script_fails_start | (self) | Would it ever be necessary to start a deleted script? | Would it ever be necessary to start a deleted script? | def test_deleted_script_fails_start(self):
"Would it ever be necessary to start a deleted script?"
self.scr.delete()
with self.assertRaises(ObjectDoesNotExist): # See issue #509
self.scr.start()
# Check the script is not recreated as a side-effect
self.assertFalse(se... | [
"def",
"test_deleted_script_fails_start",
"(",
"self",
")",
":",
"self",
".",
"scr",
".",
"delete",
"(",
")",
"with",
"self",
".",
"assertRaises",
"(",
"ObjectDoesNotExist",
")",
":",
"# See issue #509",
"self",
".",
"scr",
".",
"start",
"(",
")",
"# Check t... | [
31,
4
] | [
37,
72
] | python | en | ['en', 'en', 'en'] | True |
TestScriptDB.test_deleted_script_is_invalid | (self) | Can deleted scripts be said to be valid? | Can deleted scripts be said to be valid? | def test_deleted_script_is_invalid(self):
"Can deleted scripts be said to be valid?"
self.scr.delete()
self.assertFalse(self.scr.is_valid()) | [
"def",
"test_deleted_script_is_invalid",
"(",
"self",
")",
":",
"self",
".",
"scr",
".",
"delete",
"(",
")",
"self",
".",
"assertFalse",
"(",
"self",
".",
"scr",
".",
"is_valid",
"(",
")",
")"
] | [
39,
4
] | [
42,
45
] | python | en | ['en', 'en', 'en'] | True |
StickyMessage.stickymessage_imageset | (self, ctx, delay: time.ShortTime, *, message: str) | Set a sticky message for the current channel that replies only to images. | Set a sticky message for the current channel that replies only to images. | async def stickymessage_imageset(self, ctx, delay: time.ShortTime, *, message: str):
"""Set a sticky message for the current channel that replies only to images."""
try:
await ctx.message.delete()
except discord.errors.NotFound:
pass
await self.set_stickymessage... | [
"async",
"def",
"stickymessage_imageset",
"(",
"self",
",",
"ctx",
",",
"delay",
":",
"time",
".",
"ShortTime",
",",
"*",
",",
"message",
":",
"str",
")",
":",
"try",
":",
"await",
"ctx",
".",
"message",
".",
"delete",
"(",
")",
"except",
"discord",
... | [
161,
4
] | [
169,
63
] | python | en | ['en', 'en', 'en'] | True |
StickyMessage.stickymessage_unset | (self, ctx) | Unset a sticky message for the current channel. | Unset a sticky message for the current channel. | async def stickymessage_unset(self, ctx):
"""Unset a sticky message for the current channel."""
try:
await ctx.message.delete()
except discord.errors.NotFound:
pass
if ctx.channel.id in self._stickymessage_cache:
del self._stickymessage_cache[ctx.cha... | [
"async",
"def",
"stickymessage_unset",
"(",
"self",
",",
"ctx",
")",
":",
"try",
":",
"await",
"ctx",
".",
"message",
".",
"delete",
"(",
")",
"except",
"discord",
".",
"errors",
".",
"NotFound",
":",
"pass",
"if",
"ctx",
".",
"channel",
".",
"id",
"... | [
175,
4
] | [
194,
20
] | python | en | ['en', 'en', 'en'] | True |
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.bar.marker.colorbar.Tickfont`
colo... |
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 |
CmdMail.search_targets | (self, namelist) |
Search a list of targets of the same type as caller.
Args:
caller (Object or Account): The type of object to search.
namelist (list): List of strings for objects to search for.
Returns:
targetlist (list): List of matches, if any.
|
Search a list of targets of the same type as caller. | def search_targets(self, namelist):
"""
Search a list of targets of the same type as caller.
Args:
caller (Object or Account): The type of object to search.
namelist (list): List of strings for objects to search for.
Returns:
targetlist (list): List ... | [
"def",
"search_targets",
"(",
"self",
",",
"namelist",
")",
":",
"nameregex",
"=",
"r\"|\"",
".",
"join",
"(",
"r\"^%s$\"",
"%",
"re",
".",
"escape",
"(",
"name",
")",
"for",
"name",
"in",
"make_iter",
"(",
"namelist",
")",
")",
"if",
"hasattr",
"(",
... | [
64,
4
] | [
81,
22
] | python | en | ['en', 'error', 'th'] | False |
CmdMail.get_all_mail | (self) |
Returns a list of all the messages where the caller is a recipient.
Returns:
messages (list): list of Msg objects.
|
Returns a list of all the messages where the caller is a recipient. | def get_all_mail(self):
"""
Returns a list of all the messages where the caller is a recipient.
Returns:
messages (list): list of Msg objects.
"""
# mail_messages = Msg.objects.get_by_tag(category="mail")
# messages = []
try:
account = se... | [
"def",
"get_all_mail",
"(",
"self",
")",
":",
"# mail_messages = Msg.objects.get_by_tag(category=\"mail\")",
"# messages = []",
"try",
":",
"account",
"=",
"self",
".",
"caller",
".",
"account",
"except",
"AttributeError",
":",
"account",
"=",
"self",
".",
"caller",
... | [
83,
4
] | [
98,
23
] | python | en | ['en', 'error', 'th'] | False |
CmdMail.send_mail | (self, recipients, subject, message, caller) |
Function for sending new mail. Also useful for sending notifications from objects or systems.
Args:
recipients (list): list of Account or character objects to receive the newly created mails.
subject (str): The header or subject of the message to be delivered.
mess... |
Function for sending new mail. Also useful for sending notifications from objects or systems. | def send_mail(self, recipients, subject, message, caller):
"""
Function for sending new mail. Also useful for sending notifications from objects or systems.
Args:
recipients (list): list of Account or character objects to receive the newly created mails.
subject (str): ... | [
"def",
"send_mail",
"(",
"self",
",",
"recipients",
",",
"subject",
",",
"message",
",",
"caller",
")",
":",
"for",
"recipient",
"in",
"recipients",
":",
"recipient",
".",
"msg",
"(",
"\"You have received a new @mail from %s\"",
"%",
"caller",
")",
"new_message"... | [
100,
4
] | [
121,
18
] | python | en | ['en', 'error', 'th'] | False |
setup_script_registry | () |
Loads the scripts so that @register_script is hit for all.
|
Loads the scripts so that | def setup_script_registry():
"""
Loads the scripts so that @register_script is hit for all.
"""
for module in pkgutil.iter_modules(parlai.scripts.__path__, 'parlai.scripts.'):
importlib.import_module(module.name) | [
"def",
"setup_script_registry",
"(",
")",
":",
"for",
"module",
"in",
"pkgutil",
".",
"iter_modules",
"(",
"parlai",
".",
"scripts",
".",
"__path__",
",",
"'parlai.scripts.'",
")",
":",
"importlib",
".",
"import_module",
"(",
"module",
".",
"name",
")"
] | [
31,
0
] | [
36,
44
] | python | en | ['en', 'error', 'th'] | False |
superscript_main | (args=None) |
Superscript is a loader for all the other scripts.
|
Superscript is a loader for all the other scripts.
| def superscript_main(args=None):
"""
Superscript is a loader for all the other scripts.
"""
setup_script_registry()
parser = _SupercommandParser(
False, False, formatter_class=_SuperscriptHelpFormatter
)
parser.add_argument(
'--helpall',
action='helpall',
hel... | [
"def",
"superscript_main",
"(",
"args",
"=",
"None",
")",
":",
"setup_script_registry",
"(",
")",
"parser",
"=",
"_SupercommandParser",
"(",
"False",
",",
"False",
",",
"formatter_class",
"=",
"_SuperscriptHelpFormatter",
")",
"parser",
".",
"add_argument",
"(",
... | [
223,
0
] | [
305,
79
] | python | en | ['en', 'error', 'th'] | False |
ParlaiScript.setup_args | (cls) |
Create the parser with args.
|
Create the parser with args.
| def setup_args(cls) -> ParlaiParser:
"""
Create the parser with args.
""" | [
"def",
"setup_args",
"(",
"cls",
")",
"->",
"ParlaiParser",
":"
] | [
48,
4
] | [
51,
11
] | python | en | ['en', 'error', 'th'] | False |
ParlaiScript.run | (self) |
The main method.
Must be implemented by the script writer.
|
The main method. | def run(self):
"""
The main method.
Must be implemented by the script writer.
"""
raise NotImplementedError() | [
"def",
"run",
"(",
"self",
")",
":",
"raise",
"NotImplementedError",
"(",
")"
] | [
58,
4
] | [
64,
35
] | python | en | ['en', 'error', 'th'] | False |
ParlaiScript._run_kwargs | (cls, kwargs: Dict[str, Any]) |
Construct and run the script using kwargs, pseudo-parsing them.
|
Construct and run the script using kwargs, pseudo-parsing them.
| def _run_kwargs(cls, kwargs: Dict[str, Any]):
"""
Construct and run the script using kwargs, pseudo-parsing them.
"""
parser = cls.setup_args()
opt = parser.parse_kwargs(**kwargs)
return cls._run_from_parser_and_opt(opt, parser) | [
"def",
"_run_kwargs",
"(",
"cls",
",",
"kwargs",
":",
"Dict",
"[",
"str",
",",
"Any",
"]",
")",
":",
"parser",
"=",
"cls",
".",
"setup_args",
"(",
")",
"opt",
"=",
"parser",
".",
"parse_kwargs",
"(",
"*",
"*",
"kwargs",
")",
"return",
"cls",
".",
... | [
67,
4
] | [
73,
56
] | python | en | ['en', 'error', 'th'] | False |
ParlaiScript._run_args | (cls, args: Optional[List[str]] = None) |
Construct and run the script using args, defaulting to getting from CLI.
|
Construct and run the script using args, defaulting to getting from CLI.
| def _run_args(cls, args: Optional[List[str]] = None):
"""
Construct and run the script using args, defaulting to getting from CLI.
"""
parser = cls.setup_args()
opt = parser.parse_args(args=args)
return cls._run_from_parser_and_opt(opt, parser) | [
"def",
"_run_args",
"(",
"cls",
",",
"args",
":",
"Optional",
"[",
"List",
"[",
"str",
"]",
"]",
"=",
"None",
")",
":",
"parser",
"=",
"cls",
".",
"setup_args",
"(",
")",
"opt",
"=",
"parser",
".",
"parse_args",
"(",
"args",
"=",
"args",
")",
"re... | [
76,
4
] | [
82,
56
] | python | en | ['en', 'error', 'th'] | False |
ParlaiScript.main | (cls, *args, **kwargs) |
Run the program, possibly with some given args.
You may provide command line args in the form of strings, or
options. For example:
>>> MyScript.main(['--task', 'convai2'])
>>> MyScript.main(task='convai2')
You may not combine both args and kwargs.
|
Run the program, possibly with some given args. | def main(cls, *args, **kwargs):
"""
Run the program, possibly with some given args.
You may provide command line args in the form of strings, or
options. For example:
>>> MyScript.main(['--task', 'convai2'])
>>> MyScript.main(task='convai2')
You may not combine... | [
"def",
"main",
"(",
"cls",
",",
"*",
"args",
",",
"*",
"*",
"kwargs",
")",
":",
"assert",
"not",
"(",
"bool",
"(",
"args",
")",
"and",
"bool",
"(",
"kwargs",
")",
")",
"if",
"args",
":",
"return",
"cls",
".",
"_run_args",
"(",
"args",
")",
"eli... | [
91,
4
] | [
109,
38
] | python | en | ['en', 'error', 'th'] | False |
_SupercommandParser.print_help | (self) |
Print help, possibly deferring to the appropriate subcommand.
|
Print help, possibly deferring to the appropriate subcommand.
| def print_help(self):
"""
Print help, possibly deferring to the appropriate subcommand.
"""
if self._help_subparser:
self._help_subparser.print_help()
else:
return super().print_help() | [
"def",
"print_help",
"(",
"self",
")",
":",
"if",
"self",
".",
"_help_subparser",
":",
"self",
".",
"_help_subparser",
".",
"print_help",
"(",
")",
"else",
":",
"return",
"super",
"(",
")",
".",
"print_help",
"(",
")"
] | [
167,
4
] | [
174,
39
] | python | en | ['en', 'error', 'th'] | False |
_SupercommandParser._unsuppress_hidden | (self) |
Restore the help messages of hidden commands.
|
Restore the help messages of hidden commands.
| def _unsuppress_hidden(self):
"""
Restore the help messages of hidden commands.
"""
spa = [a for a in self._actions if isinstance(a, argparse._SubParsersAction)]
assert len(spa) == 1
spa = spa[0]
for choices_action in spa._choices_actions:
dest = choi... | [
"def",
"_unsuppress_hidden",
"(",
"self",
")",
":",
"spa",
"=",
"[",
"a",
"for",
"a",
"in",
"self",
".",
"_actions",
"if",
"isinstance",
"(",
"a",
",",
"argparse",
".",
"_SubParsersAction",
")",
"]",
"assert",
"len",
"(",
"spa",
")",
"==",
"1",
"spa"... | [
179,
4
] | [
190,
67
] | python | en | ['en', 'error', 'th'] | False |
Font.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
] | [
64,
28
] | python | en | ['en', 'error', 'th'] | False |
Font.colorsrc | (self) |
Sets the source reference on Chart Studio Cloud for color .
The 'colorsrc' 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 color .
The 'colorsrc' property must be specified as a string or
as a plotly.grid_objs.Column object | def colorsrc(self):
"""
Sets the source reference on Chart Studio Cloud for color .
The 'colorsrc' property must be specified as a string or
as a plotly.grid_objs.Column object
Returns
-------
str
"""
return self["colorsrc"] | [
"def",
"colorsrc",
"(",
"self",
")",
":",
"return",
"self",
"[",
"\"colorsrc\"",
"]"
] | [
73,
4
] | [
84,
31
] | python | en | ['en', 'error', 'th'] | False |
Font.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\"",
"]"
] | [
93,
4
] | [
116,
29
] | python | en | ['en', 'error', 'th'] | False |
Font.familysrc | (self) |
Sets the source reference on Chart Studio Cloud for family .
The 'familysrc' 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 family .
The 'familysrc' property must be specified as a string or
as a plotly.grid_objs.Column object | def familysrc(self):
"""
Sets the source reference on Chart Studio Cloud for family .
The 'familysrc' property must be specified as a string or
as a plotly.grid_objs.Column object
Returns
-------
str
"""
return self["familysrc"] | [
"def",
"familysrc",
"(",
"self",
")",
":",
"return",
"self",
"[",
"\"familysrc\"",
"]"
] | [
125,
4
] | [
136,
32
] | python | en | ['en', 'error', 'th'] | False |
Font.size | (self) |
The 'size' property is a number and may be specified as:
- An int or float in the interval [1, inf]
- A tuple, list, or one-dimensional numpy array of the above
Returns
-------
int|float|numpy.ndarray
|
The 'size' property is a number and may be specified as:
- An int or float in the interval [1, inf]
- A tuple, list, or one-dimensional numpy array of the above | def size(self):
"""
The 'size' property is a number and may be specified as:
- An int or float in the interval [1, inf]
- A tuple, list, or one-dimensional numpy array of the above
Returns
-------
int|float|numpy.ndarray
"""
return self["size"... | [
"def",
"size",
"(",
"self",
")",
":",
"return",
"self",
"[",
"\"size\"",
"]"
] | [
145,
4
] | [
155,
27
] | python | en | ['en', 'error', 'th'] | False |
Font.sizesrc | (self) |
Sets the source reference on Chart Studio Cloud for size .
The 'sizesrc' 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 size .
The 'sizesrc' property must be specified as a string or
as a plotly.grid_objs.Column object | def sizesrc(self):
"""
Sets the source reference on Chart Studio Cloud for size .
The 'sizesrc' property must be specified as a string or
as a plotly.grid_objs.Column object
Returns
-------
str
"""
return self["sizesrc"] | [
"def",
"sizesrc",
"(",
"self",
")",
":",
"return",
"self",
"[",
"\"sizesrc\"",
"]"
] | [
164,
4
] | [
175,
30
] | python | en | ['en', 'error', 'th'] | False |
Font.__init__ | (
self,
arg=None,
color=None,
colorsrc=None,
family=None,
familysrc=None,
size=None,
sizesrc=None,
**kwargs
) |
Construct a new Font object
Sets the font used in hover labels.
Parameters
----------
arg
dict of properties compatible with this constructor or
an instance of
:class:`plotly.graph_objs.area.hoverlabel.Font`
color
co... |
Construct a new Font object
Sets the font used in hover labels. | def __init__(
self,
arg=None,
color=None,
colorsrc=None,
family=None,
familysrc=None,
size=None,
sizesrc=None,
**kwargs
):
"""
Construct a new Font object
Sets the font used in hover labels.
Parameters
... | [
"def",
"__init__",
"(",
"self",
",",
"arg",
"=",
"None",
",",
"color",
"=",
"None",
",",
"colorsrc",
"=",
"None",
",",
"family",
"=",
"None",
",",
"familysrc",
"=",
"None",
",",
"size",
"=",
"None",
",",
"sizesrc",
"=",
"None",
",",
"*",
"*",
"kw... | [
215,
4
] | [
329,
34
] | python | en | ['en', 'error', 'th'] | False |
dbref | (inp, reqhash=True) |
Valid forms of dbref (database reference number) are either a
string '#N' or an integer N.
Args:
inp (int or str): A possible dbref to check syntactically.
reqhash (bool): Require an initial hash `#` to accept.
Returns:
is_dbref (int or None): The dbref integer part if a valid... |
Valid forms of dbref (database reference number) are either a
string '#N' or an integer N. | def dbref(inp, reqhash=True):
"""
Valid forms of dbref (database reference number) are either a
string '#N' or an integer N.
Args:
inp (int or str): A possible dbref to check syntactically.
reqhash (bool): Require an initial hash `#` to accept.
Returns:
is_dbref (int or Non... | [
"def",
"dbref",
"(",
"inp",
",",
"reqhash",
"=",
"True",
")",
":",
"if",
"reqhash",
"and",
"not",
"(",
"isinstance",
"(",
"inp",
",",
"basestring",
")",
"and",
"inp",
".",
"startswith",
"(",
"\"#\"",
")",
")",
":",
"return",
"None",
"if",
"isinstance... | [
31,
0
] | [
54,
14
] | python | en | ['en', 'error', 'th'] | False |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.