Skip to content

Instantly share code, notes, and snippets.

@pashu123
Created April 24, 2025 01:02
Show Gist options
  • Save pashu123/c691bb3350415a80c117cb8d95a58f97 to your computer and use it in GitHub Desktop.
Save pashu123/c691bb3350415a80c117cb8d95a58f97 to your computer and use it in GitHub Desktop.
import numpy as np
import os
np.random.seed(0)
# Tensor shapes
shapes = {
"arg0": (2816, 2),
"arg1": (1280, 2816),
}
# Generate and save tensors
for name, shape in shapes.items():
tensor = np.random.uniform(low=0.0, high=1.0, size=shape).astype(np.float16)
np.save(f"{name}.npy", tensor)
print(f"Saved {name}.npy with shape {shape}")
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment