pysiglib.log_sig_combine_backprop#
Warning
Where possible, pysiglib.torch_api should be used rather than explicitly calling
backpropagation functions. Explicit backpropagation can introduce subtle errors if called
incorrectly. In addition, some pysiglib functions can only be backpropagated through
using their pysiglib.torch_api variants and do not expose explicit backpropagation functions.
- log_sig_combine_backprop(deriv, ls1, ls2, dimension, degree, *, time_aug=False, lead_lag=False, n_jobs=1)[source]#
Backpropagation through
log_sig_combine(). Given derivatives of a scalar function \(F\) with respect to the output oflog_sig_combine, computes the derivatives with respect to the two input log-signatures.- Parameters:
deriv (numpy.ndarray | torch.tensor) – Derivative with respect to the combined log-signature
ls1 (numpy.ndarray | torch.tensor) – The first truncated log-signature (Lyndon basis, method=2 or method=3)
ls2 (numpy.ndarray | torch.tensor) – The second truncated log-signature (Lyndon basis, method=2 or method=3)
dimension (int) – Dimension of the underlying space
degree (int) – Truncation level of the log-signatures
time_aug (bool) – Whether time augmentation was applied
lead_lag (bool) – Whether the lead-lag transformation was applied
n_jobs (int) – Number of threads (CPU only)
- Returns:
Derivatives with respect to
ls1andls2- Return type:
Tuple[numpy.ndarray | torch.tensor, numpy.ndarray | torch.tensor]
Citation#
If you found this library useful in your research, please consider citing the paper:
@article{shmelev2025pysiglib,
title={pySigLib-Fast Signature-Based Computations on CPU and GPU},
author={Shmelev, Daniil and Salvi, Cristopher},
journal={arXiv preprint arXiv:2509.10613},
year={2025}
}