File tree Expand file tree Collapse file tree 2 files changed +4
-0
lines changed
PaddleNLP/emotion_detection Expand file tree Collapse file tree 2 files changed +4
-0
lines changed Original file line number Diff line number Diff line change 18
18
import numpy as np
19
19
20
20
from models .classification import nets
21
+ from models .model_check import check_cuda
21
22
import reader
22
23
import config
23
24
import utils
@@ -374,4 +375,5 @@ def get_cards():
374
375
375
376
if __name__ == "__main__" :
376
377
utils .print_arguments (args )
378
+ check_cuda (args .use_cuda )
377
379
main (args )
Original file line number Diff line number Diff line change 19
19
20
20
from preprocess .ernie import task_reader
21
21
from models .representation import ernie
22
+ from models .model_check import check_cuda
22
23
import utils
23
24
24
25
# yapf: disable
@@ -384,4 +385,5 @@ def main(args):
384
385
385
386
if __name__ == "__main__" :
386
387
utils .print_arguments (args )
388
+ check_cuda (args .use_cuda )
387
389
main (args )
You can’t perform that action at this time.
0 commit comments