Skip to content

Commit

Permalink
build based on fbf4714
Browse files Browse the repository at this point in the history
  • Loading branch information
Documenter.jl committed Feb 12, 2024
1 parent b4ea70c commit 902038c
Show file tree
Hide file tree
Showing 14 changed files with 210 additions and 183 deletions.
72 changes: 48 additions & 24 deletions dev/api/Building_Blocks/WeightInitializers.md
Original file line number Diff line number Diff line change
Expand Up @@ -150,7 +150,8 @@ Return an `AbstractArray{T}` of the given `size` where each element is drawn fro


```julia
zeros16([::AbstractRNG=_default_rng()], size...; kwargs...) -> AbstractArray{Float16, length(size)}
zeros16([::AbstractRNG=_default_rng()], size...;
kwargs...) -> AbstractArray{Float16, length(size)}
```

Return an `AbstractArray{Float16}` of the given `size` containing an AbstractArray of zeros.
Expand All @@ -163,7 +164,8 @@ Return an `AbstractArray{Float16}` of the given `size` containing an AbstractArr


```julia
ones16([::AbstractRNG=_default_rng()], size...; kwargs...) -> AbstractArray{Float16, length(size)}
ones16([::AbstractRNG=_default_rng()], size...;
kwargs...) -> AbstractArray{Float16, length(size)}
```

Return an `AbstractArray{Float16}` of the given `size` containing an AbstractArray of ones.
Expand All @@ -176,7 +178,8 @@ Return an `AbstractArray{Float16}` of the given `size` containing an AbstractArr


```julia
rand16([::AbstractRNG=_default_rng()], size...; kwargs...) -> AbstractArray{Float16, length(size)}
rand16([::AbstractRNG=_default_rng()], size...;
kwargs...) -> AbstractArray{Float16, length(size)}
```

Return an `AbstractArray{Float16}` of the given `size` containing random numbers from a uniform distribution.
Expand All @@ -189,7 +192,8 @@ Return an `AbstractArray{Float16}` of the given `size` containing random numbers


```julia
randn16([::AbstractRNG=_default_rng()], size...; kwargs...) -> AbstractArray{Float16, length(size)}
randn16([::AbstractRNG=_default_rng()], size...;
kwargs...) -> AbstractArray{Float16, length(size)}
```

Return an `AbstractArray{Float16}` of the given `size` containing random numbers from a standard normal distribution.
Expand All @@ -202,7 +206,8 @@ Return an `AbstractArray{Float16}` of the given `size` containing random numbers


```julia
zeros32([::AbstractRNG=_default_rng()], size...; kwargs...) -> AbstractArray{Float32, length(size)}
zeros32([::AbstractRNG=_default_rng()], size...;
kwargs...) -> AbstractArray{Float32, length(size)}
```

Return an `AbstractArray{Float32}` of the given `size` containing an AbstractArray of zeros.
Expand All @@ -215,7 +220,8 @@ Return an `AbstractArray{Float32}` of the given `size` containing an AbstractArr


```julia
ones32([::AbstractRNG=_default_rng()], size...; kwargs...) -> AbstractArray{Float32, length(size)}
ones32([::AbstractRNG=_default_rng()], size...;
kwargs...) -> AbstractArray{Float32, length(size)}
```

Return an `AbstractArray{Float32}` of the given `size` containing an AbstractArray of ones.
Expand All @@ -228,7 +234,8 @@ Return an `AbstractArray{Float32}` of the given `size` containing an AbstractArr


```julia
rand32([::AbstractRNG=_default_rng()], size...; kwargs...) -> AbstractArray{Float32, length(size)}
rand32([::AbstractRNG=_default_rng()], size...;
kwargs...) -> AbstractArray{Float32, length(size)}
```

Return an `AbstractArray{Float32}` of the given `size` containing random numbers from a uniform distribution.
Expand All @@ -241,7 +248,8 @@ Return an `AbstractArray{Float32}` of the given `size` containing random numbers


```julia
randn32([::AbstractRNG=_default_rng()], size...; kwargs...) -> AbstractArray{Float32, length(size)}
randn32([::AbstractRNG=_default_rng()], size...;
kwargs...) -> AbstractArray{Float32, length(size)}
```

Return an `AbstractArray{Float32}` of the given `size` containing random numbers from a standard normal distribution.
Expand All @@ -254,7 +262,8 @@ Return an `AbstractArray{Float32}` of the given `size` containing random numbers


```julia
zeros64([::AbstractRNG=_default_rng()], size...; kwargs...) -> AbstractArray{Float64, length(size)}
zeros64([::AbstractRNG=_default_rng()], size...;
kwargs...) -> AbstractArray{Float64, length(size)}
```

Return an `AbstractArray{Float64}` of the given `size` containing an AbstractArray of zeros.
Expand All @@ -267,7 +276,8 @@ Return an `AbstractArray{Float64}` of the given `size` containing an AbstractArr


```julia
ones64([::AbstractRNG=_default_rng()], size...; kwargs...) -> AbstractArray{Float64, length(size)}
ones64([::AbstractRNG=_default_rng()], size...;
kwargs...) -> AbstractArray{Float64, length(size)}
```

Return an `AbstractArray{Float64}` of the given `size` containing an AbstractArray of ones.
Expand All @@ -280,7 +290,8 @@ Return an `AbstractArray{Float64}` of the given `size` containing an AbstractArr


```julia
rand64([::AbstractRNG=_default_rng()], size...; kwargs...) -> AbstractArray{Float64, length(size)}
rand64([::AbstractRNG=_default_rng()], size...;
kwargs...) -> AbstractArray{Float64, length(size)}
```

Return an `AbstractArray{Float64}` of the given `size` containing random numbers from a uniform distribution.
Expand All @@ -293,7 +304,8 @@ Return an `AbstractArray{Float64}` of the given `size` containing random numbers


```julia
randn64([::AbstractRNG=_default_rng()], size...; kwargs...) -> AbstractArray{Float64, length(size)}
randn64([::AbstractRNG=_default_rng()], size...;
kwargs...) -> AbstractArray{Float64, length(size)}
```

Return an `AbstractArray{Float64}` of the given `size` containing random numbers from a standard normal distribution.
Expand All @@ -306,7 +318,8 @@ Return an `AbstractArray{Float64}` of the given `size` containing random numbers


```julia
zerosC16([::AbstractRNG=_default_rng()], size...; kwargs...) -> AbstractArray{ComplexF16, length(size)}
zerosC16([::AbstractRNG=_default_rng()], size...;
kwargs...) -> AbstractArray{ComplexF16, length(size)}
```

Return an `AbstractArray{ComplexF16}` of the given `size` containing an AbstractArray of zeros.
Expand All @@ -319,7 +332,8 @@ Return an `AbstractArray{ComplexF16}` of the given `size` containing an Abstract


```julia
onesC16([::AbstractRNG=_default_rng()], size...; kwargs...) -> AbstractArray{ComplexF16, length(size)}
onesC16([::AbstractRNG=_default_rng()], size...;
kwargs...) -> AbstractArray{ComplexF16, length(size)}
```

Return an `AbstractArray{ComplexF16}` of the given `size` containing an AbstractArray of ones.
Expand All @@ -332,7 +346,8 @@ Return an `AbstractArray{ComplexF16}` of the given `size` containing an Abstract


```julia
randC16([::AbstractRNG=_default_rng()], size...; kwargs...) -> AbstractArray{ComplexF16, length(size)}
randC16([::AbstractRNG=_default_rng()], size...;
kwargs...) -> AbstractArray{ComplexF16, length(size)}
```

Return an `AbstractArray{ComplexF16}` of the given `size` containing random numbers from a uniform distribution.
Expand All @@ -345,7 +360,8 @@ Return an `AbstractArray{ComplexF16}` of the given `size` containing random numb


```julia
randnC16([::AbstractRNG=_default_rng()], size...; kwargs...) -> AbstractArray{ComplexF16, length(size)}
randnC16([::AbstractRNG=_default_rng()], size...;
kwargs...) -> AbstractArray{ComplexF16, length(size)}
```

Return an `AbstractArray{ComplexF16}` of the given `size` containing random numbers from a standard normal distribution.
Expand All @@ -358,7 +374,8 @@ Return an `AbstractArray{ComplexF16}` of the given `size` containing random numb


```julia
zerosC32([::AbstractRNG=_default_rng()], size...; kwargs...) -> AbstractArray{ComplexF32, length(size)}
zerosC32([::AbstractRNG=_default_rng()], size...;
kwargs...) -> AbstractArray{ComplexF32, length(size)}
```

Return an `AbstractArray{ComplexF32}` of the given `size` containing an AbstractArray of zeros.
Expand All @@ -371,7 +388,8 @@ Return an `AbstractArray{ComplexF32}` of the given `size` containing an Abstract


```julia
onesC32([::AbstractRNG=_default_rng()], size...; kwargs...) -> AbstractArray{ComplexF32, length(size)}
onesC32([::AbstractRNG=_default_rng()], size...;
kwargs...) -> AbstractArray{ComplexF32, length(size)}
```

Return an `AbstractArray{ComplexF32}` of the given `size` containing an AbstractArray of ones.
Expand All @@ -384,7 +402,8 @@ Return an `AbstractArray{ComplexF32}` of the given `size` containing an Abstract


```julia
randC32([::AbstractRNG=_default_rng()], size...; kwargs...) -> AbstractArray{ComplexF32, length(size)}
randC32([::AbstractRNG=_default_rng()], size...;
kwargs...) -> AbstractArray{ComplexF32, length(size)}
```

Return an `AbstractArray{ComplexF32}` of the given `size` containing random numbers from a uniform distribution.
Expand All @@ -397,7 +416,8 @@ Return an `AbstractArray{ComplexF32}` of the given `size` containing random numb


```julia
randnC32([::AbstractRNG=_default_rng()], size...; kwargs...) -> AbstractArray{ComplexF32, length(size)}
randnC32([::AbstractRNG=_default_rng()], size...;
kwargs...) -> AbstractArray{ComplexF32, length(size)}
```

Return an `AbstractArray{ComplexF32}` of the given `size` containing random numbers from a standard normal distribution.
Expand All @@ -410,7 +430,8 @@ Return an `AbstractArray{ComplexF32}` of the given `size` containing random numb


```julia
zerosC64([::AbstractRNG=_default_rng()], size...; kwargs...) -> AbstractArray{ComplexF64, length(size)}
zerosC64([::AbstractRNG=_default_rng()], size...;
kwargs...) -> AbstractArray{ComplexF64, length(size)}
```

Return an `AbstractArray{ComplexF64}` of the given `size` containing an AbstractArray of zeros.
Expand All @@ -423,7 +444,8 @@ Return an `AbstractArray{ComplexF64}` of the given `size` containing an Abstract


```julia
onesC64([::AbstractRNG=_default_rng()], size...; kwargs...) -> AbstractArray{ComplexF64, length(size)}
onesC64([::AbstractRNG=_default_rng()], size...;
kwargs...) -> AbstractArray{ComplexF64, length(size)}
```

Return an `AbstractArray{ComplexF64}` of the given `size` containing an AbstractArray of ones.
Expand All @@ -436,7 +458,8 @@ Return an `AbstractArray{ComplexF64}` of the given `size` containing an Abstract


```julia
randC64([::AbstractRNG=_default_rng()], size...; kwargs...) -> AbstractArray{ComplexF64, length(size)}
randC64([::AbstractRNG=_default_rng()], size...;
kwargs...) -> AbstractArray{ComplexF64, length(size)}
```

Return an `AbstractArray{ComplexF64}` of the given `size` containing random numbers from a uniform distribution.
Expand All @@ -449,7 +472,8 @@ Return an `AbstractArray{ComplexF64}` of the given `size` containing random numb


```julia
randnC64([::AbstractRNG=_default_rng()], size...; kwargs...) -> AbstractArray{ComplexF64, length(size)}
randnC64([::AbstractRNG=_default_rng()], size...;
kwargs...) -> AbstractArray{ComplexF64, length(size)}
```

Return an `AbstractArray{ComplexF64}` of the given `size` containing random numbers from a standard normal distribution.
Expand Down
32 changes: 16 additions & 16 deletions dev/api/Lux/contrib.md
Original file line number Diff line number Diff line change
Expand Up @@ -71,7 +71,7 @@ Training State containing:
* `step`: Number of updates of the parameters made.


<a target='_blank' href='https://github.com/LuxDL/Lux.jl/blob/792e10d40a9dd0dc107fa8f4528018f9620cae5c/src/contrib/training.jl#L3-L13' class='documenter-source'>source</a><br>
<a target='_blank' href='https://github.com/LuxDL/Lux.jl/blob/fbf471448f5a4fcb63b968f9befd3333d8cc431f/src/contrib/training.jl#L3-L13' class='documenter-source'>source</a><br>

</div>
<br>
Expand Down Expand Up @@ -104,7 +104,7 @@ A 4-Tuple containing:
* `ts`: Updated Training State.


<a target='_blank' href='https://github.com/LuxDL/Lux.jl/blob/792e10d40a9dd0dc107fa8f4528018f9620cae5c/src/contrib/training.jl#L68-L92' class='documenter-source'>source</a><br>
<a target='_blank' href='https://github.com/LuxDL/Lux.jl/blob/fbf471448f5a4fcb63b968f9befd3333d8cc431f/src/contrib/training.jl#L68-L92' class='documenter-source'>source</a><br>

</div>
<br>
Expand All @@ -129,7 +129,7 @@ Update the parameters stored in `ts` using the gradients `grads`.
Updated `TrainState` object.


<a target='_blank' href='https://github.com/LuxDL/Lux.jl/blob/792e10d40a9dd0dc107fa8f4528018f9620cae5c/src/contrib/training.jl#L49-L62' class='documenter-source'>source</a><br>
<a target='_blank' href='https://github.com/LuxDL/Lux.jl/blob/fbf471448f5a4fcb63b968f9befd3333d8cc431f/src/contrib/training.jl#L49-L62' class='documenter-source'>source</a><br>

</div>
<br>
Expand Down Expand Up @@ -206,7 +206,7 @@ m = Lux.Experimental.FrozenLayer(Dense(2 => 2), (:weight,))
See also [`Lux.Experimental.freeze`](contrib#Lux.Experimental.freeze), [`Lux.Experimental.unfreeze`](contrib#Lux.Experimental.unfreeze).


<a target='_blank' href='https://github.com/LuxDL/Lux.jl/blob/792e10d40a9dd0dc107fa8f4528018f9620cae5c/src/contrib/freeze.jl#L1-L57' class='documenter-source'>source</a><br>
<a target='_blank' href='https://github.com/LuxDL/Lux.jl/blob/fbf471448f5a4fcb63b968f9befd3333d8cc431f/src/contrib/freeze.jl#L1-L57' class='documenter-source'>source</a><br>

</div>
<br>
Expand All @@ -222,7 +222,7 @@ freeze(l::AbstractExplicitLayer, which_params::Union{Tuple, Nothing} = nothing)
Constructs a version of `l` with `which_params` frozen. If `which_params` is nothing, then all parameters are frozen.


<a target='_blank' href='https://github.com/LuxDL/Lux.jl/blob/792e10d40a9dd0dc107fa8f4528018f9620cae5c/src/contrib/freeze.jl#L107-L112' class='documenter-source'>source</a><br>
<a target='_blank' href='https://github.com/LuxDL/Lux.jl/blob/fbf471448f5a4fcb63b968f9befd3333d8cc431f/src/contrib/freeze.jl#L107-L112' class='documenter-source'>source</a><br>


```
Expand All @@ -233,7 +233,7 @@ freeze(l::AbstractExplicitLayer, ps, st::NamedTuple,
Construct a [`Lux.Experimental.FrozenLayer`](contrib#Lux.Experimental.FrozenLayer) for `l` with the current parameters and states. If `which_params` is nothing, then all parameters are frozen.


<a target='_blank' href='https://github.com/LuxDL/Lux.jl/blob/792e10d40a9dd0dc107fa8f4528018f9620cae5c/src/contrib/freeze.jl#L117-L123' class='documenter-source'>source</a><br>
<a target='_blank' href='https://github.com/LuxDL/Lux.jl/blob/fbf471448f5a4fcb63b968f9befd3333d8cc431f/src/contrib/freeze.jl#L117-L123' class='documenter-source'>source</a><br>

</div>
<br>
Expand All @@ -249,7 +249,7 @@ unfreeze(l::FrozenLayer)
Unfreezes the layer `l`.


<a target='_blank' href='https://github.com/LuxDL/Lux.jl/blob/792e10d40a9dd0dc107fa8f4528018f9620cae5c/src/contrib/freeze.jl#L141-L145' class='documenter-source'>source</a><br>
<a target='_blank' href='https://github.com/LuxDL/Lux.jl/blob/fbf471448f5a4fcb63b968f9befd3333d8cc431f/src/contrib/freeze.jl#L141-L145' class='documenter-source'>source</a><br>


```
Expand All @@ -259,7 +259,7 @@ unfreeze(l::FrozenLayer, ps, st::NamedTuple)
Unwraps a [`Lux.Experimental.FrozenLayer`](contrib#Lux.Experimental.FrozenLayer) `l` with the current parameters and states.


<a target='_blank' href='https://github.com/LuxDL/Lux.jl/blob/792e10d40a9dd0dc107fa8f4528018f9620cae5c/src/contrib/freeze.jl#L148-L152' class='documenter-source'>source</a><br>
<a target='_blank' href='https://github.com/LuxDL/Lux.jl/blob/fbf471448f5a4fcb63b968f9befd3333d8cc431f/src/contrib/freeze.jl#L148-L152' class='documenter-source'>source</a><br>

</div>
<br>
Expand Down Expand Up @@ -320,7 +320,7 @@ Lux.layer_map(zero_dense_params, c, ps, st)
```


<a target='_blank' href='https://github.com/LuxDL/Lux.jl/blob/792e10d40a9dd0dc107fa8f4528018f9620cae5c/src/contrib/map.jl#L42' class='documenter-source'>source</a><br>
<a target='_blank' href='https://github.com/LuxDL/Lux.jl/blob/fbf471448f5a4fcb63b968f9befd3333d8cc431f/src/contrib/map.jl#L42' class='documenter-source'>source</a><br>

</div>
<br>
Expand Down Expand Up @@ -361,7 +361,7 @@ Lux.@layer_map zero_dense_params c ps st
```


<a target='_blank' href='https://github.com/LuxDL/Lux.jl/blob/792e10d40a9dd0dc107fa8f4528018f9620cae5c/src/contrib/map.jl#L4' class='documenter-source'>source</a><br>
<a target='_blank' href='https://github.com/LuxDL/Lux.jl/blob/fbf471448f5a4fcb63b968f9befd3333d8cc431f/src/contrib/map.jl#L4' class='documenter-source'>source</a><br>

</div>
<br>
Expand All @@ -387,7 +387,7 @@ Recurses into the `layer` and replaces the inner most non Container Layers with
See [`Lux.Experimental.DebugLayer`](contrib#Lux.Experimental.DebugLayer) for details about the Keyword Arguments.


<a target='_blank' href='https://github.com/LuxDL/Lux.jl/blob/792e10d40a9dd0dc107fa8f4528018f9620cae5c/src/contrib/debug.jl#L159-L166' class='documenter-source'>source</a><br>
<a target='_blank' href='https://github.com/LuxDL/Lux.jl/blob/fbf471448f5a4fcb63b968f9befd3333d8cc431f/src/contrib/debug.jl#L159-L166' class='documenter-source'>source</a><br>

</div>
<br>
Expand Down Expand Up @@ -439,7 +439,7 @@ If `nan_check` is enabled and NaNs are detected then a `DomainError` is thrown.
See [`Lux.Experimental.@debug_mode`](contrib#Lux.Experimental.@debug_mode) to construct this layer.


<a target='_blank' href='https://github.com/LuxDL/Lux.jl/blob/792e10d40a9dd0dc107fa8f4528018f9620cae5c/src/contrib/debug.jl#L1-L49' class='documenter-source'>source</a><br>
<a target='_blank' href='https://github.com/LuxDL/Lux.jl/blob/fbf471448f5a4fcb63b968f9befd3333d8cc431f/src/contrib/debug.jl#L1-L49' class='documenter-source'>source</a><br>

</div>
<br>
Expand Down Expand Up @@ -485,7 +485,7 @@ ps = Lux.share_parameters(ps, (("d3.l2", "d1"), ("d2", "d3.l1")))
```


<a target='_blank' href='https://github.com/LuxDL/Lux.jl/blob/792e10d40a9dd0dc107fa8f4528018f9620cae5c/src/contrib/share_parameters.jl#L3-L38' class='documenter-source'>source</a><br>
<a target='_blank' href='https://github.com/LuxDL/Lux.jl/blob/fbf471448f5a4fcb63b968f9befd3333d8cc431f/src/contrib/share_parameters.jl#L3-L38' class='documenter-source'>source</a><br>

</div>
<br>
Expand Down Expand Up @@ -535,7 +535,7 @@ State is mutated in place. An additional caveat is that the updated state from `
* `y`: The output of the layer


<a target='_blank' href='https://github.com/LuxDL/Lux.jl/blob/792e10d40a9dd0dc107fa8f4528018f9620cae5c/src/contrib/stateful.jl#L1-L39' class='documenter-source'>source</a><br>
<a target='_blank' href='https://github.com/LuxDL/Lux.jl/blob/fbf471448f5a4fcb63b968f9befd3333d8cc431f/src/contrib/stateful.jl#L1-L39' class='documenter-source'>source</a><br>

</div>
<br>
Expand Down Expand Up @@ -583,7 +583,7 @@ Here is a linear model with bias and activation:
```julia
d_in = 5
d_out = 7
d = @compact(W=randn(d_out, d_in), b=zeros(d_out), act=relu) do x
d = @compact(W=randn(d_out, d_in), b=zeros(d_out),act=relu) do x
y = W * x
return act.(y .+ b)
end
Expand Down Expand Up @@ -661,7 +661,7 @@ Array Parameter don't print the number of parameters on the side. However, they
:::


<a target='_blank' href='https://github.com/LuxDL/Lux.jl/blob/792e10d40a9dd0dc107fa8f4528018f9620cae5c/src/contrib/compact.jl#L17-L135' class='documenter-source'>source</a><br>
<a target='_blank' href='https://github.com/LuxDL/Lux.jl/blob/fbf471448f5a4fcb63b968f9befd3333d8cc431f/src/contrib/compact.jl#L17-L135' class='documenter-source'>source</a><br>

</div>
<br>
Loading

0 comments on commit 902038c

Please sign in to comment.