Skip to content

Commit

Permalink
format
Browse files Browse the repository at this point in the history
  • Loading branch information
kmp5VT committed Sep 20, 2023
1 parent ada189b commit 6536ee5
Showing 1 changed file with 4 additions and 2 deletions.
6 changes: 4 additions & 2 deletions NDTensors/ext/NDTensorsCUDAExt/adapt.jl
Original file line number Diff line number Diff line change
Expand Up @@ -19,14 +19,16 @@ function Adapt.adapt_storage(adaptor::NDTensorCuArrayAdaptor, xs::AbstractArray)
return isbits(xs) ? xs : CuArray{ElT,1,BufT}(xs)
end

function Adapt.adapt_storage(adaptor::NDTensorCuArrayAdaptor, xs::NDTensors.UnallocatedZeros)
function Adapt.adapt_storage(
adaptor::NDTensorCuArrayAdaptor, xs::NDTensors.UnallocatedZeros
)
arraytype_specified_1 = set_unspecified_parameters(
CuArray, Position(1), get_parameter(xs, Position(1))
)
arraytype_specified_2 = set_unspecified_parameters(
arraytype_specified_1, Position(2), get_parameter(xs, Position(2))
)

elt = get_parameter(arraytype_specified_2, Position(1))
N = get_parameter(arraytype_specified_2, Position(2))
return NDTensors.UnallocatedZeros{
Expand Down

0 comments on commit 6536ee5

Please sign in to comment.