###One Person Per Project
While discussion among students about model design is allowed, each Kaggle contest submission must reflect your own effort and results, and no two students should submit identical work. Your final paper should also be your own work.

###Submission Timelines
Once you have a trained model you're satisfied with, you can generate predictions on the provided test data and submit them to the Kaggle contest platform. You can upload and update your ML model prediction at anytime and multiple times (up to 10 times a day). The leaderboard will display your prediction score compared to the ground truth of the test data. **You must submit your model prediction before our last lecture on 6/3, so that we can announce the first few winners as of 6/3. After that you will still have time to improve and upload/update new model predictions and thus alter the contest result until final paper due date (6/12).**

###No Additional Data
You can only use the data provided in this project. External datasets are not allowed.

###No Pretrained Models
Models must be trained from scratch. Using any pretrained weights or architectures trained on external data is not permitted.

###Post-Processing Restrictions
You can not manually change the ML predictions. Only minimal post-processing of the prediction is allowed. You may clean your predictions by removing invalid values (e.g., NaN, Inf, -Inf), but additional filtering or smoothing operations are not permitted.

###Training Data Considerations
The first 12 time frames of each simulation capture the initial wavefield build-up from the earthquake source. The remaining times in the simulation do not contain the source.

If you're using an ML auto-regressive model (like in the baseline), taking a single previous time frame and predicting the next, you should consider excluding the first 12 time frames to avoid implicit source injection effects, as the "physics" in the between the first 12 time frames and the time frames afterwards are different.

If you're using an end-to-end ML model that takes all 15 input time frames and predicts all 45 future time frames in one shot, including the first 12 time frames may still be beneficial, as the ML may learn how to map the initial time period with the source to the later time period without the source.

### Submission Guidelines
It is tricky to submit your final results here, as Kaggle only accepts .csv files for submission. Your submission should be a single CSV file (wavefield_predictions.csv) containing predicted wavefields for all 100 test samples, each with 45 future time framesfs on a 64 × 128 spatial grid and 2 channels (vx, vz). 
##### Dimensions
Each sample has: 45 time frames × 64 × 128 spatial grid × 2 channels = 737,280 predicted values
Final submission shape: 737,280 rows × 101 columns
The CSV should follow this structure:
| ID     | 0   | 1   | 2   | ... | 98  | 99  |
| ------ | --- | --- | --- | --- | --- | --- |
| 0      | v   | v   | v   | ... | v   | v   |
| 1      | v   | v   | v   | ... | v   | v   |
| ...    | ... | ... | ... |     | ... | ... |
| 737279 | v   | v   | v   | ... | v   | v   |

The ID column (0 to 737279) is required and must be the first column. Each subsequent column (0–99) represents predictions for the corresponding test sample. Each column must contain the flattened output of shape (45, 64, 128, 2) → flattened in C-order (default NumPy .reshape(-1)):

Column 1 is prediction for 0.npy
Column 2 for 1.npy
...
Column 100 for 99.npy

We highly recommend you use the code below to structure your submission. 

<pre> ```
python import numpy as np 
import pandas as pd 
wavefield_data = ***YOUR PREDICTION, FILL THIS IN***  # prediction, 45 frames for all 100 samples: shape (100, 45, 64, 128, 2) 
wavefield_data = wavefield_data.astype('float32') 
flattened = wavefield_data.reshape(100, -1) # Flatten each sample: (100, 737280) 
submission = pd.DataFrame(flattened).T # Transpose so each column is one sample → (737280, 100) 
submission.insert(0, 'ID', np.arange(737280)) # Add ID column 
submission.to_csv("wavefield_predictions.csv", index=False) # Save to CSV 
``` </pre>
