Matt Fishman
Matt Fishman
In the latest, I made it so the axes of the `BlockIndices` resulting from a slice pick up the block structure of the input indices: ```julia julia> using BlockArrays julia>...
One behavior I wasn't sure about was indexing with `Colon`. Currently it preserves the block structure: ```julia julia> B[:, :] 2×2-blocked 4×4 PseudoBlockMatrix{BlockIndex{2}}: Block(1, 1)[1, 1] Block(1, 1)[1, 2] │...
Yeah, I didn't look into indexing arrays with `BlockIndices` at all yet, but ideally that would work. Good point about offset axes, I also didn't have that use case in...
In the latest I added support for indexing with `BlockIndices`: ```julia julia> using BlockArrays julia> using BlockArrays: BlockIndices julia> A = BlockArray(randn(4, 4), [2, 2], [2, 2]) 2×2-blocked 4×4 BlockMatrix{Float64}:...
Yeah I think you are right, I just found it surprising. I think ultimately what I wanted was a function that implemented `findblock(only(axes(r)), k)`, which I think is a more...
`findaxesblock` seems fine. I'm still not a huge fan of using the naming convention `find*` for this kind of operation, which is ultimately a conversion from a cartesian index to...
Sure, happy to make a PR with a basic implementation of `BlockIndices`.
@jishnub that seems like a reasonable rule, but to clarify do you think `blockedrange([2, 4])[2:4]` should output a `BlockedUnitRange` and `BlockArray(randn(4, 4), [2, 2], [2, 2])[2:4, 2:4]` should output a...
Responding to https://github.com/JuliaArrays/BlockArrays.jl/pull/356#issuecomment-2024751896. It seems like we could have both worlds, where the rule is that if you slice with a `UnitRange`, it picks up the blocking information based on...
That could be a good way to go. Then `@blocked blockedrange([3, 4])[2:5]` would be a convenient way to make `blockedrange(2, [2, 2])`, in the notation of #348. So `@blocked B[2:5,...