Skip to content

Commit a2c4760

Browse files
committed
format fix
1 parent df3f0e4 commit a2c4760

File tree

1 file changed

+9
-9
lines changed

1 file changed

+9
-9
lines changed

src/icn.jl

Lines changed: 9 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -17,11 +17,11 @@ mutable struct ICN
1717
weights::BitVector
1818

1919
function ICN(;
20-
param=Vector{Symbol}(),
21-
tr_layer=transformation_layer(param),
22-
ar_layer=arithmetic_layer(),
23-
ag_layer=aggregation_layer(),
24-
co_layer=comparison_layer(param),
20+
param = Vector{Symbol}(),
21+
tr_layer = transformation_layer(param),
22+
ar_layer = arithmetic_layer(),
23+
ag_layer = aggregation_layer(),
24+
co_layer = comparison_layer(param),
2525
)
2626
w = generate_weights([tr_layer, ar_layer, ag_layer, co_layer])
2727
return new(tr_layer, ar_layer, ag_layer, co_layer, w)
@@ -107,7 +107,7 @@ function regularization(icn)
107107
return Σop / (Σmax + 1)
108108
end
109109

110-
max_icn_length(icn=ICN(; param=[:val])) = length(icn.transformation)
110+
max_icn_length(icn = ICN(; param = [:val])) = length(icn.transformation)
111111

112112
"""
113113
_compose(icn)
@@ -116,7 +116,7 @@ Internal function called by `compose` and `show_composition`.
116116
function _compose(icn::ICN)
117117
!is_viable(icn) && (
118118
return (
119-
(x; X=zeros(length(x), max_icn_length()), param=nothing, dom_size=0) -> typemax(Float64)
119+
(x; X = zeros(length(x), max_icn_length()), param = nothing, dom_size = 0) -> typemax(Float64)
120120
),
121121
[]
122122
)
@@ -152,11 +152,11 @@ function _compose(icn::ICN)
152152
end
153153
end
154154

155-
function composition(x; X=zeros(length(x), length(funcs[1])), dom_size, params...)
155+
function composition(x; X = zeros(length(x), length(funcs[1])), dom_size, params...)
156156
tr_in(Tuple(funcs[1]), X, x; params...)
157157
X[1:length(x), 1] .=
158158
1:length(x) .|> (i -> funcs[2][1](@view X[i, 1:length(funcs[1])]))
159-
return (y -> funcs[4][1](y; dom_size, nvars=length(x), params...))(
159+
return (y -> funcs[4][1](y; dom_size, nvars = length(x), params...))(
160160
funcs[3][1](@view X[:, 1]),
161161
)
162162
end

0 commit comments

Comments
 (0)