From 4c5043508eaa3bdd133b40e3cfac9e13a12826e4 Mon Sep 17 00:00:00 2001 From: "Documenter.jl" Date: Tue, 26 Dec 2023 16:47:04 +0000 Subject: [PATCH] build based on 2040e3a --- dev/.documenter-siteinfo.json | 2 +- dev/index.html | 41 ++++++++++++++++++++++++++--------- dev/internalapis/index.html | 4 ++-- dev/search_index.js | 2 +- 4 files changed, 35 insertions(+), 14 deletions(-) diff --git a/dev/.documenter-siteinfo.json b/dev/.documenter-siteinfo.json index 202c25c..6265aa3 100644 --- a/dev/.documenter-siteinfo.json +++ b/dev/.documenter-siteinfo.json @@ -1 +1 @@ -{"documenter":{"julia_version":"1.9.4","generation_timestamp":"2023-12-26T16:18:02","documenter_version":"1.2.1"}} \ No newline at end of file +{"documenter":{"julia_version":"1.9.4","generation_timestamp":"2023-12-26T16:47:01","documenter_version":"1.2.1"}} \ No newline at end of file diff --git a/dev/index.html b/dev/index.html index 7eda95f..6a7cec8 100644 --- a/dev/index.html +++ b/dev/index.html @@ -5,15 +5,12 @@ julia> fpath = "PhotosplineReader.jl/test/examples/IceCube_data_release_202209013_kdes/E_dec_photospline_v006_3D.fits"; -julia> spt = FITS(fpath) do f - SplineTable(f) - end +julia> spt = SplineTable( fpath ) 3-dimensional SplineTable of b-spline orders [1, 1, 3], -with extents: - (0.83, 10.21) - (-0.17, 1.00) - (0.57, 4.42) - +with extents: + (0.83, 10.21) + (-0.17, 1.00) + (0.57, 4.42) julia> x = [ 2.8, 0.2, 3.0 ] 3-element Vector{Float64}: @@ -21,5 +18,29 @@ 0.2 3.0 -julia> evaluate_simple( x, spt ) -0.7973871961087491 +julia> spt(x) +0.7973871961087491 + +julia> spt(x...) +0.7973871961087491

Interfacing with Interpolations.jl

julia> using Interpolations
+
+julia> spt = SplineTable( fpath )
+3-dimensional SplineTable of b-spline orders [1, 1, 3],
+with extents:
+    (0.83, 10.21)
+    (-0.17, 1.00)
+    (0.57, 4.42)
+
+julia> itp = spline_interpolation( spt );
+
+julia> typeof( itp )
+Interpolations.FilledExtrapolation{Float64, 3, ScaledInterpolation{Float32, 3, Interpolations.BSplineInterpolation{Float32, 3, Array{Float32, 3}, Tuple{BSpline{Linear{Throw{OnGrid}}}, BSpline{Linear{Throw{OnGrid}}}, BSpline{Cubic{Line{OnGrid}}}}, Tuple{Base.Slice{UnitRange{Int64}}, Base.Slice{UnitRange{Int64}}, Base.Slice{UnitRange{Int64}}}}, Tuple{BSpline{Linear{Throw{OnGrid}}}, BSpline{Linear{Throw{OnGrid}}}, BSpline{Cubic{Line{OnGrid}}}}, Tuple{StepRangeLen{Float64, Base.TwicePrecision{Float64}, Base.TwicePrecision{Float64}, Int64}, StepRangeLen{Float64, Base.TwicePrecision{Float64}, Base.TwicePrecision{Float64}, Int64}, StepRangeLen{Float64, Base.TwicePrecision{Float64}, Base.TwicePrecision{Float64}, Int64}}}, Tuple{BSpline{Linear{Throw{OnGrid}}}, BSpline{Linear{Throw{OnGrid}}}, BSpline{Cubic{Line{OnGrid}}}}, Float64}
+
+julia> itp( x... )
+0.7973871961087493
+
+julia> Interpolations.gradient( itp, x... )
+3-element StaticArraysCore.SVector{3, Float64} with indices SOneTo(3):
+ -1.0382749146578347
+ -0.4631499529505209
+  0.08274258979323065
diff --git a/dev/internalapis/index.html b/dev/internalapis/index.html index f2780dd..e8d75f6 100644 --- a/dev/internalapis/index.html +++ b/dev/internalapis/index.html @@ -1,3 +1,3 @@ -APIs · PhotosplineReader.jl
PhotosplineReader.spline_interpolationMethod
spline_interpolation( spt::SplineTable )
-spline_interpolation( f::FITS )

make an Interpolation object from a given SplineTable. note that this method assumes that spline padding knots are symmetric on both sides, and that it Interpolations supports only up to cubic-order B-splines.

source
+APIs · PhotosplineReader.jl
PhotosplineReader.spline_interpolationMethod
spline_interpolation( spt::SplineTable )
+spline_interpolation( f::FITS )

make an Interpolation object from a given SplineTable. note that this method assumes that spline padding knots are symmetric on both sides, and that it Interpolations supports only up to cubic-order B-splines.

source
diff --git a/dev/search_index.js b/dev/search_index.js index 6e120bd..474cbdd 100644 --- a/dev/search_index.js +++ b/dev/search_index.js @@ -1,3 +1,3 @@ var documenterSearchIndex = {"docs": -[{"location":"internalapis/","page":"APIs","title":"APIs","text":"Modules = [PhotosplineReader]","category":"page"},{"location":"internalapis/#PhotosplineReader.SplineTable-Tuple{FITSIO.FITS}","page":"APIs","title":"PhotosplineReader.SplineTable","text":"SplineTable( f::FITS )\n\nread a FITS file into a SplineTable struct.\n\n\n\n\n\n","category":"method"},{"location":"internalapis/#PhotosplineReader.evaluate_simple-Tuple{Any, SplineTable}","page":"APIs","title":"PhotosplineReader.evaluate_simple","text":"evaluate_simple( x, spt::SplineTable )\n\nevalute the spline at x.\n\n\n\n\n\n","category":"method"},{"location":"internalapis/#PhotosplineReader.spline_interpolation-Tuple{SplineTable}","page":"APIs","title":"PhotosplineReader.spline_interpolation","text":"spline_interpolation( spt::SplineTable )\nspline_interpolation( f::FITS )\n\nmake an Interpolation object from a given SplineTable. note that this method assumes that spline padding knots are symmetric on both sides, and that it Interpolations supports only up to cubic-order B-splines.\n\n\n\n\n\n","category":"method"},{"location":"#PhotosplineReader.jl","page":"-","title":"PhotosplineReader.jl","text":"","category":"section"},{"location":"","page":"-","title":"-","text":"(Image: Dev) (Image: Build Status)","category":"page"},{"location":"","page":"-","title":"-","text":"source code adapted to julia from https://github.com/icecube/photospline, with help from FITSIO.jl and BasicBSpline.jl.","category":"page"},{"location":"#Quick-start","page":"-","title":"Quick start","text":"","category":"section"},{"location":"","page":"-","title":"-","text":"julia> using PhotosplineReader\n\njulia> using PhotosplineReader.FITSIO\n\njulia> fpath = \"PhotosplineReader.jl/test/examples/IceCube_data_release_202209013_kdes/E_dec_photospline_v006_3D.fits\";\n\njulia> spt = FITS(fpath) do f\n SplineTable(f)\n end\n3-dimensional SplineTable of b-spline orders [1, 1, 3],\nwith extents: \n\t (0.83, 10.21) \n\t (-0.17, 1.00) \n\t (0.57, 4.42) \n\n\njulia> x = [ 2.8, 0.2, 3.0 ]\n3-element Vector{Float64}:\n 2.8\n 0.2\n 3.0\n\njulia> evaluate_simple( x, spt )\n0.7973871961087491","category":"page"}] +[{"location":"internalapis/","page":"APIs","title":"APIs","text":"Modules = [PhotosplineReader]","category":"page"},{"location":"internalapis/#PhotosplineReader.SplineTable-Tuple{FITSIO.FITS}","page":"APIs","title":"PhotosplineReader.SplineTable","text":"SplineTable( f::FITS )\n\nread a FITS file into a SplineTable struct.\n\n\n\n\n\n","category":"method"},{"location":"internalapis/#PhotosplineReader.evaluate_simple-Tuple{Any, SplineTable}","page":"APIs","title":"PhotosplineReader.evaluate_simple","text":"evaluate_simple( x, spt::SplineTable )\n\nevalute the spline at x.\n\n\n\n\n\n","category":"method"},{"location":"internalapis/#PhotosplineReader.spline_interpolation-Tuple{SplineTable}","page":"APIs","title":"PhotosplineReader.spline_interpolation","text":"spline_interpolation( spt::SplineTable )\nspline_interpolation( f::FITS )\n\nmake an Interpolation object from a given SplineTable. note that this method assumes that spline padding knots are symmetric on both sides, and that it Interpolations supports only up to cubic-order B-splines.\n\n\n\n\n\n","category":"method"},{"location":"#PhotosplineReader.jl","page":"-","title":"PhotosplineReader.jl","text":"","category":"section"},{"location":"","page":"-","title":"-","text":"(Image: Dev) (Image: Build Status)","category":"page"},{"location":"","page":"-","title":"-","text":"source code adapted to julia from https://github.com/icecube/photospline, with help from FITSIO.jl and BasicBSpline.jl.","category":"page"},{"location":"#Quick-start","page":"-","title":"Quick start","text":"","category":"section"},{"location":"","page":"-","title":"-","text":"julia> using PhotosplineReader\n\njulia> using PhotosplineReader.FITSIO\n\njulia> fpath = \"PhotosplineReader.jl/test/examples/IceCube_data_release_202209013_kdes/E_dec_photospline_v006_3D.fits\";\n\njulia> spt = SplineTable( fpath )\n3-dimensional SplineTable of b-spline orders [1, 1, 3],\nwith extents:\n (0.83, 10.21)\n (-0.17, 1.00)\n (0.57, 4.42)\n\njulia> x = [ 2.8, 0.2, 3.0 ]\n3-element Vector{Float64}:\n 2.8\n 0.2\n 3.0\n\njulia> spt(x)\n0.7973871961087491\n\njulia> spt(x...)\n0.7973871961087491","category":"page"},{"location":"#Interfacing-with-Interpolations.jl","page":"-","title":"Interfacing with Interpolations.jl","text":"","category":"section"},{"location":"","page":"-","title":"-","text":"julia> using Interpolations\n\njulia> spt = SplineTable( fpath )\n3-dimensional SplineTable of b-spline orders [1, 1, 3],\nwith extents:\n (0.83, 10.21)\n (-0.17, 1.00)\n (0.57, 4.42)\n\njulia> itp = spline_interpolation( spt );\n\njulia> typeof( itp )\nInterpolations.FilledExtrapolation{Float64, 3, ScaledInterpolation{Float32, 3, Interpolations.BSplineInterpolation{Float32, 3, Array{Float32, 3}, Tuple{BSpline{Linear{Throw{OnGrid}}}, BSpline{Linear{Throw{OnGrid}}}, BSpline{Cubic{Line{OnGrid}}}}, Tuple{Base.Slice{UnitRange{Int64}}, Base.Slice{UnitRange{Int64}}, Base.Slice{UnitRange{Int64}}}}, Tuple{BSpline{Linear{Throw{OnGrid}}}, BSpline{Linear{Throw{OnGrid}}}, BSpline{Cubic{Line{OnGrid}}}}, Tuple{StepRangeLen{Float64, Base.TwicePrecision{Float64}, Base.TwicePrecision{Float64}, Int64}, StepRangeLen{Float64, Base.TwicePrecision{Float64}, Base.TwicePrecision{Float64}, Int64}, StepRangeLen{Float64, Base.TwicePrecision{Float64}, Base.TwicePrecision{Float64}, Int64}}}, Tuple{BSpline{Linear{Throw{OnGrid}}}, BSpline{Linear{Throw{OnGrid}}}, BSpline{Cubic{Line{OnGrid}}}}, Float64}\n\njulia> itp( x... )\n0.7973871961087493\n\njulia> Interpolations.gradient( itp, x... )\n3-element StaticArraysCore.SVector{3, Float64} with indices SOneTo(3):\n -1.0382749146578347\n -0.4631499529505209\n 0.08274258979323065","category":"page"}] }