class VAMPNetModel¶
- class deeptime.decomposition.deep.VAMPNetModel(lobe: ~torch.nn.modules.module.Module, lobe_timelagged: ~typing.Optional[~torch.nn.modules.module.Module] = None, dtype=<class 'numpy.float32'>, device=None)¶
A VAMPNet model which can be fit to data optimizing for one of the implemented VAMP scores.
- Parameters:
lobe (torch.nn.Module) – One of the lobes of the VAMPNet. See also
deeptime.util.torch.MLP
.lobe_timelagged (torch.nn.Module, optional, default=None) – The timelagged lobe. Can be left None, in which case the lobes are shared.
dtype (data type, default=np.float32) – The data type for which operations should be performed. Leads to an appropriate cast within fit and transform methods.
device (device, default=None) – The device for the lobe(s). Can be None which defaults to CPU.
See also
VAMPNet
The corresponding estimator.
Attributes
The instantaneous lobe.
The timelagged lobe.
Methods
copy
()Makes a deep copy of this model.
get_params
([deep])Get the parameters.
set_params
(**params)Set the parameters of this estimator.
transform
(data[, instantaneous])Transforms data through the instantaneous or time-shifted network lobe.
- __call__(*args, **kwargs)¶
Call self as a function.
- copy() Model ¶
Makes a deep copy of this model.
- Returns:
A new copy of this model.
- Return type:
copy
- get_params(deep=False)¶
Get the parameters.
- Returns:
params – Parameter names mapped to their values.
- Return type:
mapping of string to any
- set_params(**params)¶
Set the parameters of this estimator.
The method works on simple estimators as well as on nested objects (such as pipelines). The latter have parameters of the form
<component>__<parameter>
so that it’s possible to update each component of a nested object.- Parameters:
**params (dict) – Estimator parameters.
- Returns:
self – Estimator instance.
- Return type:
object
- transform(data, instantaneous: bool = True, **kwargs)¶
Transforms data through the instantaneous or time-shifted network lobe.
- Parameters:
data (numpy array or torch tensor) – The data to transform.
instantaneous (bool, default=True) – Whether to use the instantaneous lobe or the time-shifted lobe for transformation.
**kwargs – Ignored kwargs for api compatibility.
- Returns:
transform – List of numpy array or numpy array containing transformed data.
- Return type:
array_like
- property lobe: Module¶
The instantaneous lobe.
- Returns:
lobe
- Return type:
nn.Module