Skip to content

Commit

Permalink
Remove repeated definition of sigmoid
Browse files Browse the repository at this point in the history
  • Loading branch information
facusapienza21 authored Nov 13, 2024
1 parent 90eb112 commit 031fb79
Showing 1 changed file with 1 addition and 15 deletions.
16 changes: 1 addition & 15 deletions src/utils.jl
Original file line number Diff line number Diff line change
Expand Up @@ -38,15 +38,6 @@ function sigmoid(x)
return 1.0 / (1.0 + exp(-x))
end

function sigmoid(z::Complex)
return 1.0 / ( 1.0 + exp(-z) )
# if real(z) > 0
# return 1 / ( 1.0 + exp(-z) )
# else
# return exp(z) / (1.0 + exp(z))
# end
end

"""
relu_cap(x; ω₀=1.0)
"""
Expand Down Expand Up @@ -94,11 +85,6 @@ end
"""
function sigmoid(z::Complex)
return 1.0 / ( 1.0 + exp(-z) )
# if real(z) > 0
# return 1 / ( 1.0 + exp(-z) )
# else
# return exp(z) / (1.0 + exp(z))
# end
end

"""
Expand Down Expand Up @@ -309,4 +295,4 @@ function convert2dict(data::SphereData, results::Results)
_dict["losses"] = results.losses

return _dict
end
end

0 comments on commit 031fb79

Please sign in to comment.