Lifecycle functions#

set_cache_dir_cuda#

int set_cache_dir_cuda(const char *dir) noexcept#

Sets the disk cache directory for CUDA log signature data.

This should match the directory used by cpsig, as both libraries share the same disk cache format.

Parameters:

dir – Path to the cache directory.

Returns:

Status code (0 = success).

clear_cache_cuda#

int clear_cache_cuda(bool use_disk = false) noexcept#

Clears all GPU-side cached data for log signature computation.

Parameters:

use_disk – If true, also delete the shared disk cache.

Returns:

Status code (0 = success).

cusig_shutdown#

void cusig_shutdown() noexcept#

Release all cached device allocations and the CUDA stream pool. Synchronizes the device first. Idempotent.


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}
}