Skip to content

Commit 66c5d67

Browse files
authored
fix: rust doc.rs docstring build (#5)
### Summary when building to doc.rs it seems to be unable to find the docs/katex.html, so I moved it within the bintensors directory. ``` ... [INFO] [stderr] warning: target filter specified, but no targets matched; this is a no-op [INFO] [stderr] Documenting bintensors v0.0.1-alpha.2 (/opt/rustwide/workdir) [INFO] [stderr] error: error reading `../docs/katex.html`: No such file or directory (os error 2) ... ```
2 parents cfe16e2 + 9058437 commit 66c5d67

File tree

5 files changed

+6
-18
lines changed

5 files changed

+6
-18
lines changed

binding/python/pyproject.toml

Lines changed: 1 addition & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -27,19 +27,7 @@ authors = [
2727
{name = 'Luca Vivona', email = "lucavivona01@gmail.com"}
2828
]
2929
readme = {file = "README.md", content-type = "text/markdown"}
30-
description = """
31-
bintensors is a high-performance binary tensor serialization
32-
format designed to be faster than safetensors by eliminating
33-
JSON metadata overhead. Instead of using JSON for metadata storage,
34-
bintensors employs a compact binary header, reducing parsing time and improving I/O efficiency.
35-
The format begins with an 8-byte unsigned integer (u64), indicating the size of the binary header.
36-
This header contains essential tensor metadata, including the data type (dtype),
37-
the shape of the tensor stored as a length-prefixed list,
38-
and data offsets specifying where each tensor's raw values are stored within the file.
39-
An index map is also included for named tensor lookups. With its efficient structure,
40-
bintensors provides a fast and lightweight alternative for serializing and deserializing large models,
41-
making it ideal for machine learning, scientific computing, and other high-performance applications.
42-
"""
30+
description = "bintensors is a high-performance binary tensor serialization format designed to be faster than safetensors by eliminating JSON metadata overhead."
4331
[project.optional-dependencies]
4432
numpy = ["numpy>=1.21.6"]
4533
torch = [

bintensors/Cargo.toml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
[package]
22
name = "bintensors"
3-
version = "0.0.1-alpha.2"
3+
version = "0.0.1-alpha.3"
44
edition = "2024"
55
license = "MIT"
66
rust-version = "1.85"
@@ -51,4 +51,4 @@ name = "benchmark"
5151
harness = false
5252

5353
[package.metadata.docs.rs]
54-
rustdoc-args = ["--html-in-header", "../docs/katex.html"]
54+
rustdoc-args = ["--html-in-header", "./docs/katex.html"]
File renamed without changes.

bintensors/src/lib.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
#![deny(missing_docs)]
22
#![doc(
3-
html_logo_url = "https://github.com/GnosisFoundation/bintensors/blob/master/.github/assets/bintensors-logo.png"
3+
html_logo_url = "https://github.com/GnosisFoundation/bintensors/blob/master/.github/assets/bintensors-logo.png?raw=true"
44
)]
55
#![doc = include_str!("../DOC_README.md")]
66
#![cfg_attr(not(feature = "std"), no_std)]

makefile

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,8 @@
11
# Define variables
22
ROOT_DIR := $(shell pwd)
3-
TARGET_DIR := $(ROOT_DIR)/../docs
4-
KATEX_HEADER := $(ROOT_DIR)/docs/katex.html
53
DOCS_DIR := $(ROOT_DIR)/bintensors
4+
TARGET_DIR := $(DOCS_DIR)/docs
5+
KATEX_HEADER := $(DOCS_DIR)/docs/katex.html
66

77
# Ensure the target directory exists
88
$(TARGET_DIR):

0 commit comments

Comments
 (0)