Skip to content
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

Vitepress based documentation #1061

Open
wants to merge 3 commits into
base: master
Choose a base branch
from
Open
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
6 changes: 5 additions & 1 deletion .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -5,4 +5,8 @@
Manifest.toml
/docs/build/
test/Manifest.toml
test/gpu/Manifest.toml
test/gpu/Manifest.toml
node_modules
package-lock.json
docs/src/assets/Manifest.toml
docs/src/assets/Project.toml
1 change: 1 addition & 0 deletions docs/Project.toml
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,7 @@ DiffEqCallbacks = "459566f4-90b8-5000-8ac3-15dfb0a30def"
DiffEqNoiseProcess = "77a26b50-5914-5dd7-bc55-306e6241c503"
DifferentialEquations = "0c46a032-eb83-5123-abaf-570d42b7fbaa"
Documenter = "e30172f5-a6a5-5a46-863b-614d45cd2de4"
DocumenterVitepress = "4710194d-e776-4893-9690-8d956a29c365"
Enzyme = "7da242da-08ed-463a-9acd-ee780be4f1d9"
Flux = "587475ba-b771-5e3f-ad9e-33799f191a9c"
ForwardDiff = "f6369f11-7733-5829-9624-2563aa707210"
Expand Down
17 changes: 14 additions & 3 deletions docs/make.jl
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
using Documenter, SciMLSensitivity
using DocumenterVitepress

cp("./docs/Manifest.toml", "./docs/src/assets/Manifest.toml", force = true)
cp("./docs/Project.toml", "./docs/src/assets/Project.toml", force = true)
Expand All @@ -9,14 +10,24 @@ using Plots

include("pages.jl")

deploy_config = Documenter.auto_detect_deploy_system()
deploy_decision = Documenter.deploy_folder(deploy_config; repo="github.com/SciML/SciMLSensitivity.jl",
devbranch="master", devurl="dev", push_preview=true)

makedocs(sitename = "SciMLSensitivity.jl",
authors = "Chris Rackauckas et al.",
modules = [SciMLSensitivity],
clean = true, doctest = false, linkcheck = true,
warnonly = [:missing_docs],
format = Documenter.HTML(assets = ["assets/favicon.ico"],
canonical = "https://docs.sciml.ai/SciMLSensitivity/stable/"),
warnonly = true,
format = DocumenterVitepress.MarkdownVitepress(;
repo="https://github.com/SciML/SciMLSensitivity.jl",
devbranch="master", devurl="dev",
deploy_url="https://docs.sciml.ai/SciMLSensitivity/", deploy_decision
),
pages = pages)

deploydocs(repo = "github.com/SciML/SciMLSensitivity.jl.git";
target="build", # this is where Vitepress stores its output
branch = "gh-pages",
devbranch="master",
push_preview = true)
17 changes: 17 additions & 0 deletions docs/package.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,17 @@
{
"devDependencies": {
"markdown-it": "^14.1.0",
"markdown-it-mathjax3": "^4.3.2",
"vitepress": "^1.1.4",
"vitepress-plugin-tabs": "^0.5.0"
},
"scripts": {
"docs:dev": "vitepress dev build/.documenter",
"docs:build": "vitepress build build/.documenter",
"docs:preview": "vitepress preview build/.documenter"
},
"dependencies": {
"@shikijs/transformers": "^1.1.7",
"markdown-it-footnote": "^4.0.0"
}
}
84 changes: 49 additions & 35 deletions docs/pages.jl
Original file line number Diff line number Diff line change
@@ -1,37 +1,51 @@
pages = ["index.md",
"getting_started.md",
"Tutorials" => Any["tutorials/parameter_estimation_ode.md",
"tutorials/direct_sensitivity.md",
"tutorials/adjoint_continuous_functional.md",
"tutorials/data_parallel.md",
"tutorials/chaotic_ode.md",
"Training Techniques and Tips" => Any["tutorials/training_tips/local_minima.md",
"tutorials/training_tips/divergence.md",
"tutorials/training_tips/multiple_nn.md"]],
"Examples" => Any[
"Ordinary Differential Equations (ODEs)" => Any["examples/ode/exogenous_input.md",
"examples/ode/prediction_error_method.md",
"examples/ode/second_order_adjoints.md",
"examples/ode/second_order_neural.md"],
"Neural Ordinary Differential Equations (Neural ODE)" => Any[
"examples/neural_ode/neural_ode_flux.md",
"examples/neural_ode/simplechains.md",
"examples/neural_ode/minibatch.md"],
"Stochastic Differential Equations (SDEs)" => Any[
"examples/sde/optimization_sde.md",
"examples/sde/SDE_control.md"],
"Delay Differential Equations (DDEs)" => Any["examples/dde/delay_diffeq.md"],
"Partial Differential Equations (PDEs)" => Any["examples/pde/pde_constrained.md"],
"Hybrid and Jump Equations" => Any["examples/hybrid_jump/hybrid_diffeq.md",
"examples/hybrid_jump/bouncing_ball.md"],
"Bayesian Estimation" => Any["examples/bayesian/turing_bayesian.md"],
"Optimal and Model Predictive Control" => Any[
"examples/optimal_control/optimal_control.md",
"examples/optimal_control/feedback_control.md"]],
"Manual and APIs" => Any["manual/differential_equation_sensitivities.md",
"manual/nonlinear_solve_sensitivities.md",
"manual/direct_forward_sensitivity.md",
"manual/direct_adjoint_sensitivities.md"],
pages = ["Home" => "index.md",
"Get Started" => "getting_started.md",
"Tutorials" => [
"Parameter estimation ode" => "tutorials/parameter_estimation_ode.md",
"Training Techniques and Tips" => [
"Local minima" => "tutorials/training_tips/local_minima.md",
]
],
"Examples" => [
"Ordinary Differential Equations (ODEs)" => [
"Exogenous input"=>"examples/ode/exogenous_input.md",
"Prediction error method" => "examples/ode/prediction_error_method.md",
"Second order adjoints" => "examples/ode/second_order_adjoints.md",
"second_order_neural" => "examples/ode/second_order_neural.md"
],
"Neural Ordinary Differential Equations (Neural ODE)" => [
"neural ode flux"=>"examples/neural_ode/neural_ode_flux.md",
"Simple chains" => "examples/neural_ode/simplechains.md",
"Minibatch" => "examples/neural_ode/minibatch.md"
],
"Stochastic Differential Equations (SDEs)" => [
"optimization sde"=>"examples/sde/optimization_sde.md",
"SDE_control" => "examples/sde/SDE_control.md"
],
"Delay Differential Equations (DDEs)" => [
"delay diffeq"=>"examples/dde/delay_diffeq.md"
],
"Partial Differential Equations (PDEs)" => [
"pde constrained"=>"examples/pde/pde_constrained.md"
],
"Hybrid and Jump Equations" => [
"Hybrid diffeq"=>"examples/hybrid_jump/hybrid_diffeq.md",
"Bouncing ball" => "examples/hybrid_jump/bouncing_ball.md"
],
"Bayesian Estimation" => [
"Turing Bayesian"=>"examples/bayesian/turing_bayesian.md"
],
"Optimal and Model Predictive Control" => [
"Optimal control"=>"examples/optimal_control/optimal_control.md",
"Feedback control" => "examples/optimal_control/feedback_control.md"
]
],
"Manual and APIs" => [
"Differential equation sensitivities" => "manual/differential_equation_sensitivities.md",
"Nonlinear solve sensitivities" => "manual/nonlinear_solve_sensitivities.md",
"Direct forward sensitivity" => "manual/direct_forward_sensitivity.md",
"Direct adjoint sensitivities" => "manual/direct_adjoint_sensitivities.md"
],
"Benchmarks" => "Benchmark.md",
"Sensitivity Math Details" => "sensitivity_math.md"
]
]
Loading