Opened 6 years ago
Closed 5 years ago
#1985 closed enhancement (duplicate)
extend should support adding dimensions to an array
Reported by: | Dimitar Misev | Owned by: | |
---|---|---|---|
Priority: | major | Milestone: | 9.8 |
Component: | qlparser | Version: | 9.7 |
Keywords: | Cc: | Peter Baumann, Vlad Merticariu | |
Complexity: | Medium |
Description
It should be possible in some way to turn a 2D array into a 3D (i.e. opposite of slicing).
I think extend() is a good candidate for this, e.g. suppose A is array with sdom [0:100,0:100]
extend(A, [0, 0:100, 0:100])
results in a 3D array with sdom [0:0, 0:100, 0:100].
extend() does not support slices like subsetting so there's no danger of conflict with a slicing operation.
This will allow us to directly insert a 2D image into a 3D time-series for example. At the moment it's necessary to first initialize the object with some "dummy" single point and then do an update (which does support such placing of 2D in 3D.
Change History (3)
comment:1 by , 6 years ago
comment:2 by , 5 years ago
The main issue is with the aligned tiling. The result of that 1 pixel initialization is a 1x1x1 tile, along with 1 pixel wide/long tiles on the subsequent full update. See #480
comment:3 by , 5 years ago
Resolution: | → duplicate |
---|---|
Status: | new → closed |
I don't see what the issue is with the current approach, as the dummy value is replaced anyway.