Skip to content
GitLab
Menu
Projects
Groups
Snippets
/
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Menu
Open sidebar
Gaëtan Caillaut
hatespeech
Commits
985bed5a
Commit
985bed5a
authored
Jun 09, 2021
by
Gaëtan Caillaut
Browse files
suppression du device passé à HateSpeechCollater
parent
d426d9a2
Changes
1
Hide whitespace changes
Inline
Side-by-side
train_roberta.py
View file @
985bed5a
...
...
@@ -19,7 +19,7 @@ if __name__ == "__main__":
tokenizer
=
RobertaTokenizerFast
.
from_pretrained
(
'roberta-base'
)
dataset
=
HateSpeechDataset
(
args
.
input
)
collater
=
HateSpeechCollater
(
tokenizer
,
device
)
collater
=
HateSpeechCollater
(
tokenizer
)
class_names
=
collater
.
class_names
()
for
fold
,
(
train
,
test
)
in
enumerate
(
dataset
.
iter_folds
(
args
.
folds
,
True
),
1
):
...
...
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment