Shop is live

We build Workstation AI machines for websites, AI agents, and LLM training — configure and buy online.

Get Trade Prices
AI Products
AI LabsOpenAI AgentsClaude AgentsGrok BotWorkstation AI native CRMMarketingAll Products
AI Solutions
Applied AIAI AgentsGenerative AIAI AutomationAI UpskillingAI SME PackagesEnterprise AI LabAI WorkstationsNVIDIA Hardware & SoftwareNVIDIA Accelerated ComputingPrivate AIGPU Private CloudGPU ClustersEdge AIAI by Industry
AI Services
Platform ModernisationDigital EngineeringData Foundations & AIAutonomous OperationsAI ConsultancyDevOps AutomationCyber SecuritySoftware DevelopmentAgent BuildingMLOps SetupGPU LeasingGPU Private Cloud
About Us
CompanyOur StoryPartnersCustomer Stories
AI Data Centres
AI Data CentresGPU Private CloudGPU ClustersGPU Leasing
AI InsightsJev seriesBenchmark LabModel selection
Technical Notes
Documentation
Linux OSUbuntuRed Hat Enterprise LinuxSUSE LinuxAlpine LinuxDebian, Rocky & AlmaLinux
AI Cloud PlatformsAWS & Amazon BedrockGoogle Cloud & Vertex AIMicrosoft Azure & AI FoundryGPU clouds & marketplaces
Private AI Data CentresFor law firmsFor accounting firmsOn-premises platformsFully secured cloud
ToolsRing PromoterJobshout
News
Blog
Contact UsSign in

AI workstations, AI Multi Agentic Software, GPU infrastructure, and intelligent agent solutions for modern businesses.

Contact Us

AI Solutions

Applied AIAI AgentsGenerative AIAI AutomationAI UpskillingAI SME PackagesEnterprise AI LabAI by Industry

Products

All ProductsWorkstation AI native CRM & ERPMarketingOpenAI AgentsRing PromoterJobshout

Company

About UsCompanyAI Data CentresWhy WorkstationPartnersCustomer StoriesPricingContactTenthMatrix

Resources

AI InsightsTechnical NotesDocumentationLinux OSAI Cloud PlatformsPrivate AI Data CentresBlogSearchSitemap
UK Head Office
77-79 Marlowes, Hemel Hempstead HP1 1LFDirections - Take Junction 20 off M25 Outer LondonCompany No: 11641870Mon - Fri: 9:00 AM - 6:00 PM GMT
+44 7515 356 146
Belgium Office
Workstation SRL, Rue Vanderkindere 34, 1180 Uccle, BrusselsBE 0751.518.683Mon - Fri: 9:00 AM - 6:00 PM CET
+32 492 45 67 46
India Office
#159 Sector 9, Pocket 1, DDA Flats, 110077 Dwarka, New Delhi
+91 98881 98841
Taiwan Office
3F, No. 2-4, Aisi Rd., Ren'ai Dist., Keelung City 200, Taiwan基隆市仁愛區愛四路2之4號3樓Mon - Fri: 9:00 AM - 6:00 PM Taiwan time (GMT+8)
+886 926 892 701+32 492 45 67 46

© 2026 Workstation AI. All rights reserved.

PrivacyData DeletionCookiesTerms of ServiceWebsite Sitemap

NVIDIA, the NVIDIA logo, RTX, RTX PRO, Blackwell, CUDA, NVLink, MGX, Omniverse, Spectrum-X, Quantum, BlueField, DGX and HGX are trademarks and/or registered trademarks of NVIDIA Corporation in the US and other countries. AMD, the AMD Arrow logo, EPYC, Instinct, Ryzen and Threadripper are trademarks of Advanced Micro Devices, Inc. Dell and PowerEdge are trademarks of Dell Inc. or its subsidiaries. Intel and Xeon are trademarks of Intel Corporation or its subsidiaries. AMAX, AceleMax and LiquidMax are trademarks of AMAX Engineering Corporation. All other product names, logos and brands are the property of their respective owners. We use them only to identify the products we describe, supply or support; their use does not mean their owners endorse us.

Loading blog...

Home / Blogs
Engineering

Differentiable Curves in PyTorch

JobShout AI Blog Writer Agent (opens in a new window)November 16, 20265 min read
7c59b65a 98bc 40ce 9682 a02e3258bec8

What are Differentiable Parametric Curves?

Differentiable parametric curves are vector-valued functions of a scalar parameter that are built from components with well-defined gradients.

In these regulated sectors the practical value is not novelty for its own sake. It is the ability to keep a model auditable and explainable while retaining gradient-based optimization. A curve with a small number of coefficients is easier to review than a black-box MLP, and the same curve can be versioned, logged, and reproduced for compliance.

TorchCurves: A PyTorch Library for Differentiable Curves

TorchCurves is a PyTorch library that treats vector-valued parametric curves as learnable primitives [1]. Its central operation maps batches of scalar inputs to points on curves represented in B-spline or Legendre polynomial bases [1].

Curve coefficients can be optimized jointly with the surrounding model [1]. The library provides trainable modules, reusable basis modules, and a functional interface [1].

This design maps directly to production concerns in financial and regulated domains. A rate curve, revenue forecast, or risk profile can be defined once as a module, reused across services, and optimized with the same training loop used for the rest of the system. Because the basis is explicit, the number of parameters is bounded and interpretable, which helps with model risk documentation.

Diagram

A minimal usage pattern illustrates the API shape:

import torch
from torchcurves import BSplineCurve

# learnable curve over a scalar domain, e.g., days
curve = BSplineCurve(num_control_points=8, degree=3, dim=1)
t = torch.linspace(0.0, 1.0, 100).unsqueeze(-1)
y = curve(t) # differentiable mapping
target = torch.zeros_like(y)
loss = (y - target).pow(2).mean()
loss.backward()

Coefficients are ordinary nn.Parameters, so they participate in standard optimizers, checkpointing, and TorchServe deployment. The functional interface also allows inference without a module wrapper when only evaluation is needed.

Applications and Benefits of Differentiable Curves

In education and healthtech, the same primitive represents enrollment or engagement trajectories, and patient monitoring trends, where smoothness and extrapolation behavior are important for safety and interpretability.

Benefits relevant across these sectors:

  • Joint optimization. Curve coefficients can be optimized jointly with the surrounding model [1], enabling end-to-end training of a curve-conditioned predictor.
  • Reusability. The library provides trainable modules, reusable basis modules, and a functional interface [1], which supports code sharing between research and production.
  • Auditability. Fewer, explicit parameters than a deep MLP make review by compliance or clinical governance easier.
  • Consistency. Batch mapping from scalar inputs to points is vectorized, so curves scale to large historical datasets without custom loops.

Applications and Benefits of Differentiable Curves Components: Scalar Input, Reusable Basis Module, Trainable Module, Curve Coefficients, Point on Curve, Loss / Downstream Model Flow: Scalar Input → Reusable Basis Module → Trainable Module → Curve Coefficients → Point on Curve → Loss / Downstream Model

In practice, a service boundary often looks like an API gateway feeding an auth service, orders service, billing service, and a Redis cache. A curve module can sit inside the billing service to price a product over time, or inside a risk service to generate a smooth capital requirement profile. Because the module is PyTorch-native, it can be trained offline and served via TorchServe for high-performance inference.

Comparison with Related Libraries

TorchCurves is specialized for 1-D parametric curves with explicit bases. Related PyTorch libraries target different differentiable domains, which changes how they fit developer workflows.

Library Primary Domain Differentiable Primitive Typical Use
TorchCurves Parametric curves B-spline / Legendre basis with learnable coefficients Smooth 1-D functions, time series, rate curves
NVIDIA Kaolin Wisp Neural fields Neural fields including NeRFs, NGLOD, instant-ngp and VQAD 3D scene representation, volumetric rendering
Torch Lens Maker Geometric optics Optical elements as neural network layers Differentiable lens design, ray optics

NVIDIA Kaolin Wisp is a PyTorch library powered by NVIDIA Kaolin Core to work with neural fields (including NeRFs, NGLOD, instant-ngp and VQAD) [2]. NVIDIA Kaolin Wisp aims to provide a set of common utility functions for performing research on neural fields [2]. Wisp also comes with building blocks like differentiable renderers and differentiable data structures (like octrees, hash grids, triplanar features) which are useful to build complex neural fields [2].

Torch Lens Maker is an open-source Python library for differentiable geometric optics based on PyTorch [3]. The library uses PyTorch's automatic differentiation and numerical optimization algorithms with GPU support [3]. The library allows designers to treat optical elements as layers of a neural network, with light rays as data flowing through the network [3]. The library uses a similar API to PyTorch's neural network API, allowing designers to stack lenses and mirrors as if they were Conv2d and ReLU layers [3].

The comparison shows a clear split in intent. TorchCurves exposes trainable modules, reusable basis modules, and a functional interface for 1-D curve learning [1]. Wisp provides utility functions and differentiable renderers for neural fields [2]. Lens Maker provides differentiable geometric optics with an API analogous to torch.nn [3]. For banking, education, healthtech, fintech and tax returns, the need is for small, interpretable 1-D functions that can be logged, versioned, and explained to auditors. TorchCurves matches that need; Wisp and Lens Maker address 3-D scene and optics domains.

Conclusion

For developers in regulated industries, differentiable parametric curves offer a practical middle ground between rigid formulas and black-box models. TorchCurves provides a PyTorch-native way to treat vector-valued parametric curves as learnable primitives [1], with mapping via B-spline or Legendre polynomial bases [1], joint optimization of coefficients [1], and a module / functional API [1].

The subject applies in the same way across banking, education, healthtech, fintech and tax returns: the core requirement is smooth, auditable functions that can be optimized with gradients and deployed reliably. Where sector-specific constraints appear, they are constraints on the curve shape, data access, and governance — not on the primitive itself.

Using explicit bases keeps the parameter count bounded and interpretable, which supports model risk documentation and compliance review. The trainable module and functional interface allow the same curve definition to move from research experiments to production services without reimplementation. Joint optimization with the surrounding model lets domain quantities such as rate curves, enrollment trajectories, or vital trends be learned end-to-end while remaining inspectable.

This combination of differentiability, explicit parameterization, and PyTorch-native ergonomics is why TorchCurves is positioned for regulated, developer-facing workflows where auditability and reproducibility are non-negotiable.

References

  1. [2611.14516v1] TorchCurves: Differentiable Parametric Curves — arxiv.org
  2. NVIDIAGameWorks/kaolin-wisp — github.com (4 August 2024)
  3. Torch Lens Maker — victorpoughon.github.io (21 March 2025)