module grammar_sklearn.grammar.gtypes
¶
Short summary¶
module mlprodict.grammar_sklearn.grammar.gtypes
Types definition.
Classes¶
class |
truncated documentation |
---|---|
Base class for numerical types. |
|
A numpy.bool. |
|
A numpy.float32. |
|
A numpy.float64. |
|
A numpy.int32. |
|
A numpy.int64. |
|
int32 or float32 |
|
Defines a tensor with a dimension and a single type for what it contains. |
|
Base class for every type. |
Properties¶
property |
truncated documentation |
---|---|
|
Returns ctype. |
|
Returns ctype. |
|
Returns ctype. |
|
Returns ctype. |
|
Returns ctype. |
Returns ctype. |
|
Returns ctype. |
Methods¶
method |
truncated documentation |
---|---|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
Converts value into this type. |
|
Exports value into this type. |
|
Exports value into this type. |
|
Exports value into this type. |
|
Exports value into this type. |
|
Exports value into this type. |
Exports value into this type. |
|
|
Converts value into this type. |
Converts value into this type. |
|
|
Exports value into this type, does it anyway without verification. |
|
Exports value into this type, does it anyway without verification. |
|
Exports value into this type, does it anyway without verification. |
|
Exports value into this type, does it anyway without verification. |
|
Exports value into this type, does it anyway without verification. |
Exports value into this type, does it anyway without verification. |
|
|
Checks that the value is of this type. |
|
Checks that the value is of this type. |
|
Checks that the value is of this type. |
|
Checks that the value is of this type. |
|
Checks that the value is of this type. |
|
Checks that the value is of this type. |
Checks that the value is of this type. |
|
Checks that the value is of this type. |
|
Checks that the value is of this type. |
Documentation¶
Types definition.
- class mlprodict.grammar_sklearn.grammar.gtypes.MLNumType¶
Bases:
mlprodict.grammar_sklearn.grammar.gtypes.MLType
Base class for numerical types.
- _copy_c(src, dst, hook=None)¶
- _format_value_c(value, hook=None)¶
- _format_value_json(value, hook=None)¶
- class mlprodict.grammar_sklearn.grammar.gtypes.MLNumTypeBool¶
Bases:
mlprodict.grammar_sklearn.grammar.gtypes.MLNumTypeSingle
A numpy.bool.
- __init__()¶
- class mlprodict.grammar_sklearn.grammar.gtypes.MLNumTypeFloat32¶
Bases:
mlprodict.grammar_sklearn.grammar.gtypes.MLNumTypeSingle
A numpy.float32.
- __init__()¶
- class mlprodict.grammar_sklearn.grammar.gtypes.MLNumTypeFloat64¶
Bases:
mlprodict.grammar_sklearn.grammar.gtypes.MLNumTypeSingle
A numpy.float64.
- __init__()¶
- class mlprodict.grammar_sklearn.grammar.gtypes.MLNumTypeInt32¶
Bases:
mlprodict.grammar_sklearn.grammar.gtypes.MLNumTypeSingle
A numpy.int32.
- __init__()¶
- class mlprodict.grammar_sklearn.grammar.gtypes.MLNumTypeInt64¶
Bases:
mlprodict.grammar_sklearn.grammar.gtypes.MLNumTypeSingle
A numpy.int64.
- __init__()¶
- class mlprodict.grammar_sklearn.grammar.gtypes.MLNumTypeSingle(numpy_type, name, ctype, key)¶
Bases:
mlprodict.grammar_sklearn.grammar.gtypes.MLNumType
int32 or float32
- property CTypeSingle¶
Returns ctype.
- __init__(numpy_type, name, ctype, key)¶
- _byref_c()¶
- _export_c(hook=None, result_name=None)¶
- _export_common_c(ctype, hook=None, result_name=None)¶
- _export_json(hook=None, result_name=None)¶
- _format_value_c(value, hook=None)¶
- _format_value_json(value, hook=None)¶
- cast(value)¶
Exports value into this type.
- softcast(value)¶
Exports value into this type, does it anyway without verification.
- validate(value)¶
Checks that the value is of this type.
- class mlprodict.grammar_sklearn.grammar.gtypes.MLTensor(element_type, dim)¶
Bases:
mlprodict.grammar_sklearn.grammar.gtypes.MLType
Defines a tensor with a dimension and a single type for what it contains.
- property CTypeSingle¶
Returns ctype.
- __init__(element_type, dim)¶
- _byref_c()¶
- _copy_c(src, dest, hook=None)¶
- _export_c(hook=None, result_name=None)¶
- _export_json(hook=None, result_name=None)¶
- _format_value_c(value, hook=None)¶
- _format_value_json(value, hook=None)¶
- validate(value)¶
Checks that the value is of this type.
- class mlprodict.grammar_sklearn.grammar.gtypes.MLType¶
Bases:
mlprodict.grammar_sklearn.grammar.api_extension.AutoType
Base class for every type.
- cast(value)¶
Converts value into this type.
- validate(value)¶
Checks that the value is of this type.