TorchCP: A Python Library for Conformal Prediction
Authors
Research Topics
Paper Information
-
Journal:
Journal of Machine Learning Research -
Added to Tracker:
Dec 30, 2025
Abstract
Conformal prediction (CP) is a powerful statistical framework that generates prediction intervals or sets with guaranteed coverage probability. While CP algorithms have evolved beyond traditional classifiers and regressors to sophisticated deep learning models like deep neural networks (DNNs), graph neural networks (GNNs), and large language models (LLMs), existing CP libraries often lack the model support and scalability for large-scale deep learning (DL) scenarios. This paper introduces TorchCP, a PyTorch-native library designed to integrate state-of-the-art CP algorithms into DL techniques, including DNN-based classifiers/regressors, GNNs, and LLMs. Released under the LGPL-3.0 license, TorchCP comprises about 16k lines of code, validated with 100% unit test coverage and detailed documentation. Notably, TorchCP enables CP-specific training algorithms, online prediction, and GPU-accelerated batch processing, achieving up to 90% reduction in inference time on large datasets. With its low-coupling design, comprehensive suite of advanced methods, and full GPU scalability, TorchCP empowers researchers and practitioners to enhance uncertainty quantification across cutting-edge applications.
Author Details
Jianguo Huang
AuthorJianqing Song
AuthorXuanning Zhou
AuthorBingyi Jing
AuthorHongxin Wei
AuthorResearch Topics & Keywords
Statistical Learning
Research AreaCitation Information
APA Format
Jianguo Huang
,
Jianqing Song
,
Xuanning Zhou
,
Bingyi Jing
&
Hongxin Wei
.
TorchCP: A Python Library for Conformal Prediction.
Journal of Machine Learning Research
.
BibTeX Format
@article{paper664,
title = { TorchCP: A Python Library for Conformal Prediction },
author = {
Jianguo Huang
and Jianqing Song
and Xuanning Zhou
and Bingyi Jing
and Hongxin Wei
},
journal = { Journal of Machine Learning Research },
url = { https://www.jmlr.org/papers/v26/24-2141.html }
}