pycognaize.document.field.section_field.SectionField
- class SectionField(name, value='', ocr_value='', tags=None, field_id=None, group_key=None, confidence=-1.0, group_name=None, mapping=None)[source]
Bases:
Field
Base class for all pycognaize Section fields
- Parameters:
name (
str
)value (
str
)ocr_value (
str
)tags (
Optional
[List
[SectionTag
]])field_id (
Optional
[str
])group_key (
str
)confidence (
Optional
[float
])group_name (
str
)mapping (
Optional
[List
[Dict
[str
,str
]]])
Methods
Create SectionField object from dictionary
Converts SectionField object to dictionary
Attributes
classes
classification_labels
confidence
Returns the end tag of the field
field_id
group_key
group_name
mapping
name
raw_value
Returns the start tag of the field
tags
value
- classmethod construct_from_raw(raw, pages, html=None, labels=None)[source]
Create SectionField object from dictionary
- Parameters:
- Return type:
- property end: SectionTag | None
Returns the end tag of the field
- property start: SectionTag | None
Returns the start tag of the field
- tag_class
alias of
SectionTag