gather
Collect tall array into memory after executing queued operations
Syntax
Y = gather(X)
[y1,y2,y3,...] =收集(x1,x2,x3,...)
Description
executes all queued operations required to calculate unevaluated tall arrayY
= gather(X
)X
和collects the results into memory asY
.
MATLAB®can run out of memory if the result of thegather
计算太大。如果您不确定结果是否适合内存,请使用gather(head(X))
或者gather(tail(X))
要执行完整的计算,但仅将结果的一小部分带入内存。
Usegather
sparingly to ensure that extra passes through the data are combined during the calculations whenever possible. For more information, seeDeferred Evaluation of Tall Arrays.
Examples
Input Arguments
Output Arguments
Tips
If you have Parallel Computing Toolbox™, see
gather
有关聚会的信息distributed
和gpuArray
computations.
See Also
Introduced in R2016b
Was this topic helpful?