You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
There appears to be a mismatch between behavior of normal matrices and CuMatrices in how views of rows and columns are treated that causes a scalar indexing issue.
should https://github.com/views x[1:3,1] return a view instead of CuArray for conformity with Base matrices?
Most views are represented by CuArray objects, so we don't need the SubArray wrapper (which is responsible for the view part of the output).
So I take it that the issue you have is the scalar iteration when invoking cat with a SubArray{<:CuArray}. Extending those vcat and hcat definitions may work, but I don't feel happy extending everything to AnyGPUArray. As I mentioned before, this really needs some support in Base, as we can't make everything ::AnyGPUArray: It'll severely penalize load times, and you'll quickly run into tricky ambiguities. You can try, though.
maleadt
changed the title
Different behavior for views of columns vs rows of a CuMatrix
Scalar iteration with cat(SubArray{<:CuArray})
Sep 12, 2023
Maybe an intermediate solution where operations are changed from AbstractGpuArray to a union with (Adjoints of) SubArrays of AbstractGpuArrays - would that be more feasible or would it have similar effects on load times?
There appears to be a mismatch between behavior of normal matrices and CuMatrices in how views of rows and columns are treated that causes a scalar indexing issue.
In CuMatrices I observe:
In normal matrices on the other hand:
Versioninfo:
Does it make sense to expand Base.vcat and Base.hcat lines 141-144 in https://github.com/JuliaGPU/GPUArrays.jl/blob/master/src/host/base.jl from AbstractGPUArray to AnyGPUArray @maleadt ?
Seperately, should @views x[1:3,1] return a view instead of CuArray for conformity with Base matrices?
The text was updated successfully, but these errors were encountered: