Skip to content

Update code formatting with JuliaFormatter #1305

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 1 commit into from
Jul 31, 2025
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
7 changes: 4 additions & 3 deletions docs/make.jl
Original file line number Diff line number Diff line change
Expand Up @@ -39,9 +39,10 @@ makedocs(sitename = "Catalyst.jl",
collapselevel = 1,
assets = ["assets/favicon.ico"],
canonical = "https://docs.sciml.ai/Catalyst/stable/"),
modules = [Catalyst, ModelingToolkit,
isdefined(Base, :get_extension) ? Base.get_extension(Catalyst, :CatalystGraphMakieExtension) :
Catalyst.CatalystGraphMakieExtension],
modules = [Catalyst, ModelingToolkit,
isdefined(Base, :get_extension) ?
Base.get_extension(Catalyst, :CatalystGraphMakieExtension) :
Catalyst.CatalystGraphMakieExtension],
doctest = false,
clean = true,
pages = pages,
Expand Down
159 changes: 78 additions & 81 deletions docs/pages.jl
Original file line number Diff line number Diff line change
@@ -1,83 +1,80 @@
pages = Any[
"Home" => "index.md",
"Introduction to Catalyst" => Any[
"introduction_to_catalyst/catalyst_for_new_julia_users.md",
"introduction_to_catalyst/introduction_to_catalyst.md",
"introduction_to_catalyst/math_models_intro.md"
],
"Model creation and properties" => Any[
"model_creation/dsl_basics.md",
"model_creation/dsl_advanced.md",
"model_creation/programmatic_CRN_construction.md",
"model_creation/compositional_modeling.md",
"model_creation/constraint_equations.md",
"model_creation/conservation_laws.md",
"model_creation/parametric_stoichiometry.md",
"model_creation/functional_parameters.md",
"model_creation/model_file_loading_and_export.md",
"model_creation/model_visualisation.md",
"model_creation/reactionsystem_content_accessing.md",
"model_creation/chemistry_related_functionality.md",
"Examples" => Any[
"model_creation/examples/basic_CRN_library.md",
"model_creation/examples/programmatic_generative_linear_pathway.md",
"model_creation/examples/hodgkin_huxley_equation.md",
"model_creation/examples/smoluchowski_coagulation_equation.md",
"model_creation/examples/noise_modelling_approaches.md",
]
],
"Model simulation and visualization" => Any[
"model_simulation/simulation_introduction.md",
"model_simulation/simulation_plotting.md",
"model_simulation/simulation_structure_interfacing.md",
"model_simulation/ensemble_simulations.md",
"model_simulation/ode_simulation_performance.md",
"model_simulation/sde_simulation_performance.md",
"model_simulation/finite_state_projection_simulation.md",
"Examples" => Any[
"model_simulation/examples/periodic_events_simulation.md",
"model_simulation/examples/activation_time_distribution_measurement.md",
"model_simulation/examples/interactive_brusselator_simulation.md"
]
],
"Network Analysis" => Any[
"network_analysis/odes.md",
"network_analysis/crn_theory.md",
"network_analysis/network_properties.md"
],
"Steady state analysis" => Any[
"steady_state_functionality/homotopy_continuation.md",
"steady_state_functionality/nonlinear_solve.md",
"steady_state_functionality/steady_state_stability_computation.md",
"steady_state_functionality/bifurcation_diagrams.md",
"steady_state_functionality/dynamical_systems.md",
"Examples" => Any[
"steady_state_functionality/examples/nullcline_plotting.md",
"steady_state_functionality/examples/bifurcationkit_periodic_orbits.md",
"steady_state_functionality/examples/bifurcationkit_codim2.md"
]
],
"Inverse problems" => Any[
"inverse_problems/petab_ode_param_fitting.md",
"inverse_problems/optimization_ode_param_fitting.md",
"inverse_problems/behaviour_optimisation.md",
"inverse_problems/structural_identifiability.md",
"inverse_problems/global_sensitivity_analysis.md",
#"Examples" => Any[
# "inverse_problems/examples/ode_fitting_oscillation.md"
#]
],
"Spatial modelling" => Any[
"spatial_modelling/lattice_reaction_systems.md",
"spatial_modelling/lattice_simulation_structure_ interaction.md",
"spatial_modelling/lattice_simulation_plotting.md",
"spatial_modelling/spatial_ode_simulations.md",
"spatial_modelling/spatial_jump_simulations.md"
],
"FAQs" => "faqs.md",
"API" => Any[
"api/core_api.md",
"api/network_analysis_api.md"
],
"Developer Documentation" => "devdocs/dev_guide.md"
"Home" => "index.md",
"Introduction to Catalyst" => Any[
"introduction_to_catalyst/catalyst_for_new_julia_users.md",
"introduction_to_catalyst/introduction_to_catalyst.md",
"introduction_to_catalyst/math_models_intro.md"
],
"Model creation and properties" => Any[
"model_creation/dsl_basics.md",
"model_creation/dsl_advanced.md",
"model_creation/programmatic_CRN_construction.md",
"model_creation/compositional_modeling.md",
"model_creation/constraint_equations.md",
"model_creation/conservation_laws.md",
"model_creation/parametric_stoichiometry.md",
"model_creation/functional_parameters.md",
"model_creation/model_file_loading_and_export.md",
"model_creation/model_visualisation.md",
"model_creation/reactionsystem_content_accessing.md",
"model_creation/chemistry_related_functionality.md",
"Examples" => Any[
"model_creation/examples/basic_CRN_library.md",
"model_creation/examples/programmatic_generative_linear_pathway.md",
"model_creation/examples/hodgkin_huxley_equation.md",
"model_creation/examples/smoluchowski_coagulation_equation.md",
"model_creation/examples/noise_modelling_approaches.md"
]
],
"Model simulation and visualization" => Any[
"model_simulation/simulation_introduction.md",
"model_simulation/simulation_plotting.md",
"model_simulation/simulation_structure_interfacing.md",
"model_simulation/ensemble_simulations.md",
"model_simulation/ode_simulation_performance.md",
"model_simulation/sde_simulation_performance.md",
"model_simulation/finite_state_projection_simulation.md",
"Examples" => Any[
"model_simulation/examples/periodic_events_simulation.md",
"model_simulation/examples/activation_time_distribution_measurement.md",
"model_simulation/examples/interactive_brusselator_simulation.md"
]
],
"Network Analysis" => Any[
"network_analysis/odes.md",
"network_analysis/crn_theory.md",
"network_analysis/network_properties.md"
],
"Steady state analysis" => Any[
"steady_state_functionality/homotopy_continuation.md",
"steady_state_functionality/nonlinear_solve.md",
"steady_state_functionality/steady_state_stability_computation.md",
"steady_state_functionality/bifurcation_diagrams.md",
"steady_state_functionality/dynamical_systems.md",
"Examples" => Any[
"steady_state_functionality/examples/nullcline_plotting.md",
"steady_state_functionality/examples/bifurcationkit_periodic_orbits.md",
"steady_state_functionality/examples/bifurcationkit_codim2.md"
]
],
"Inverse problems" => Any[
"inverse_problems/petab_ode_param_fitting.md",
"inverse_problems/optimization_ode_param_fitting.md",
"inverse_problems/behaviour_optimisation.md",
"inverse_problems/structural_identifiability.md",
"inverse_problems/global_sensitivity_analysis.md" #"Examples" => Any[ # "inverse_problems/examples/ode_fitting_oscillation.md" #]
],
"Spatial modelling" => Any[
"spatial_modelling/lattice_reaction_systems.md",
"spatial_modelling/lattice_simulation_structure_ interaction.md",
"spatial_modelling/lattice_simulation_plotting.md",
"spatial_modelling/spatial_ode_simulations.md",
"spatial_modelling/spatial_jump_simulations.md"
],
"FAQs" => "faqs.md",
"API" => Any[
"api/core_api.md",
"api/network_analysis_api.md"
],
"Developer Documentation" => "devdocs/dev_guide.md"
]
Original file line number Diff line number Diff line change
Expand Up @@ -37,6 +37,7 @@ function bkext_make_nsys(rs, u0)
cons_default = [cons_eq.rhs for cons_eq in cons_eqs]
cons_default = Catalyst.get_networkproperties(rs).conservedconst => cons_default
defaults = Dict([u0; cons_default])
nsys = convert(NonlinearSystem, rs; defaults, remove_conserved = true, conseqs_remake_warn = false)
nsys = convert(
NonlinearSystem, rs; defaults, remove_conserved = true, conseqs_remake_warn = false)
return complete(nsys)
end
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,8 @@ function lattice_animation(
vals, plot_min, plot_max = Catalyst.extract_vals(sol, sp, lrs, plot_min, plot_max, t)

# Creates the base figure (which is modified in the animation).
fig, ax, plt = scatterlines(vals[1];
fig, ax,
plt = scatterlines(vals[1];
axis = (xlabel = "Compartment", ylabel = "$(sp)",
limits = (nothing, nothing, plot_min, plot_max)),
markersize = markersize, kwargs...)
Expand Down Expand Up @@ -100,8 +101,10 @@ function lattice_animation(
x_vals, y_vals = Catalyst.extract_grid_axes(lrs)

# Creates the base figure (which is modified in the animation).
fig, ax, hm = heatmap(x_vals, y_vals, vals[1];
axis = (xgridvisible = false, ygridvisible = false, xlabel = "Compartment", ylabel = "Compartment"),
fig, ax,
hm = heatmap(x_vals, y_vals, vals[1];
axis = (xgridvisible = false, ygridvisible = false,
xlabel = "Compartment", ylabel = "Compartment"),
Comment on lines -103 to +107
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Things likes this are not a reasonable reformat, and are why Catalyst no longer uses JuliaFormatter. Please revert this PR. Is this even correct syntactically now?

colormap, colorrange = (plot_min, plot_max),
kwargs...)
ttitle && (ax.title = "Time: $(round(t[1]; sigdigits = 3))")
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,8 @@ function lattice_animation(
vals, plot_min, plot_max = Catalyst.extract_vals(sol, sp, lrs, plot_min, plot_max, t)

# Creates the base figure (which is modified in the animation).
fig, ax, plt = graphplot(plot_graph; node_color = vals[1],
fig, ax,
plt = graphplot(plot_graph; node_color = vals[1],
node_attr = (colorrange = (plot_min, plot_max), colormap), node_size, kwargs...
)
ttitle && (ax.title = "Time: $(round(t[1]; sigdigits = 3))")
Expand Down
Loading
Loading