Skip to content

pullrequests Search Results · repo:johnmarktaylor91/torchlens language:Python

Filter by

95 results  (133 ms)

95 results

injohnmarktaylor91/torchlens (press backspace or delete to remove)

Summary Fixes #138 -- log_forward_pass() fails on first call under Python 3.14 with TypeError: unsupported operand type(s) for |: function and types.GenericAlias . Root cause: Python 3.14 (PEP 649) evaluates ...

Summary - Bug: After wrap_torch() (or any log_forward_pass), torch.tensor([0-d_tensor, ...]) raises TypeError: len() of a 0-d tensor. Persists even after unwrap_torch(). - Root cause: Replacing ...

Summary - Add detect-private-key hook (catches PGP, RSA, SSH, EC private keys) - Add detect-secrets (Yelp) hook (catches API keys, tokens, passwords, high-entropy strings) Test plan - [x] Both ...

Summary - Lazy decoration: import torchlens no longer wraps torch functions. Wrapping happens on first log_forward_pass() call and persists afterward. - Public wrap/unwrap API: wrap_torch(), unwrap_torch(), ...

Summary - Break symlink mirroring convention: every subdirectory had AGENTS.md - CLAUDE.md symlinks. Now they are separate files with distinct purposes. - CLAUDE.md = architect-level context (what ...

Summary - Replace timer-based SIGALRM (setitimer with 50ms delay) with direct os.kill() inside the model s forward(), ensuring the signal always fires mid-logging - Eliminates flaky skips when ...

Summary - Root cause: ELK s stress algorithm allocates TWO O(n²) distance matrices (n² × 16 bytes). At 100k nodes = 160 GB, at 1M nodes = 16 TB. The old 150k stress-switch threshold could never ...

Summary - Per-step verbose timing (O16): Unwrap grouped _vtimed blocks into individual step timing with graph-stats summary line and total elapsed time, so users can identify which specific step ...

Summary - Rename ~68 fields across all 8 data structures for clarity and consistency - Key renames: tensor_contents → activation, grad_contents → gradient, all *_fsize* → *_memory*, vis_opt → vis_mode ...

Summary - Updated all 10 CLAUDE.md files across root, torchlens/, and all subpackages to reflect current codebase state - Synced line counts for all 36 source modules (many were stale by 50-200+ lines) ...