Skip to content

Commit

Permalink
adding message to be optional
Browse files Browse the repository at this point in the history
  • Loading branch information
alex-rakowski committed Dec 12, 2023
1 parent 7639f25 commit 62107ea
Showing 1 changed file with 3 additions and 5 deletions.
8 changes: 3 additions & 5 deletions pylops/utils/deps.py
Original file line number Diff line number Diff line change
Expand Up @@ -15,9 +15,7 @@

# from importlib import import_module
from importlib import util

# from typing import Optional

from typing import Optional

# def check_module_enabled(
# module: str,
Expand Down Expand Up @@ -187,7 +185,7 @@ def sympy_import(message):
return sympy_message


def cupy_import(message):
def cupy_import(message: Optional[str] = None):
# detect if cupy should be importable
cupy_test = (
util.find_spec("cupy") is not None and int(os.getenv("CUPY_PYLOPS", 1)) == 1
Expand Down Expand Up @@ -221,7 +219,7 @@ def cupy_import(message):
return cupy_message


def cusignal_import(message):
def cusignal_import(message: Optional[str] = None):
# detect if cupy should be importable
cusignal_test = (
util.find_spec("cusignal") is not None
Expand Down

0 comments on commit 62107ea

Please sign in to comment.