This is machine translation

Translated by Microsoft
Mouseover text to see original. Click the button below to return to the English version of the page.

Note: This page has been translated by MathWorks. Click here to see
To view all translated materials including this page, select Country from the country navigator on the bottom of this page.


Return timing of storage space allocation


alloc_time = H5P.get_alloc_time(plist_id)


alloc_time = H5P.get_alloc_time(plist_id) retrieves the timing for storage space allocation from the dataset creation property list specified by plist_id. The alloc_time output can have any of the following values: H5D_ALLOC_TIME_DEFAULT, H5D_ALLOC_TIME_EARLY, H5D_ALLOC_TIME_INCR, or H5D_ALLOC_TIME_LATE.


fid ='example.h5');
dset_id =,'/g3/integer');
dcpl = H5D.get_create_plist(dset_id);
alloc_time = H5P.get_alloc_time(dcpl);
    case H5ML.get_constant_value('H5D_ALLOC_TIME_DEFAULT')
        fprintf('allocation time is default\n');
    case H5ML.get_constant_value('H5D_ALLOC_TIME_EARLY')
        fprintf('allocation time is dataset creation time\n');
    case H5ML.get_constant_value('H5D_ALLOC_TIME_INCR')
        fprintf('allocation time is incremental\n');
    case H5ML.get_constant_value('H5D_ALLOC_TIME_LATE')
        fprintf('allocation time is when data is first written\n');
Was this topic helpful?