bugGNU Octave - Bugs: bug #56148, Document that load() only works...

 
 

bug #56148: Document that load() only works with HDF5 files created by Octave itself

Submitter:  Grey Christoforo <greyltc>
Submitted:  Wed 17 Apr 2019 03:00:37 PM UTC
   
 
Category:  Documentation Severity:  3 - Normal
Priority:  5 - Normal Item Group:  Documentation
Status:  Fixed Assigned to:  None
Originator Name:  Open/Closed:  * Closed
Release:  * 5.1.0 Operating System:  * GNU/Linux
Fixed Release:  None Planned Release:  None
* Mandatory Fields

Add a New Comment Rich Markup
   

Wed 24 Apr 2019 04:25:31 AM UTC, comment #4: 

I documented the fact that Octave can only read HDF5 files created by itself here (https://hg.savannah.gnu.org/hgweb/octave/rev/ad77f3204eda)

Rik <rik5>
Group administrator
Wed 17 Apr 2019 04:22:22 PM UTC, comment #3: 

The bug's in the documentation then. From page 262 of the 5.1.0 .pdf manual:

"Note that Octave can read hdf5 files not created by itself, but may skip some datasets in formats that it cannot support. This format is only available if Octave was built with a link to the hdf5 libraries."

Grey Christoforo <greyltc>
Wed 17 Apr 2019 04:15:13 PM UTC, comment #2: 

Octave's load command is only able to load hdf5 files that it writes when saving with the hdf5 option.  It is not designed to load arbitrary hdf5 files.

John W. Eaton <jwe>
Group administrator
Wed 17 Apr 2019 03:11:42 PM UTC, comment #1: 

Matlab seems to be able to interpret this file fine.
In case it helps, here is what matlab gives for h5disp("example.h5"):

Group '/'
    Attributes:
        'Operator':  'grey'
        'Timestamp':  1555509928.273387
        'PCB Firmware Hash':  '3b583b6'
        'Control Software Revision':  'v1.1.3'
        'Format Revision':  '1.8.1'
        'Run Description':  'software dev'
        'Sourcemeter':  'KEITHLEY INSTRUMENTS INC.,MODEL 2400,1226045,C34 Sep 21 2016 15:30:00/A02  /K/J'
        'Diode 1 intensity [ADC counts]':  14610
        'Diode 2 intensity [ADC counts]':  13100
        'Diode 1 calibration [ADC counts]':  13280
        'Diode 2 calibration [ADC counts]':  12953
        'Diode 1 intensity [suns]':  1.100151
        'Diode 2 intensity [suns]':  1.011349
    Group '/A'
        Attributes:
            'Sample Unique Identifier':  ''
            'Sample Adapter Board Resistor Value':  0
            'Sample Layout Name':  '8x BPW34'
            'User_thickness':  '1.2m'
            'User_hair color':  'turquoise'
        Group '/A/3'
            Attributes:
                'area':  0.000008
                'Voc':  -0.246205
                'Isc':  0.000004
                'Vmpp':  -0.190956
                'Impp':  0.000004
                'ssPmax':  0.000001
            Dataset 'all_measurements'
                Size:  891
                MaxSize:  891
                Datatype:   H5T_COMPOUND
                    Member 'voltage':  H5T_IEEE_F32LE (single)
                    Member 'current':  H5T_IEEE_F32LE (single)
                    Member 'time':  H5T_IEEE_F32LE (single)
                    Member 'status':  H5T_STD_U32LE (uint32)
                ChunkSize:  446
                Filters:  deflate(4)
                Attributes:
                    'V_oc dwell':  'H5T_REFERENCE'
                    'Sweep':  'H5T_REFERENCE'
                    'I_sc dwell':  'H5T_REFERENCE'
                    'Snaith':  'H5T_REFERENCE'
                    'MPPT':  'H5T_REFERENCE'
            Dataset 'status_list'
                Size:  5
                MaxSize:  5
                Datatype:   H5T_COMPOUND
                    Member 'index':  H5T_STD_U32LE (uint32)
                    Member 'message':  H5T_STRING
                        String Length: variable
                        Padding: H5T_STR_NULLTERM
                        Character Set: H5T_CSET_UTF8
                        Character Type: H5T_C_S1
                ChunkSize:  5
                Filters:  deflate(4)
        Group '/A/4'
            Attributes:
                'area':  0.000008
                'Voc':  0.250181
                'Isc':  -0.000005
                'Vmpp':  0.188952
                'Impp':  -0.000004
                'ssPmax':  0.000001
            Dataset 'all_measurements'
                Size:  901
                MaxSize:  901
                Datatype:   H5T_COMPOUND
                    Member 'voltage':  H5T_IEEE_F32LE (single)
                    Member 'current':  H5T_IEEE_F32LE (single)
                    Member 'time':  H5T_IEEE_F32LE (single)
                    Member 'status':  H5T_STD_U32LE (uint32)
                ChunkSize:  451
                Filters:  deflate(4)
                Attributes:
                    'V_oc dwell':  'H5T_REFERENCE'
                    'Sweep':  'H5T_REFERENCE'
                    'I_sc dwell':  'H5T_REFERENCE'
                    'Snaith':  'H5T_REFERENCE'
                    'MPPT':  'H5T_REFERENCE'
            Dataset 'status_list'
                Size:  5
                MaxSize:  5
                Datatype:   H5T_COMPOUND
                    Member 'index':  H5T_STD_U32LE (uint32)
                    Member 'message':  H5T_STRING
                        String Length: variable
                        Padding: H5T_STR_NULLTERM
                        Character Set: H5T_CSET_UTF8
                        Character Type: H5T_C_S1
                ChunkSize:  5
                Filters:  deflate(4)


Grey Christoforo <greyltc>
Wed 17 Apr 2019 03:00:37 PM UTC, original submission:  

I have a script like this:

data = load("example.h5")


Which fails to run with the following output in my command window:

error: load: error while reading hdf5 item all_measurements


I expect octave
(A) to support loading every bit of data from valid hdf5 files
and
(B) to gracefully skip pieces of hdf5 files it does not understand

I've attached the file I've tried to load here.

Grey Christoforo <greyltc>

 

(Note: upload size limit is set to 16384 kB, after insertion of the required escape characters.)

Attach Files:
   
   
Comment:
   

Attached Files
file #46784:  example.h5 added by greyltc (36KiB - application/x-hdf)

 

Depends on the following items: None found

Items that depend on this one: None found

 

Carbon-Copy List
  • -email is unavailable- added by rik5 (Posted a comment)
  • -email is unavailable- added by jwe (Posted a comment)
  • -email is unavailable- added by greyltc (Submitted the item)
  •  

    There are 0 votes so far. Votes easily highlight which items people would like to see resolved in priority, independently of the priority of the item set by tracker managers.

    Only group members can vote.

     

    Follow 6 latest changes.

    Date Changed by Updated Field Previous Value => Replaced by
    2019-04-24 rik5 CategoryOctave Function Documentation
        Item GroupUnexpected Error or Warning Documentation
        StatusNone Fixed
        Open/ClosedOpen Closed
        Summaryerror importing hdf5 file Document that load() only works with HDF5 files created by Octave itself
    2019-04-17 greyltc Attached File- Added example.h5, #46784

    Back to the top

    Powered by Savane 3.13-758e.
    Corresponding source code