[PR #11507] [MERGED] convert: skip reading into memory when possible #60256

Closed
opened 2026-04-29 15:10:17 -05:00 by GiteaMirror · 0 comments
Owner

📋 Pull Request Information

Original PR: https://github.com/ollama/ollama/pull/11507
Author: @mxyng
Created: 7/23/2025
Status: Merged
Merged: 8/14/2025
Merged by: @mxyng

Base: mainHead: mxyng/convert


📝 Commits (1)

  • f1ae74a convert: skip reading into memory when possible

📊 Changes

2 files changed (+258 additions, -13 deletions)

View changed files

📝 convert/reader_safetensors.go (+26 -13)
convert/reader_test.go (+232 -0)

📄 Description

if there's no transformation to the tensor and the input and output types match, copy directly into the writer. also read from a bufio with a 32K buffer


🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.

## 📋 Pull Request Information **Original PR:** https://github.com/ollama/ollama/pull/11507 **Author:** [@mxyng](https://github.com/mxyng) **Created:** 7/23/2025 **Status:** ✅ Merged **Merged:** 8/14/2025 **Merged by:** [@mxyng](https://github.com/mxyng) **Base:** `main` ← **Head:** `mxyng/convert` --- ### 📝 Commits (1) - [`f1ae74a`](https://github.com/ollama/ollama/commit/f1ae74aaf7129181ee250b3b947122033eac6d19) convert: skip reading into memory when possible ### 📊 Changes **2 files changed** (+258 additions, -13 deletions) <details> <summary>View changed files</summary> 📝 `convert/reader_safetensors.go` (+26 -13) ➕ `convert/reader_test.go` (+232 -0) </details> ### 📄 Description if there's no transformation to the tensor and the input and output types match, copy directly into the writer. also read from a bufio with a 32K buffer --- <sub>🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.</sub>
GiteaMirror added the pull-request label 2026-04-29 15:10:17 -05:00
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: github-starred/ollama#60256