pymc-devs / pymc-devs/pytensor

Move more "experimental" backends to its own library

Open
#1,570 4 comments 2 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

backend compatibility refactor release
Dominant language
Python
Stars
644
Forks
208
Avg merge
2d 14h
Merged PRs (30d)
16

Description

Description

We have some limited support for PyTorch and coming up MLX, which are at a stage where they don't yet integrate well enough with PyTensor in general.

I suggest we create a separate package pytensor-backends for these. That way development stays more focused and we don't need to test for every PR to main. User experience would still be similar, except when they do pytensor.function(..., mode="PYTORCH") we try to import the pytensor-backends library and if missing tell user to go about installing it (together with the backend library).

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start at pytensor.function(..., mode="PYTORCH") and trace how that mode loads its backend; then map the existing PyTorch support and planned MLX support before deciding package boundaries. Done means experimental backends live in pytensor-backends, missing dependencies produce an installation message, and they no longer need testing on every PR to main.

Written by the indexing model from the issue text.

Assessment

Tech stack
python, pytorch
Domain
backend, machine-learning
Issue type
Feature
Difficulty
5/5
Estimated time
Over a week
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
25/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.