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

issue on mil_model.py #9

Open
sssingh21 opened this issue Nov 24, 2022 · 0 comments
Open

issue on mil_model.py #9

sssingh21 opened this issue Nov 24, 2022 · 0 comments

Comments

@sssingh21
Copy link

'
File "/opt/sss/AceSum-main/src/mil_model.py", line 22, in init
self.word_linear = nn.Linear(args.model_dim, args.num_aspects, bias=False)
AttributeError: 'Namespace' object has no attribute 'model_dim'
'

And I do see that model_dim is not added to args anywhere. Traceback

'
Traceback (most recent call last):
File "src/create_sum_data.py", line 521, in
create_train_data(args)
File "src/create_sum_data.py", line 55, in create_train_data
model, tokenizer = prepare_model(args)
File "src/create_sum_data.py", line 26, in prepare_model
model = MIL(args)
File "/opt/sss/AceSum-main/src/mil_model.py", line 22, in init
self.word_linear = nn.Linear(args.model_dim, args.num_aspects, bias=False)
AttributeError: 'Namespace' object has no attribute 'model_dim'
'

And in create sum data, following attributes are being added:
'
if name == 'main':
parser = argparse.ArgumentParser()

parser.add_argument('-mode', default='train', type=str)

parser.add_argument('-dataset', default='space', type=str)
parser.add_argument('-num_aspects', default=6, type=int)

parser.add_argument('-load_model', default=None, type=str)
parser.add_argument('-model_type', default='distilroberta-base', type=str)

args = parser.parse_args()
'

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

1 participant