Skip to content
This repository has been archived by the owner on Dec 15, 2023. It is now read-only.

Commit

Permalink
make hickle optional
Browse files Browse the repository at this point in the history
  • Loading branch information
eendebakpt committed Oct 27, 2021
1 parent 17fbf28 commit 8ed9f2c
Show file tree
Hide file tree
Showing 2 changed files with 10 additions and 5 deletions.
5 changes: 3 additions & 2 deletions setup.py
Original file line number Diff line number Diff line change
Expand Up @@ -35,7 +35,7 @@ def get_package_data(root_dir):
tests_require = ['coverage', 'jupyter', 'mypy', 'types-redis', 'types-python-dateutil', 'pytest']

install_requires = [
'apscheduler', 'attrs', 'dulwich', 'h5py', 'hickle', 'IPython>=0.1', 'jupyter', 'lmfit', 'matplotlib>=3.0',
'apscheduler', 'attrs', 'dulwich', 'h5py', 'IPython>=0.1', 'jupyter', 'lmfit', 'matplotlib>=3.0',
'numdifftools', 'numpy>=1.15', 'opencv-python', 'PyQt5', 'pyqtgraph', 'pyvisa', 'pyzmqrpc', 'qcodes>=0.23.0',
'qcodes-contrib-drivers', 'qilib', 'qtpy', 'qupulse', 'redis', 'scipy', 'scikit-image',
'shapely', 'sympy'
Expand All @@ -45,7 +45,7 @@ def get_package_data(root_dir):
install_requires.append('pywin32')

rtd_requires = [
'sphinx>=1.7', 'sphinx_rtd_theme', 'nbsphinx', 'sphinx-automodapi','sphinx_copybutton'
'sphinx>=1.7', 'sphinx_rtd_theme', 'nbsphinx', 'sphinx-automodapi', 'sphinx_copybutton'
]

extras_require = {"rtd": rtd_requires}
Expand All @@ -67,6 +67,7 @@ def get_package_data(root_dir):
'Programming Language :: Python :: 3',
'Programming Language :: Python :: 3.7',
'Programming Language :: Python :: 3.8',
'Programming Language :: Python :: 3.9',
'Topic :: Scientific/Engineering'
],
license='MIT',
Expand Down
10 changes: 7 additions & 3 deletions src/qtt/data.py
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,7 @@ def load_example_dataset(filename: str, verbose: int = 0) -> Optional[DataSet]:
Returns:
Example dataset or None of no dataset can be found
"""
exampledatadir = os.path.join(qtt.__path__[0], 'exampledata') # type: ignore # mypy issue #1422
exampledatadir = os.path.join(qtt.__path__[0], 'exampledata') # type: ignore # mypy issue #1422

dataset = qtt.data.load_dataset(os.path.join(exampledatadir, filename), verbose=verbose)
return dataset
Expand Down Expand Up @@ -165,8 +165,12 @@ def load_dataset(location, io=None, verbose=0):
formatters = [DataSet.default_formatter]

from qcodes.data.hdf5_format import HDF5FormatMetadata
from qcodes.data.hdf5_format_hickle import HDF5FormatHickle
formatters += [HDF5FormatHickle(), HDF5FormatMetadata()]
formatters += [HDF5FormatMetadata()]
try:
from qcodes.data.hdf5_format_hickle import HDF5FormatHickle
formatters += [HDF5FormatHickle()]
except ImportError:
logging.info('hickle not available')

from qcodes.data.hdf5_format import HDF5Format
formatters += [HDF5Format()]
Expand Down

0 comments on commit 8ed9f2c

Please sign in to comment.