Skip to content
GitLab
Explore
Projects
Groups
Topics
Snippets
Projects
Groups
Topics
Snippets
/
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Menu
proekt
obuch
Commits
1a49ab7b
Commit
1a49ab7b
authored
2 weeks ago
by
Мазур Грета Евгеньевна
Browse files
Options
Download
Patches
Plain Diff
micro zapusk no cross
parent
1fbe726d
master
No related merge requests found
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
.ipynb_checkpoints/checkLora-checkpoint.py
+3
-0
.ipynb_checkpoints/checkLora-checkpoint.py
checkLora.py
+3
-0
checkLora.py
with
6 additions
and
0 deletions
+6
-0
.ipynb_checkpoints/checkLora-checkpoint.py
+
3
−
0
View file @
1a49ab7b
...
...
@@ -314,9 +314,12 @@ tokenizer = BertTokenizer.from_pretrained("./micro_no_cross_fine_tuned2")
base_model
=
MultiTaskBert
.
from_pretrained
(
'bert-base-uncased'
).
to
(
device
)
print
(
"Загружена базовая"
)
model
=
PeftModel
.
from_pretrained
(
base_model
,
"./micro_no_cross_fine_tuned/lora2"
,
strict
=
False
)
print
(
"Загружена с лора"
)
# Переводим модель в режим оценки
model
.
eval
()
...
...
This diff is collapsed.
Click to expand it.
checkLora.py
+
3
−
0
View file @
1a49ab7b
...
...
@@ -314,9 +314,12 @@ tokenizer = BertTokenizer.from_pretrained("./micro_no_cross_fine_tuned2")
base_model
=
MultiTaskBert
.
from_pretrained
(
'bert-base-uncased'
).
to
(
device
)
print
(
"Загружена базовая"
)
model
=
PeftModel
.
from_pretrained
(
base_model
,
"./micro_no_cross_fine_tuned/lora2"
,
strict
=
False
)
print
(
"Загружена с лора"
)
# Переводим модель в режим оценки
model
.
eval
()
...
...
This diff is collapsed.
Click to expand it.
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment
Menu
Explore
Projects
Groups
Topics
Snippets