Skip to content

save_mtp_tensors_to_checkpoint lazy download - #791

Open
kylesayrs wants to merge 9 commits into
mainfrom
kylesayrs/less-load-mtp-save
Open

save_mtp_tensors_to_checkpoint lazy download#791
kylesayrs wants to merge 9 commits into
mainfrom
kylesayrs/less-load-mtp-save

Conversation

@kylesayrs

Copy link
Copy Markdown
Collaborator

Purpose

  • Reduce runtime when adding tmp tensors to a model when the source model is not downloaded; ie if we want to start a job to add mtp tensors back to already-uploaded models

Changes

  • Allow save_mtp_tensors_to_checkpoint to be used without requiring all source model files to be downloaded; only the required files are downloaded

Testing

  • TODO: more and better tests, tested locally

Signed-off-by: Kyle Sayers <kylesayrs@gmail.com>
Signed-off-by: Kyle Sayers <kylesayrs@gmail.com>
Signed-off-by: Kyle Sayers <kylesayrs@gmail.com>
Signed-off-by: Kyle Sayers <kylesayrs@gmail.com>
Signed-off-by: Kyle Sayers <kylesayrs@gmail.com>
Signed-off-by: Kyle Sayers <kylesayrs@gmail.com>
@coderabbitai

coderabbitai Bot commented Jul 24, 2026

Copy link
Copy Markdown
Contributor

Important

Review skipped

Auto reviews are disabled on this repository. Please check the settings in the CodeRabbit UI or the .coderabbit.yaml file in this repository. To trigger a single review, invoke the @coderabbitai review command.

⚙️ Run configuration

Configuration used: Path: .coderabbit.yaml

Review profile: CHILL

Plan: Team

Run ID: 023bc5c8-d48e-428b-bf7b-854e1a2bb744

You can disable this status message by setting the reviews.review_status to false in the CodeRabbit configuration file.

Use the checkbox below for a quick retry:

  • 🔍 Trigger review
✨ Finishing Touches
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Commit unit tests in branch kylesayrs/less-load-mtp-save

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

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

Base automatically changed from kylesayrs/looser-mtp-save to main July 27, 2026 14:41
@mergify

mergify Bot commented Jul 27, 2026

Copy link
Copy Markdown

This pull request has merge conflicts that must be resolved before it can be
merged. Please rebase the PR, @kylesayrs.

https://docs.github.com/en/pull-requests/collaborating-with-pull-requests/working-with-forks/syncing-a-fork

@mergify mergify Bot added the needs-rebase label Jul 27, 2026
@kylesayrs

Copy link
Copy Markdown
Collaborator Author

@coderabbitai fix merge conflict

@coderabbitai

coderabbitai Bot commented Jul 29, 2026

Copy link
Copy Markdown
Contributor

Merge conflicts resolved successfully!

Resolved 1 conflict file(s). Commit: f4d850b1cb522afe73a32c201ab2ff0e64caf36a pushed to kylesayrs/less-load-mtp-save.

2 file operation(s)
  • src/compressed_tensors/utils/mtp.py (update)
  • src/compressed_tensors/utils/safetensors_load.py (update)
View agent analysis

Resolved conflicts in:
- src/compressed_tensors/utils/mtp.py (content)

Co-authored-by: CodeRabbit <noreply@coderabbit.ai>
@mergify mergify Bot removed the needs-rebase label Jul 29, 2026
@mergify

mergify Bot commented Aug 17, 2026

Copy link
Copy Markdown

Merge Protections

🔴 1 of 1 protections blocking · waiting on 👀 reviews

Protection Waiting on
🔴 Require one maintainer review 👀 reviews

🔴 Require one maintainer review

Waiting for any of

  • approved-reviews-by=HDCharles
  • approved-reviews-by=brian-dellabetta
  • approved-reviews-by=dsikka
  • approved-reviews-by=kylesayrs
This rule is failing.

All PRs must have at least one approving review from a maintainer before merging.

  • any of:
    • approved-reviews-by=HDCharles
    • approved-reviews-by=brian-dellabetta
    • approved-reviews-by=dsikka
    • approved-reviews-by=kylesayrs
  • #changes-requested-reviews-by = 0

kylesayrs and others added 2 commits September 3, 2026 19:56
Align test_save_mtp_tensors with the incremental index update logic:
total_size/total_parameters are now derived from tensor byte/element
counts, and an empty destination synthesises a fresh index instead of
raising.

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
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.

1 participant