<jupyter_start><jupyter_text>Debug the utilimport lib<jupyter_code>%load_ext autoreload
%autoreload 2
import sys
sys.path.append('../')
import torch
import numpy as np
import lib.models as model
import lib.util as util
from scipy.stats import levy_stable<jupyter_output><empty_output><jupyter_text>Parameters<jupyter_code>m = 3 
n = 4
k = 1000
alpha = 1
beta = 0<jupyter_output><empty_output><jupyter_text>Test Generate A<jupyter_code>A = util.Generate_A(m,n)
A.shape<jupyter_output><empty_output><jupyter_text>Test Generate random variable X<jupyter_code>X = torch.tensor(util.Generate_alpha_random(alpha, beta, shape=(n, k)),dtype=torch.float32)
Y = A.mm(X)
SparsDT = model.ModelSparseDT(10,Y, num_samples=1e6)
type(X)
A.shape
X.shape
X.dtype
Y.shape
Y.norm(dim=0).shape<jupyter_output><empty_output>
{'fraction_non_alphanumeric': 0.12094763092269327, 'fraction_numerical': 0.0199501246882793, 'mean_word_length': 7.824175824175824, 'pattern_counts': {'":': 0, '<': 17, '<?xml version=': 0, '>': 17, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'chain_length': '4', 'dir': 'jupyter-structured-clean-dedup', 'id': '246203', 'license': 'MIT', 'n_tokens_mistral': 331, 'n_tokens_neox': 322, 'n_words': 60, 'path': 'notebooks/Debug - util.ipynb', 'repo_name': 'F-Salehi/SparsDT', 'size': '802'}