- Newest
- Most votes
- Most comments
The ModuleNotFoundError you're encountering suggests that Python can't find the 'utils' module in your current environment. Since that there isn't a top-level Python package called 'utils', you might want to make sure that 'utils' is a package in your current directory or Python path.
If you are trying to use the draw_pulse_sequence module from the utils directory (https://github.com/amazon-braket/amazon-braket-examples/tree/main/examples/pulse_control/utils) of the braket example repo, you need this utils folder (and it's content) in the same folder as your notebook. The simplest solution is to clone the examples repo with git clone git@github.com:amazon-braket/amazon-braket-examples.git, and create your notebook in the pulse_control (https://github.com/amazon-braket/amazon-braket-examples/tree/main/examples/pulse_control) folder
answered 2 years ago
Hello,
are you referencing the module correctly ? Can you post your code please ?
Are you using the latest version of the library ? https://github.com/amazon-braket/amazon-braket-sdk-python/tree/main
Relevant content
asked 2 years ago
- AWS OFFICIALUpdated a year ago
- AWS OFFICIALUpdated 3 years ago

%matplotlib inline
from braket.aws import AwsDevice from braket.devices import Devices from braket.parametric import FreeParameter from braket.pulse import PulseSequence from braket.circuits import Circuit, GateCalibrations, QubitSet from braket.circuits.gates import Rx, Rz, CZ from braket.circuits.serialization import IRType
import math from utils.draw_pulse_sequence import draw import matplotlib.pyplot as plt
Following is the error:
ModuleNotFoundError Traceback (most recent call last) Cell In[112], line 12 9 from braket.circuits.serialization import IRType 11 import math ---> 12 from utils.draw_pulse_sequence import draw 13 import matplotlib.pyplot as plt
ModuleNotFoundError: No module named 'utils'