Skip to content

Commit

Permalink
try caching data loading
Browse files Browse the repository at this point in the history
  • Loading branch information
rgommers committed Feb 21, 2024
1 parent 4d85828 commit 0c71484
Showing 1 changed file with 6 additions and 0 deletions.
6 changes: 6 additions & 0 deletions pywt/data/_readers.py
Original file line number Diff line number Diff line change
@@ -1,9 +1,11 @@
import functools
import importlib
import os

import numpy as np


@functools.cache
def ascent():
"""
Get an 8-bit grayscale bit-depth, 512 x 512 derived image for
Expand Down Expand Up @@ -44,6 +46,7 @@ def ascent():
return ascent


@functools.cache
def aero():
"""
Get an 8-bit grayscale bit-depth, 512 x 512 derived image for
Expand Down Expand Up @@ -81,6 +84,7 @@ def aero():
return aero


@functools.cache
def camera():
"""
Get an 8-bit grayscale bit-depth, 512 x 512 derived image for
Expand Down Expand Up @@ -129,6 +133,7 @@ def camera():
return camera


@functools.cache
def ecg():
"""
Get 1024 points of an ECG timeseries.
Expand Down Expand Up @@ -161,6 +166,7 @@ def ecg():
return ecg


@functools.cache
def nino():
"""
This data contains the averaged monthly sea surface temperature in degrees
Expand Down

0 comments on commit 0c71484

Please sign in to comment.