NEOPAX._orchestrator

NEOPAX main orchestrator: TOML-driven workflow dispatch for ambipolarity, transport, and direct flux evaluation.

Classes

Models

RuntimeContext

Functions

load_config(path)

_normalized_general_device(→ str)

_execution_device_context(config)

_as_string_list(value)

_load_python_extension_file(→ None)

_load_user_extensions(→ None)

_normalize_solver_config(→ dict)

_state_num_elements(→ int)

_apply_transport_solver_memory_heuristics(→ dict)

Keep solver config on the supported Diffrax-only path.

_build_species(→ NEOPAX._species.Species)

_build_energy_grid(config)

_build_geometry(config)

_build_database(config, geometry)

_build_state(config, geometry, species)

_apply_configured_er_dirichlet_boundaries(config, state)

_resolve_er_right_boundary_mode(→ str)

_normalized_boundary_cfg_for_transport(→ dict)

_apply_boundary_corrected_state_for_ambipolarity(...)

_maybe_initialize_er_from_ambipolarity(config, ...)

_build_flux_model(config, species, energy_grid, ...[, ...])

build_runtime_context(→ tuple[RuntimeContext, ...)

run_transport(config, runtime, state)

run_ambipolarity(config, runtime, state)

calculate_fluxes_from_config(state, config, params[, ...])

Config-driven entrypoint for direct flux calculation (no root-finding).

_resolve_reference_path(path_value)

_load_ntss_reference_profiles(path_value, rho)

calculate_sources_from_config(state, config, params[, ...])

plot_fluxes(rho, fluxes, output_dir[, species, ...])

plot_sources(rho, sources, output_dir)

write_fluxes_hdf5(rho, fluxes, output_dir)

write_sources_hdf5(rho, sources, output_dir)

plot_transport_solution(rho, solution, output_dir[, ...])

write_transport_hdf5(rho, solution, output_dir[, ...])

write_transport_ambipolarity_residual_comparison(...)

write_transport_ambipolarity_residual_scan(state, ...)

run_config(config)

run_config_path(config_path)

main(config_path)

Module Contents

class NEOPAX._orchestrator.Models
flux: object = None
source: object = None
class NEOPAX._orchestrator.RuntimeContext
species: NEOPAX._species.Species
energy_grid: object
geometry: object | None
database: object | None
solver_parameters: dict
models: Models
NEOPAX._orchestrator.load_config(path)
NEOPAX._orchestrator._normalized_general_device(config: dict) str
NEOPAX._orchestrator._execution_device_context(config: dict)
NEOPAX._orchestrator._as_string_list(value)
NEOPAX._orchestrator._load_python_extension_file(path: pathlib.Path) None
NEOPAX._orchestrator._load_user_extensions(config: dict) None
NEOPAX._orchestrator._normalize_solver_config(config: dict) dict
NEOPAX._orchestrator._state_num_elements(state: NEOPAX._state.TransportState | None) int
NEOPAX._orchestrator._apply_transport_solver_memory_heuristics(solver_cfg: dict, state: NEOPAX._state.TransportState, n_equations: int) dict

Keep solver config on the supported Diffrax-only path.

NEOPAX._orchestrator._build_species(config: dict) NEOPAX._species.Species
NEOPAX._orchestrator._build_energy_grid(config: dict)
NEOPAX._orchestrator._build_geometry(config: dict)
NEOPAX._orchestrator._build_database(config: dict, geometry)
NEOPAX._orchestrator._build_state(config: dict, geometry, species: NEOPAX._species.Species)
NEOPAX._orchestrator._apply_configured_er_dirichlet_boundaries(config: dict, state: NEOPAX._state.TransportState | None)
NEOPAX._orchestrator._resolve_er_right_boundary_mode(config: dict, solver_cfg: dict) str
NEOPAX._orchestrator._normalized_boundary_cfg_for_transport(boundary_cfg: dict) dict
NEOPAX._orchestrator._apply_boundary_corrected_state_for_ambipolarity(config: dict, runtime: RuntimeContext, state: NEOPAX._state.TransportState | None)
NEOPAX._orchestrator._maybe_initialize_er_from_ambipolarity(config: dict, runtime: RuntimeContext, state: NEOPAX._state.TransportState | None)
NEOPAX._orchestrator._build_flux_model(config: dict, species, energy_grid, geometry, database, source_models=None)
NEOPAX._orchestrator.build_runtime_context(config: dict) tuple[RuntimeContext, NEOPAX._state.TransportState | None]
NEOPAX._orchestrator.run_transport(config: dict, runtime: RuntimeContext, state: NEOPAX._state.TransportState)
NEOPAX._orchestrator.run_ambipolarity(config: dict, runtime: RuntimeContext, state: NEOPAX._state.TransportState)
NEOPAX._orchestrator.calculate_fluxes_from_config(state, config, params, flux_model=None)

Config-driven entrypoint for direct flux calculation (no root-finding). Returns (fluxes, do_plot, do_hdf5, output_dir, overlay_reference, reference_file, reference_label)

NEOPAX._orchestrator._resolve_reference_path(path_value)
NEOPAX._orchestrator._load_ntss_reference_profiles(path_value, rho)
NEOPAX._orchestrator.calculate_sources_from_config(state, config, params, source_models=None)
NEOPAX._orchestrator.plot_fluxes(rho, fluxes, output_dir, species=None, overlay_reference=False, reference_file=None, reference_label='reference')
NEOPAX._orchestrator.plot_sources(rho, sources, output_dir)
NEOPAX._orchestrator.write_fluxes_hdf5(rho, fluxes, output_dir)
NEOPAX._orchestrator.write_sources_hdf5(rho, sources, output_dir)
NEOPAX._orchestrator.plot_transport_solution(rho, solution, output_dir, n_times=1, reference_er_file=None, overlay_reference_er=False, reference_profile_file=None, initial_reference_file=None, final_reference_file=None, initial_reference_label='Initial ref', final_reference_label='Final ref', source_models=None, species=None, flux_model=None, geometry=None)
NEOPAX._orchestrator.write_transport_hdf5(rho, solution, output_dir, geometry=None, species=None, source_models=None)
NEOPAX._orchestrator.write_transport_ambipolarity_residual_comparison(state, runtime, transport_equations, config, output_dir)
NEOPAX._orchestrator.write_transport_ambipolarity_residual_scan(state, runtime, transport_equations, config, output_dir)
NEOPAX._orchestrator.run_config(config: dict)
NEOPAX._orchestrator.run_config_path(config_path)
NEOPAX._orchestrator.main(config_path)