### Example obsparam YAML File for pyuvsim Simulation Source: https://github.com/radioastronomysoftwaregroup/pyuvsim/blob/main/docs/parameter_files.rst This YAML file defines core simulation parameters for pyuvsim, including output filing, frequency setup (Nfreqs, channel_width, start_freq, end_freq, freq_array, bandwidth), source catalog details (path, type, spectral_type), telescope configuration (array_layout, telescope_config_name), time parameters (Ntimes, integration_time, start_time, end_time, duration_hours), and baseline selection criteria (bls, ant_str, antenna_nums, redundant_threshold, conjugation_convention, blt_order). It serves as the primary input for `pyuvsim.simsetup.initialize_uvdata_from_params`. ```yaml filing: outdir: '.' #Output file directory outfile_prefix: 'sim' # Prefix for the output file name, separated by underscores outfile_suffix: 'results' # Suffix for output file name outfile_name: 'sim_results' # Alternatively, give the full name output_format: 'uvfits' # Format for output. Default is 'uvh5', but 'uvfits', measurement sets ('ms'), and 'miriad' are also supported. clobber: False # overwrite existing files. (Default False) freq: Nfreqs: 10 # Number of frequencies channel_width: 80000.0 # Frequency channel width end_freq: 100800000.0 # Start and end frequencies (Hz) start_freq: 100000000.0 freq_array : [1.0000e+08, 1.0008e+08, 1.0016e+08, 1.0024e+08, 1.0032e+08, 1.0040e+08, 1.0048e+08, 1.0056e+08, 1.0064e+08, 1.0072e+08] bandwidth: 800000.0 sources: catalog: '../pyuvsim/data/gleam_50srcs.vot' # Path to catalog file (txt, vot, skyh5, fhd, etc.) readable with pyradiosky. filetype : "gleam" # optionally specify the catalog filetype (skyh5, gleam, vot, text, fhd). If not specified, the code attempt to guess the type. spectral_type: flat # If using the GLEAM catalog, specify the spectral type (flat, subband or spectral_index). Defaults to flat. table_name: single # Required for non-GLEAM VO table files id_column: name # Required for non-GLEAM VO table files flux_columns: Si # Required for non-GLEAM VO table files ra_column: RAJ2000 # Recommended for non-GLEAM VO table files dec_column: DEJ2000 # Recommended for non-GLEAM VO table files catalog: 'mock' # Alternatively, use 'mock' to use a builtin catalog). mock_arrangement: 'zenith' # If using the mock catalog, specify which one. Additional mock keywords are specified here. telescope: array_layout: 'triangle_bl_layout.csv' # Antenna layout csv file telescope_config_name: '28m_triangle_10time_10chan.yaml' # Telescope metadata file. time: Ntimes: 10 # Number of times. integration_time: 11.0 # Time step size (seconds) start_time: 2457458.1738949567 # Start and end times (Julian date) end_time: 2457458.175168105 duration_hours: 0.0276 select: # limit which baselines are simulated. Use any UVData.select keywords (except polarizations) and/or redundant_threshold bls: '[(1, 2), (3, 4), (5, 6)]' ant_str: 'cross' antenna_nums: [1, 7, 9, 15] redundant_threshold: 0.1 # redundancy threshold in meters. Only simulate one baseline per redundant group ordering: # specify the baseline-time order and baseling conjugation convention conjugation_convention: ant1 mpiexec -n 1 -np 1 pytest --refsim=1.1_uniform --benchmark-only ``` -------------------------------- ### Running Pytest for pyuvsim Testing (Shell) Source: https://github.com/radioastronomysoftwaregroup/pyuvsim/blob/main/README.md This command executes the `pytest` test suite from the current directory, typically `pyuvsim/`, to verify the installation and functionality of the `pyuvsim` package. It requires `pytest` to be installed and all `pyuvsim` dependencies to be met. ```Shell pytest ``` -------------------------------- ### Installing pyuvsim in Developer Mode with Conda Source: https://github.com/radioastronomysoftwaregroup/pyuvsim/blob/main/benchmarking/README.md Installs the `pyuvsim` repository in 'developer' mode using Conda. This allows for local modifications to be reflected without reinstallation, which is necessary for effective use of the benchmarking tools. ```Bash conda develop . ``` -------------------------------- ### Running pyuvsim with MPI Parallelization (Python) Source: https://github.com/radioastronomysoftwaregroup/pyuvsim/blob/main/docs/usage.rst This command demonstrates how to execute a pyuvsim simulation using MPI for parallel processing. It launches the `run_param_pyuvsim` script with a specified number of MPI processing units and an observation parameter file. This setup enables distributed computation to accelerate simulations, with further speedup from NumPy/SciPy internal threading. ```python # Running with 50 MPI processing units > mpirun -n 50 python run_param_pyuvsim obsparam_filename.yaml # This will run a parameter file job with 10 processing units. ``` -------------------------------- ### Initializing pyuvsim Benchmarking Configuration Source: https://github.com/radioastronomysoftwaregroup/pyuvsim/blob/main/benchmarking/README.md Generates the necessary configuration files and SLURM job script for a `pyuvsim` benchmarking run based on the parameters defined in `settings.yaml`. By default, it creates a dated directory for output. ```Python python run_benchmarking.py settings.yaml --init_config ``` -------------------------------- ### Running pyuvsim Reference Simulations with SLURM (Bash) Source: https://github.com/radioastronomysoftwaregroup/pyuvsim/blob/main/reference_simulations/README.md This Bash command initiates all `pyuvsim` reference simulations by launching SLURM jobs. It takes `obsparam_*` as arguments, which are observation parameter files, and delegates the job execution to `jobscript.sh`. ```bash ./run_ref_sims.sh obsparam_* ``` -------------------------------- ### Running pyuvsim Simulation with MPI Source: https://github.com/radioastronomysoftwaregroup/pyuvsim/blob/main/README.md This command demonstrates how to execute a pyuvsim simulation using `mpirun` for parallel processing. It specifies 4 MPI ranks and points to a YAML configuration file (`obsparam_ref_1.1.yaml`) which defines the simulation parameters, such as observation times, frequencies, and array configuration. ```Shell mpirun -n 4 python scripts/run_param_pyuvsim.py reference_simulations/first_generation/obsparam_ref_1.1.yaml ``` -------------------------------- ### Submitting pyuvsim Benchmarking Job to SLURM Source: https://github.com/radioastronomysoftwaregroup/pyuvsim/blob/main/benchmarking/README.md Submits the `pyuvsim` benchmarking job to the SLURM workload manager. If the configuration files haven't been generated yet, this command will also initialize them before submission. ```Python python run_benchmarking.py settings.yaml --submit ``` -------------------------------- ### Running Pytest via Python Module (Shell) Source: https://github.com/radioastronomysoftwaregroup/pyuvsim/blob/main/README.md This command runs the `pytest` test suite specifically for the `pyuvsim` package by invoking `pytest` as a Python module. It's an alternative to directly running `pytest` and ensures the correct Python environment is used. ```Shell python -m pytest pyuvsim ``` -------------------------------- ### Updating pyuvsim Benchmarking Log File Source: https://github.com/radioastronomysoftwaregroup/pyuvsim/blob/main/benchmarking/README.md Updates the `BENCHMARKS.log` file with the results from the latest `pyuvsim` benchmarking run. This log is tracked by Git and serves as a historical record of performance changes over time. ```Python python run_benchmarking.py settings.yaml --update_log ``` === COMPLETE CONTENT === This response contains all available snippets from this library. No additional content exists. Do not make further requests.