_utils#
Helper functions for PyTorch forecasting
Functions
|
Apply function to a list of objects or directly if passed value is not a list. |
|
Computes the autocorrelation of samples at dimension |
|
Concatenate RNN sequences. |
|
Create boolean masks of shape len(lenghts) x size. |
|
Detach object |
|
Determine empirically good embedding sizes (formula taken from fastai). |
|
Groupby apply for torch tensors |
|
Create histogram of integers in predefined range |
|
Calculate operation on masked tensor. |
|
Move object to device. |
|
Returns the next largest number |
|
Stack tensors along first dimension and pad them along last dimension to ensure their size is equal. |
|
Profile a given function with |
|
Print class name and parameters. |
|
Convert value or list to list of values. |
|
Unpack RNN sequence. |
|
Unsqueeze last dimensions of tensor to match another tensor's number of dimensions. |
Classes
MixIn to give namedtuple some access capabilities of a dictionary |
|
MixIn to give output a namedtuple-like access capabilities with |