rm more deprecations

This commit is contained in:
Mike J Innes 2019-03-12 10:17:27 +00:00
parent 46e245b87d
commit bde51aa5a6
3 changed files with 0 additions and 15 deletions

View File

@ -49,8 +49,3 @@ function normalise(x::AbstractArray; dims=1)
σ = std(x, dims = dims, mean = μ′, corrected=false)
return (x .- μ′) ./ σ
end
function normalise(x::AbstractArray, dims)
Base.depwarn("`normalise(x::AbstractArray, dims)` is deprecated, use `normalise(a, dims=dims)` instead.", :normalise)
normalise(x, dims = dims)
end

View File

@ -59,11 +59,6 @@ onecold(y::AbstractVector, labels = 1:length(y)) = labels[Base.argmax(y)]
onecold(y::AbstractMatrix, labels...) =
dropdims(mapslices(y -> onecold(y, labels...), y, dims=1), dims=1)
function argmax(xs...)
Base.depwarn("`argmax(...) is deprecated, use `onecold(...)` instead.", :argmax)
return onecold(xs...)
end
# TODO probably still want this as a custom adjoint Zygote
# onecold(x::TrackedVector, l...) = onecold(data(x), l...)
# onecold(x::TrackedMatrix, l...) = onecold(data(x), l...)

View File

@ -1,6 +1,5 @@
using Juno
import Zygote: Params, gradient
import Base.depwarn
function update!(opt, x, )
update!(x, -apply!(opt, x, ))
@ -63,10 +62,6 @@ function train!(loss, ps, data, opt; cb = () -> ())
loss(d...)
end
update!(opt, ps, gs)
if cb() == :stop
depwarn("Use of `:stop` is deprecated; use `Flux.stop()` instead", :stop)
break
end
catch ex
if ex isa StopException
break