[Python] ValueError when I run in different computer [closed]

Discussão em 'Python' iniciado por Stack, Outubro 5, 2024.

  1. Stack

    Stack Membro Participativo

    This error happened when I use my own computer to run but I've tried the same program on other computers and there are no eerors.I don't understand whats the problem. ValueError: too many values to unpack (expected 2)

    This is the code that occured the error :

    for train_input, train_label in tqdm(train_dataloader):
    train_label = train_label.to(device)
    mask = train_input['attention_mask'].to(device)
    input_id = train_input['input_ids'].squeeze(1).to(device)
    output = model(input_id, mask) #<-This is the code that happened error

    Continue reading...

Compartilhe esta Página