@functools.lru_cache(maxsize=<NUM_LIT:5>)<EOL><INDENT>def _get_experiments(self):<DEDENT>
explist = []<EOL>with h5py.File(name=self.path, mode="<STR_LIT:r>") as h5:<EOL><INDENT>if "<STR_LIT>" not in h5:<EOL><INDENT>msg = "<STR_LIT>".format(self.path)<EOL>raise HyperSpyNoDataFoundError(msg)<EOL><DEDENT>for name in h5["<STR_LIT>"]:<EOL><INDENT>if self._check_experiment(name):<EOL><INDENT>explist.append(name)<EOL><DEDENT><DEDENT><DEDENT>explist.sort()<EOL>if not explist:<EOL><INDENT>msg = "<STR_LIT>".format(self.path)<EOL>raise HyperSpyNoDataFoundError(msg)<EOL><DEDENT>return explist<EOL>
Get all experiments from the hdf5 file