max
max copied to clipboard
[Modular CLI]: max/examples/inference/bert-python-torchscript
Issue description
I installed Max to learn max.
I'm attempting to run max/examples/inference/bert-python-torchscript/bash run,sh. I get the following error after updating settings with max, and pyramid_beaker:
File "/hpome/sam/.local/lib/python3,10/site-packages/max/debug.py" line 4
def patched_checkToken(url, username,token,scope, False):
^^^^^
SyntaxError: invalid syntax
Steps to reproduce
- Include relevant code snippet that did not work as expected.
- If applicable, add screenshots to help explain the problem.
- Include anything else that might help us debug the issue. sam@rudi2:~/max/examples/inference/bert-python-torchscript$ bash run.sh
-
INPUT_EXAMPLE='Paris is the [MASK] of France.'
-
MODEL_PATH=../../models/bert-mlm.torchscript ++ dirname run.sh
-
cd .
-
python3 ../common/bert-torchscript/download-model.py -o ../../models/bert-mlm.torchscript --mlm Downloading model... /home/sam/.local/lib/python3.10/site-packages/huggingface_hub/file_download.py:1132: FutureWarning:
resume_downloadis deprecated and will be removed in version 1.0.0. Downloads always resume when possible. If you want to force a new download, useforce_download=True. warnings.warn( Saving model in TorchScript format... '../../models/bert-mlm.torchscript' already exists. -
python3 simple-inference.py --text 'Paris is the [MASK] of France.' --model-path ../../models/bert-mlm.torchscript Traceback (most recent call last): File "/home/sam/max/examples/inference/bert-python-torchscript/simple-inference.py", line 14, in
from max import engine File "/home/sam/.local/lib/python3.10/site-packages/max/init.py", line 20, in from max import debug File "/home/sam/.local/lib/python3.10/site-packages/max/debug.py", line 4 def patched_checkToken(url, username, token, scope, False): ^^^^^ SyntaxError: invalid syntax
Version Info
- Provide Modular CLI version by pasting the output of `modular -v`
- What OS did you install modular CLI on ?
sam@rudi2:~/max/examples/inference/bert-python-torchscript$ modular -v
modular 0.8.0 (39a426b5)
Ubuntu 22.04 LTS