Skip to content

deps: bump AiDotNet.Tensors + AiDotNet.Native.OpenBLAS to 0.50.0 - #1179

Merged
ooples merged 3 commits into
masterfrom
deps/bump-tensors-openblas-0.50.0
Apr 21, 2026
Merged

ooples merged 3 commits into
masterfrom
deps/bump-tensors-openblas-0.50.0

Conversation

@ooples

@ooples ooples commented Apr 20, 2026 •

Copy link
Copy Markdown
Owner

Summary

Bumps the two remaining AiDotNet ecosystem packages still behind the 0.50.0 line:

  • AiDotNet.Tensors 0.46.1 → 0.50.0
  • AiDotNet.Native.OpenBLAS 0.28.0 → 0.50.0

OneDNN and CLBlast were already at 0.50.0 on master.

Why this, not the dependabot PRs

Supersedes #1170 and #1171 (both dependabot-authored). Rebasing those branches onto current master would have produced valid results, but dependabot's anti-tamper auto-closes any PR whose branch is force-pushed by a non-bot account — which it did when I tried. Bundling both bumps into one human PR is the only workable path.

Test plan

  • dotnet build src/AiDotNet.csproj -f net10.0 → 0 errors
  • dotnet build src/AiDotNet.csproj -f net471 → 0 errors
  • CI: full test matrix on the PR

🤖 Generated with Claude Code

Summary by CodeRabbit

  • Chores

    • Updated numerical computing and linear algebra library versions.
  • Bug Fixes

    • Fixed tensor output propagation in compiled model prediction to ensure inference results are correctly returned.
    • Corrected compiled training step output handling to ensure loss values are properly computed and used during optimization.

…BLAS 0.28.0 -> 0.50.0

Unifies the AiDotNet ecosystem on 0.50.0:
  AiDotNet.Tensors              0.46.1 -> 0.50.0
  AiDotNet.Native.OneDNN        0.50.0 (already on 0.50.0)
  AiDotNet.Native.OpenBLAS      0.28.0 -> 0.50.0
  AiDotNet.Native.CLBlast       0.50.0 (already on 0.50.0)

Supersedes dependabot PRs #1170 (OpenBLAS) and #1171 (Tensors), which
dependabot auto-closed when the branches were rebased onto the current
master that already had OneDNN + CLBlast at 0.50.0. Bundling both into
one human-authored PR avoids the tamper-detection closure and keeps
all four native backends at the same release line.

Build: dotnet build -f net10.0 + net471 both green, 0 errors.
@vercel

vercel Bot commented Apr 20, 2026 •

Copy link
Copy Markdown

The latest updates on your projects. Learn more about Vercel for GitHub.

2 Skipped Deployments
Project Deployment Actions Updated (UTC)
aidotnet_website Ignored Ignored Apr 20, 2026 2:13pm
aidotnet-playground-api Ignored Ignored Preview Apr 20, 2026 2:13pm

@coderabbitai

coderabbitai Bot commented Apr 20, 2026 •

Copy link
Copy Markdown
Contributor

No actionable comments were generated in the recent review. 🎉

ℹ️ Recent review info
⚙️ Run configuration

Configuration used: Path: .coderabbit.yaml

Review profile: ASSERTIVE

Plan: Pro

Run ID: 7767a1bc-9cb5-4ab4-b472-c7bbe5bdf9cc

📥 Commits

Reviewing files that changed from the base of the PR and between cc1a1c0 and 43e4d73.

📒 Files selected for processing (3)
  • Directory.Packages.props
  • src/AiModelBuilder.cs
  • src/Training/CompiledTapeTrainingStep.cs

Walkthrough

This PR updates NuGet package dependencies and modifies graph tracing lambdas to explicitly return computed outputs. The inference trace lambda in AiModelBuilder.cs now returns the predicted tensor, while training trace lambdas in CompiledTapeTrainingStep.cs now return the scalar loss value, aligning with updated JIT compilation APIs.

Changes

Cohort / File(s) Summary
Dependency Updates
Directory.Packages.props
Bumped AiDotNet.Tensors from 0.46.1 to 0.50.1 and AiDotNet.Native.OpenBLAS from 0.28.0 to 0.50.0.
Inference Graph Tracing
src/AiModelBuilder.cs
Modified BuildCompiledPredictFunction trace lambda to return nnModel.Predict(input) instead of discarding the result, establishing the predicted tensor as the explicit compilation plan output.
Training Graph Tracing
src/Training/CompiledTapeTrainingStep.cs
Updated trace lambdas in both Step and TryStepWithFusedOptimizer to return computeLoss(predicted, target) instead of invoking without returning, conforming to GetOrCompileTraining API contract requiring Func<Tensor<T>> outputs.

Possibly related PRs

Estimated code review effort

🎯 3 (Moderate) | ⏱️ ~22 minutes

Poem

🧮 Lambdas now return what they've wrought,
No more silent tensor thoughts,
Loss and predictions, plainly sent—
The graph compiler's true intent. ✨

🚥 Pre-merge checks | ✅ 2 | ❌ 1

❌ Failed checks (1 warning)

Check name Status Explanation Resolution
Title check ⚠️ Warning The title 'deps: bump AiDotNet.Tensors + AiDotNet.Native.OpenBLAS to 0.50.0' accurately describes the primary change in Directory.Packages.props, but it omits that AiDotNet.Tensors was bumped to 0.50.1 (not 0.50.0) and significant API-driven code changes were made across multiple source files to accommodate tracer method signature changes. Revise the title to reflect the full scope of changes: something like 'deps: bump AiDotNet packages and adapt tracer API calls to Func<Tensor> signature' or split into separate commits with distinct titles to clarify the functional code changes versus dependency updates.
✅ Passed checks (2 passed)
Check name Status Explanation
Description Check ✅ Passed Check skipped - CodeRabbit’s high-level summary is enabled.
Docstring Coverage ✅ Passed Docstring coverage is 100.00% which is sufficient. The required threshold is 80.00%.

✏️ Tip: You can configure your own custom pre-merge checks in the settings.

✨ Finishing Touches
📝 Generate docstrings
  • Create stacked PR
  • Commit on current branch
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Commit unit tests in branch deps/bump-tensors-openblas-0.50.0

Comment @coderabbitai help to get the list of available commands and usage tips.

Tensors 0.50.1 is the release the open compile-tracer bugs point to;
0.50.0 was the one I initially pinned but it's strictly a prerequisite
step. The API change that matters for us:

  GetOrCompileInference / GetOrCompileTraining accept Func<Tensor<T>>
  (return = plan output tensor) instead of Action (tail-op inferred).

The explicit return fixes the shape-conditional truncation that forced
PR #1167's Predict-bypass workaround: the tracer no longer guesses
which op produced the plan's output, so rank-3 -> rank-4 promotions
and post-forward reshapes no longer get silently dropped.

Three call sites updated to return the last tensor explicitly:
  src/AiModelBuilder.cs:1344           — return nnModel.Predict(input)
  src/Training/CompiledTapeTrainingStep.cs:139  — return computeLoss(...)
  src/Training/CompiledTapeTrainingStep.cs:269  — return computeLoss(...)

Follow-up (separate PR): revert the 11 Predict-override-restore sites
from PR #1167 back to PredictEager now that the tracer actually
captures their forward behaviour correctly.

Build: dotnet build -f net10.0 + net471 both green, 0 errors.
@ooples

ooples commented Apr 20, 2026

Copy link
Copy Markdown
Owner Author

@coderabbitai review

@coderabbitai

coderabbitai Bot commented Apr 20, 2026

Copy link
Copy Markdown
Contributor
✅ Actions performed

Review triggered.

Note: CodeRabbit is an incremental review system and does not re-review already reviewed commits. This command is applicable only when automatic reviews are paused.

@ooples
ooples merged commit 736da3d into master Apr 21, 2026
29 of 46 checks passed
@ooples
ooples deleted the deps/bump-tensors-openblas-0.50.0 branch April 21, 2026 03:04
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants