Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

TypeError: <lambda>() missing 1 required positional argument: 'k' #1

Closed
changleilei opened this issue Dec 2, 2021 · 1 comment
Closed

Comments

@changleilei
Copy link

Hello, when i use pytorch-lit prepare a model, got a TypeError as title. The detail as blow:

File "nlp/rct-FPM-rhino/big_model/prepare_model.py", line 16, in prepare_model
prepare_params(model, args.save_path, dtype='float32')
File "miniconda3/envs/rhino/lib/python3.8/site-packages/pytorch_lit/export.py", line 19, in prepare_params
_params_to_memmap(parameters, path.join(save_dir, "model.bin"),
File "miniconda3/envs/rhino/lib/python3.8/site-packages/pytorch_lit/export.py", line 52, in _params_to_memmap
param = get_param(k)
File "miniconda3/envs/rhino/lib/python3.8/site-packages/pytorch_lit/export.py", line 50, in
get_param = lambda key: params"get"
TypeError: () missing 1 required positional argument: 'k'

package list:

certifi 2021.10.8
numpy 1.21.4
pip 21.2.4
pytorch-lit 0.1.6
setuptools 58.0.4
torch 1.10.0
tqdm 4.62.3
typing_extensions 4.0.1
wheel 0.37.0

model: gpt-j-6B

Have any suggesstion? Thanks.

@AminRezaei0x443
Copy link
Owner

Hi,
There was a minor issue which is now fixed.
Try upgrading to 0.1.7.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants