-
Notifications
You must be signed in to change notification settings - Fork 6
Description
Hi,
First off, fantastic utility and much appreciated. Makes handling my 5-10GB data sets so much easier than the rather clunky and slow Matlab native memmapfile. I am using the MappedTensor version from Matlab File Exchange. I have a particular use case wherein I permute my tensor, and then attempt to populate with some values. Simple example:
mt = MappedTensor(100,200,10);
mt = permute(mt,[3,1,2]);
[nr,nc,nf] = size(mt);
mt(:,:,1) = randn(nr,nc);
This gives the following error ...
Error using mapped_tensor_shim
*** mapped_tensor_shim: In an assignment A(I) = B, the number of elements in B and I must be the
same.
Error in MappedTensor>mt_write_data (line 1837)
hShimFunc('write_chunks', hDataFile, mnFileChunkIndices, vnUniqueDataIndices, vnDataSize, strClass, nHeaderBytes, cast(tData, strClass), double(bBigEndian));
Error in indexing (line 598)
mt_write_data(mtVar.hShimFunc, mtVar.hRealContent, S, mtVar.vnOriginalSize, mtVar.strStorageClass, mtVar.nHeaderBytes, tfData, mtVar.bBigEndian, mtVar.hRepSumFunc, mtVar.hChunkLengthFunc);
Should I be accessing the permuted tensor differently? Any help would be appreciated.
Cheers,
Robert