Issue #1630 updated chunk size for single dimension chunks.
Amend: check if dataType is vlen_str_type. Change-Id: Idbd39e8bcd6c2703299277b073e14b106c897ccb Former-commit-id:a64625383f
[formerlyf8b4dcc541
] [formerly4c706901f8
] [formerlya64625383f
[formerlyf8b4dcc541
] [formerly4c706901f8
] [formerly691b9d7ca2
[formerly4c706901f8
[formerly 25bd6d76b85b3c857958f1fc5189f9512420daea]]]] Former-commit-id:691b9d7ca2
Former-commit-id:0e60e11fbb
[formerly1ce25acbc5
] [formerly e271a0ffc64b57ea2a58cefa0886aac6140d7847 [formerlyb9b660535c
]] Former-commit-id: 924c9a574fa423aa775d7cc7b2ce2a4a0861be6b [formerlyb8147737fe
] Former-commit-id:79b1560c07
This commit is contained in:
parent
6bbeb0d5d4
commit
91fb8318b4
1 changed files with 6 additions and 1 deletions
|
@ -214,7 +214,12 @@ class H5pyDataStore(IDataStore.IDataStore):
|
|||
|
||||
def __calculateChunk(self, nDims, dataType, storeOp, maxDims):
|
||||
if nDims == 1:
|
||||
chunk = [DEFAULT_CHUNK_SIZE]
|
||||
if dataType != vlen_str_type:
|
||||
sizeOfEntry = numpy.dtype(dataType).itemsize
|
||||
chunkSize = int(FILESYSTEM_BLOCK_SIZE / sizeOfEntry)
|
||||
chunk = [chunkSize]
|
||||
else:
|
||||
chunk = [DEFAULT_CHUNK_SIZE]
|
||||
elif nDims == 2:
|
||||
if storeOp != 'APPEND':
|
||||
chunk = [DEFAULT_CHUNK_SIZE] * 2
|
||||
|
|
Loading…
Add table
Reference in a new issue