File size: 301 Bytes
28f4123 a03c99b 28f4123 a03c99b 28f4123 a03c99b 28f4123 | 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 | import numpy as np
MODEL_FILE = "sp_tn_1p.npz"
model = np.load(MODEL_FILE, allow_pickle=True)
w = model["w"]
vocab = model["vocab"]
print("SpTn-Model-only-1P")
print("Trainable parameters: 1")
print("Parameter:", float(w))
print("Vocabulary size:", len(vocab))
print("Model loaded successfully.")
|