rhdf5 icon indicating copy to clipboard operation
rhdf5 copied to clipboard

Error creating a dataset with chunks of size 1

Open grimbough opened this issue 5 years ago • 1 comments

It's not really sensible to allow singleton chunks, but users on the SIB advanced single-cell RNA course found it was crashing. This should be looked into.

grimbough avatar May 29 '20 13:05 grimbough

This causes a memory explosion, which is probably why the students saw R crash:

n <- 2048*200*6
fullImg <- array(runif(n), dim = c(2048, 200, 6))
myfile <- "/tmp/myhdf5file.h5"
if(file.exists(myfile)) { file.remove(myfile) }
h5createFile(myfile)
h5createDataset(myfile, "test", dim(fullImg), storage.mode = "double", chunk = c(1,1, 1))
h5write(fullImg, myfile, name="test")

grimbough avatar Jun 08 '20 12:06 grimbough