This repository contains the implementation and reproducibility materials for the paper:
Physics-Informed XNet: A Cauchy Activation-Based Neural Architecture for Seismic Ray Tracing under Multiple Initial Conditions
The authors are Rosélia N. da Silva, Lucas T. Marques, Luiz Affonso Guedes and Tiago Barros, from the Department of Computer Engineering and Automation at the Federal University of Rio Grande do Norte (UFRN), Brazil.
The proposed Physics-Informed XNet (PIXNet) is a neural surrogate for seismic ray tracing in heterogeneous velocity models. It predicts the ray state
The article PDF is intentionally not included in this repository.
PIXNet combines:
- XNet with four hidden layers of 64 neurons and trainable Cauchy activation functions;
- a data loss based on mean squared error;
- a physics loss based on the Hamiltonian ray-tracing equations and automatic differentiation;
- density-based spatial weights that increase the contribution of sparsely sampled regions;
- second-order Runge–Kutta (RK2) ray tracing to generate reference data.
The experiments use the Marmousi velocity model. A two-dimensional B-spline filter smooths the velocity field before ray tracing. The paper evaluates subsampling factors 20, 25, 30, 35 and 40, and uses factor 30 for the main model because it balances predictive accuracy and geological detail. Data are split by complete ray trajectory into training, validation and test partitions to avoid leakage between points from the same ray.
The evaluation reports
data/
├── marmousi_vp.bin # Raw Marmousi velocity model
└── splits/ # Generated ray-level data partitions
output/
├── checkpoints/ # Saved PIXNet and MLP checkpoints
├── figures/ # Static figures generated by notebooks
├── interactive/ # Interactive Plotly HTML outputs
└── tables/ # CSV/LaTeX metrics and tables
src/
├── marmousi_xnet.ipynb # Main PIXNet experiment
├── marmousi_xnet_mlp_comparison.ipynb
├── marmousi_xnet_test_smooth_factor.ipynb
├── rt_python/ # RK2 ray tracing and B-spline routines
└── utils/ # XNet, training, preprocessing and metrics
Large generated datasets, checkpoints and interactive plots are excluded from version control. Static figures and selected tables can be committed for publication or archived as supplementary material.
The experiments use Python 3.10 and PyTorch. Create the environment with:
conda env create -f conda.yaml
conda activate xnet-ray-tracingThe Marmousi velocity model must be available at data/marmousi_vp.bin. If it is not included in a distribution of this repository, download it from The Marmousi Experience and place it at that path.
Launch Jupyter from either the repository root or src/:
jupyter labRun the notebooks in this order:
marmousi_xnet.ipynbtrains and evaluates the main PIXNet model.marmousi_xnet_mlp_comparison.ipynbcompares PIXNet with a matched MLP baseline.marmousi_xnet_test_smooth_factor.ipynbevaluates the smoothing-factor experiment.
The notebooks resolve the project root automatically, so imports and outputs do not depend on the directory from which Jupyter was launched. They save generated artifacts to data/splits/ and output/.
src/utils/xnet_model.pyimplements XNet and the parameterized Cauchy activation.src/utils/architecture_xnet.pyimplements PIXNet training, physics-informed loss integration, automatic differentiation, checkpointing and prediction.src/utils/architecture_mlp.pyimplements the MLP comparison baseline.src/rt_python/ray_tracing.pygenerates reference trajectories from the Marmousi model.src/rt_python/adjointlib.pycontains the B-spline interpolation and ray-tracing numerical routines.