Skip to content

Commit

Permalink
fix cp import logic
Browse files Browse the repository at this point in the history
  • Loading branch information
TorchDSP committed Feb 6, 2023
1 parent 8d7ea1a commit 87d357e
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 1 deletion.
3 changes: 2 additions & 1 deletion torchsig/datasets/synthetic.py
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,7 @@
try:
import cusignal
import cupy as xp
import cupy as cp
CUSIGNAL = True
CUPY = True
except ImportError:
Expand Down Expand Up @@ -738,7 +739,7 @@ def _generate_samples(self, item: Tuple) -> np.ndarray:

symbols = const_oversampled[symbol_nums]
symbols_repeat = xp.repeat(symbols, samples_per_symbol_recalculated)
symbols_repeat = xp.insert(symbols_repeat,0,0) # start at zero phase
symbols_repeat = np.insert(symbols_repeat,0,0) # start at zero phase

filtered = symbols_repeat
if "g" in const_name:
Expand Down
1 change: 1 addition & 0 deletions torchsig/datasets/wideband.py
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,7 @@
try:
import cusignal
import cupy as xp
import cupy as cp
CUSIGNAL = True
CUPY = True
except ImportError:
Expand Down

0 comments on commit 87d357e

Please sign in to comment.