Skip to content
This repository was archived by the owner on Nov 4, 2024. It is now read-only.

Commit 983e735

Browse files
committed
Revert "Update LuxDeviceUtils.jl"
This reverts commit 023fb2a.
1 parent 023fb2a commit 983e735

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

src/LuxDeviceUtils.jl

+3-3
Original file line numberDiff line numberDiff line change
@@ -224,12 +224,12 @@ struct LuxCUDAAdaptor <: AbstractLuxDeviceAdaptor end
224224
struct LuxAMDGPUAdaptor <: AbstractLuxDeviceAdaptor end
225225
struct LuxMetalAdaptor <: AbstractLuxDeviceAdaptor end
226226

227-
function adapt_structure(::LuxCPUAdaptor,
227+
function adapt_storage(::LuxCPUAdaptor,
228228
x::Union{AbstractRange, SparseArrays.AbstractSparseArray})
229229
return x
230230
end
231-
adapt_structure(::LuxCPUAdaptor, x::AbstractArray) = adapt(Array, x)
232-
adapt_structure(::LuxCPUAdaptor, rng::AbstractRNG) = rng
231+
adapt_storage(::LuxCPUAdaptor, x::AbstractArray) = adapt(Array, x)
232+
adapt_storage(::LuxCPUAdaptor, rng::AbstractRNG) = rng
233233

234234
_isbitsarray(::AbstractArray{<:Number}) = true
235235
_isbitsarray(::AbstractArray{T}) where {T} = isbitstype(T)

0 commit comments

Comments
 (0)