Skip to content

Commit

Permalink
Merge pull request #19 from SebastianM-C/outsize
Browse files Browse the repository at this point in the history
Add input and output size functions
  • Loading branch information
avik-pal authored Feb 14, 2024
2 parents 774c6fc + a14133d commit feacac5
Show file tree
Hide file tree
Showing 2 changed files with 15 additions and 1 deletion.
2 changes: 1 addition & 1 deletion lib/LuxCore/Project.toml
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
name = "LuxCore"
uuid = "bb33d45b-7691-41d6-9220-0943567d0623"
authors = ["Avik Pal <[email protected]> and contributors"]
version = "0.1.7"
version = "0.1.8"

[deps]
Functors = "d9f16b24-f501-4c13-a1f2-28368ffc5196"
Expand Down
14 changes: 14 additions & 0 deletions lib/LuxCore/src/LuxCore.jl
Original file line number Diff line number Diff line change
Expand Up @@ -93,6 +93,20 @@ statelength(nt::Union{NamedTuple, Tuple}) = length(nt) == 0 ? 0 : sum(statelengt
statelength(a::AbstractArray) = length(a)
statelength(::Any) = 1

"""
inputsize(layer)
Return the input size of the layer.
"""
function inputsize end

"""
outputsize(layer)
Return the output size of the layer.
"""
function outputsize end

"""
setup(rng::AbstractRNG, layer)
Expand Down

0 comments on commit feacac5

Please sign in to comment.