# Examples The scripts in the repository's `examples/` folder are complete runs of the instrument. They are shown here, not run when the manual is built: each propagates real beams through a slab, which takes minutes to hours. Run one from a checkout with `uv run python examples/.py`; each prints what it does and accepts `--help`. ## A collection-window series `tgfrog_window_series.py` scans a 1 fs, 260 nm pulse through the boxcar instrument, collecting the transient-grating signal through six aperture diameters at sixteen slab thicknesses, and writes one scan file ({doc}`trace-simulation`). ```{literalinclude} ../examples/tgfrog_window_series.py :language: python ``` ## Certifying the step before a production scan `calibrate_production.py` runs the Richardson step calibration and the invariance battery on the production configuration of the window series ({doc}`accuracy`). ```{literalinclude} ../examples/calibrate_production.py :language: python ``` ## Injecting a pulse from a file `injected_pulse.py` writes a chirped, off-centre Gaussian to a source file, prepares it and runs a smoke scan with it ({doc}`input-pulses`). ```{literalinclude} ../examples/injected_pulse.py :language: python ``` ## The mask-edge study `mask_study.py` reproduces the numbers behind the choice of mask and window edges ({doc}`windows`, {doc}`model`). ```{literalinclude} ../examples/mask_study.py :language: python ``` ## A run file and a Slurm job The same window series as a TOML run file, for the `pnps` command, and a Slurm array job that scans it in shards ({doc}`clusters`). ```{literalinclude} ../examples/runs/window_series.toml :language: toml ``` ```{literalinclude} ../examples/runs/scan.sbatch :language: bash ``` ## A transient-grating separation The FROG2 campaign's common instrument as a separation run file, for `pnps separate` ({doc}`separation`): the `Iω_win*` traces of its file hold the transient-grating field alone, beside the whole nonlinear field's and the remainder's. The same Slurm script runs it with `pnps separate` in place of `pnps scan`, given about 160 GB of host memory per task. ```{literalinclude} ../examples/runs/frog2_tg_separation.toml :language: toml ```