pasteur.table.SeqTransformerWrapper#
- class pasteur.table.SeqTransformerWrapper(modules, parent=None, seq=None, ctx=None, seq_col=None, ctx_to_ref=None, order=None, max_len=None, first_seq_ref_itself=False, ref=None, **kwargs)[source]#
Attributes
For a given output, the input is the same.
The decoded output equals the input.
Transformer fits variables.
Methods
fit(table, data, ref, ids[, seq_val, seq])Fits to the provided data
fit_transform(table, data[, ref, ids, ...])get_factory(*args, **kwargs)Returns a factory that registers this module to the system.
reduce(other)reverse(data, ctx, ref, ids)When reversing, the data column contains encoded data, whereas the ref column contains decoded/original data.
transform(data, ref, ids[, seq])- deterministic = True#
For a given output, the input is the same.
- fit(table, data, ref, ids, seq_val=None, seq=None)[source]#
Fits to the provided data
- Return type:
tuple[SeqValue,Series] |None
- fit_transform(table, data, ref=None, ids=None, seq_val=None, seq=None)#
- Return type:
tuple[DataFrame,dict[str,DataFrame]] |tuple[DataFrame,dict[str,DataFrame],Series]
- classmethod get_factory(*args, **kwargs)#
Returns a factory that registers this module to the system.
Any *args and **kwargs passed to this function will be saved and passed to the module’s __init__() method when calling build().
- lossless = True#
The decoded output equals the input.
-
mode:
Literal['dual','single','notrn']#
-
name:
str= 'seq'#
- reverse(data, ctx, ref, ids)[source]#
When reversing, the data column contains encoded data, whereas the ref column contains decoded/original data. Therefore, the referred columns have to be decoded first.
- Return type:
DataFrame
- stateful = False#
Transformer fits variables.