Open
Conversation
…-only download Data (download_AK_only_data): • Window length: 5–10s → 60s (captures full P-wave arrival and decay) • P-wave alignment: human-validated times via libcomcat (ComCat API) • Noise: separate quiet-period download (60s, ≥2h from any event), no pre-P segments • Output: same .npy/.csv layout; metadata includes p_arrival_source, window_type Training (train_cnn_multiclass): • Augmentation (train only): 2% noise, ±0.25s shift, ±10% amplitude • Regularization: ReduceLROnPlateau (patience 4), early stop (patience 10), grad clip 2.0, dropout 0.4, weight_decay 1e-3 • Class weights for imbalance; 80/10/10 stratified split • Val acc ~94–95% (train ~91%) vs ~86–87% val with prior short-window data Fixes: • Labels: support [0,2] from data, remap to [0,1]; class_name_map for display • Conv1d input: ensure [batch, channels, length] (squeeze/unsqueeze in AugmentedDataset) • Defs: num_classes, batch_size, DataAugmentation in correct cells; Remove ReduceLROnPlateau verbose • Small-test warning when test set < 100 samples Co-authored-by: Cursor <cursoragent@cursor.com>
Co-authored-by: Cursor <cursoragent@cursor.com>
Made-with: Cursor
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Data (download_AK_only_data):
• Window length: 5–10s → 60s (captures full P-wave arrival and decay)
• P-wave alignment: human-validated times via libcomcat (ComCat API)
• Noise: separate quiet-period download (60s, ≥2h from any event), no pre-P segments
• Output: same .npy/.csv layout; metadata includes p_arrival_source, window_type
Training (train_cnn_multiclass):
• Augmentation (train only): 2% noise, ±0.25s shift, ±10% amplitude
• Regularization: ReduceLROnPlateau (patience 4), early stop (patience 10), grad clip 2.0, dropout 0.4, weight_decay 1e-3
• Class weights for imbalance; 80/10/10 stratified split
• Val acc ~94–95% (train ~91%) vs ~86–87% val with prior short-window data
Fixes:
• Labels: support [0,2] from data, remap to [0,1]; class_name_map for display
• Conv1d input: ensure [batch, channels, length] (squeeze/unsqueeze in AugmentedDataset)
• Defs: num_classes, batch_size, DataAugmentation in correct cells; Remove ReduceLROnPlateau verbose