visions.typesets.VisionsTypeset
- class visions.typesets.VisionsTypeset(types)[source]
A collection of
visions.types.type.VisionsBaseType
with associated relationship map between them.- types
The collection of Visions Types derived from
visions.types.type.VisionsBaseType
- base_graph
The graph of relations composed exclusively of
visions.relations.relations.IdentityRelation
- relation_graph
The full relation graph including both
visions.relations.relations.IdentityRelation
andvisions.relations.relations.InferenceRelation
- Parameters
types (
Set
[Type
[VisionsBaseType
]]) – a set of types
- __init__(types)[source]
- Parameters
types (
Set
[Type
[VisionsBaseType
]]) – a set of types
Methods
__init__
(types)- type types
Set
[Type
[VisionsBaseType
]]
cast_to_detected
(data)Transforms input data into a canonical representation using only IdentityRelations
cast_to_inferred
(data)Transforms input data and returns it's corresponding new type relation using all relations.
detect
(data)The results found after only considering IdentityRelations.
detect_type
(data)The inferred type found only considering IdentityRelations.
infer
(data)The results found after considering all relations.
infer_type
(data)The inferred type found using all type relations.
output_graph
(file_name[, base_only, dpi])Write the type graph to a file.
plot_graph
([dpi, base_only, figsize])- type dpi
int
replace
(old, new)Create a new typeset having replace one type with another.
Attributes
root_node
Returns a cached copy of the relation_graphs root node