Kevin Fink
commited on
Commit
·
283af96
1
Parent(s):
c29bf98
dev
Browse files- app.py +2 -2
- gradio-3.wpu +78 -57
app.py
CHANGED
@@ -250,8 +250,8 @@ def fine_tune_model(model, dataset_name, hub_id, api_key, num_epochs, batch_size
|
|
250 |
|
251 |
for check in previous_checkpoints:
|
252 |
try:
|
253 |
-
|
254 |
-
|
255 |
train_result = trainer.train(resume_from_checkpoint=True)
|
256 |
trainer.push_to_hub(commit_message="Training complete!")
|
257 |
return 'DONE!'#train_result
|
|
|
250 |
|
251 |
for check in previous_checkpoints:
|
252 |
try:
|
253 |
+
print(f"Removing previous checkpoint {check}")
|
254 |
+
os.remove(os.path.join('/data/results', check))
|
255 |
train_result = trainer.train(resume_from_checkpoint=True)
|
256 |
trainer.push_to_hub(commit_message="Training complete!")
|
257 |
return 'DONE!'#train_result
|
gradio-3.wpu
CHANGED
@@ -458,51 +458,15 @@ guimgr.overall-gui-state = {'windowing-policy': 'combined-window',
|
|
458 |
'primary_view_state': {'editor_states': ({'bookmarks': ([[loc('app.py'),
|
459 |
{'attrib-starts': [('fine_tune_model|0|',
|
460 |
30)],
|
461 |
-
'code-line': "
|
462 |
-
'first-line':
|
463 |
'folded-linenos': [],
|
464 |
-
'sel-line':
|
465 |
-
'sel-line-start':
|
466 |
-
'selection_end':
|
467 |
-
'selection_start':
|
468 |
'zoom': 0},
|
469 |
-
|
470 |
-
[loc('app.py'),
|
471 |
-
{'attrib-starts': [('fine_tune_model|0|',
|
472 |
-
30)],
|
473 |
-
'code-line': " output_dir='/data/results',\n",
|
474 |
-
'first-line': 224,
|
475 |
-
'folded-linenos': [],
|
476 |
-
'sel-line': 72,
|
477 |
-
'sel-line-start': 2869,
|
478 |
-
'selection_end': 2869,
|
479 |
-
'selection_start': 2869,
|
480 |
-
'zoom': 0},
|
481 |
-
1733819898.7307088],
|
482 |
-
[loc('app.py'),
|
483 |
-
{'attrib-starts': [('fine_tune_model|0|',
|
484 |
-
30)],
|
485 |
-
'code-line': ' logging_steps=100,\n',
|
486 |
-
'first-line': 81,
|
487 |
-
'folded-linenos': [],
|
488 |
-
'sel-line': 84,
|
489 |
-
'sel-line-start': 3389,
|
490 |
-
'selection_end': 3418,
|
491 |
-
'selection_start': 3418,
|
492 |
-
'zoom': 0},
|
493 |
-
1733819967.3641207],
|
494 |
-
[loc('app.py'),
|
495 |
-
{'attrib-starts': [('fine_tune_model|0|',
|
496 |
-
30)],
|
497 |
-
'code-line': " print(os.listdir('/data/results'))\n",
|
498 |
-
'first-line': 228,
|
499 |
-
'folded-linenos': [],
|
500 |
-
'sel-line': 234,
|
501 |
-
'sel-line-start': 10995,
|
502 |
-
'selection_end': 11045,
|
503 |
-
'selection_start': 11045,
|
504 |
-
'zoom': 0},
|
505 |
-
1733820110.295894],
|
506 |
[loc('app.py'),
|
507 |
{'attrib-starts': [('fine_tune_model|0|',
|
508 |
30)],
|
@@ -692,23 +656,70 @@ guimgr.overall-gui-state = {'windowing-policy': 'combined-window',
|
|
692 |
'selection_end': 10605,
|
693 |
'selection_start': 10605,
|
694 |
'zoom': 0},
|
695 |
-
1733883833.4841597]
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
696 |
20),
|
697 |
'current-loc': loc('selenium_click.py'),
|
698 |
-
'editor-state-list': [(loc('
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
699 |
{'attrib-starts': [],
|
700 |
-
'code-line':
|
701 |
-
'first-line':
|
702 |
'folded-linenos': [],
|
703 |
-
'sel-line':
|
704 |
-
'sel-line-start':
|
705 |
-
'selection_end':
|
706 |
-
'selection_start':
|
707 |
'zoom': 0})],
|
708 |
-
'has-focus':
|
709 |
'locked': False},
|
710 |
-
[loc('
|
711 |
-
|
|
|
|
|
712 |
'saved_notebook_display': None,
|
713 |
'split_percents': {0: 0.4410585404971933,
|
714 |
1: 0.5,
|
@@ -717,7 +728,7 @@ guimgr.overall-gui-state = {'windowing-policy': 'combined-window',
|
|
717 |
'tab_location': 'top',
|
718 |
'traversal_pos': ((1,
|
719 |
1),
|
720 |
-
|
721 |
'user_data': {}},
|
722 |
'saved_notebook_display': None,
|
723 |
'split_percents': {0: 0.49743589743589745},
|
@@ -725,13 +736,14 @@ guimgr.overall-gui-state = {'windowing-policy': 'combined-window',
|
|
725 |
'tab_location': 'left',
|
726 |
'traversal_pos': ((1,
|
727 |
0),
|
728 |
-
|
729 |
'user_data': {}},
|
730 |
'window-alloc': (0,
|
731 |
0,
|
732 |
1920,
|
733 |
793)}]}
|
734 |
-
guimgr.recent-documents = [loc('selenium_click.py')
|
|
|
735 |
guimgr.visual-state = {loc('../../envs/gradio-3/lib/python3.12/site-packages/selenium/webdriver/remote/errorhandler.py'): {'attrib-starts': [('ErrorHandler|0|',
|
736 |
140),
|
737 |
('ErrorHandler|0|.check_response|0|',
|
@@ -764,6 +776,15 @@ guimgr.visual-state = {loc('../../envs/gradio-3/lib/python3.12/site-packages/sel
|
|
764 |
'sel-line-start': 0,
|
765 |
'selection_end': 537,
|
766 |
'selection_start': 0,
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
767 |
'zoom': 0}}
|
768 |
proj.pyexec = {None: ('custom',
|
769 |
'/home/kevin/envs/gradio-3/bin/python3')}
|
|
|
458 |
'primary_view_state': {'editor_states': ({'bookmarks': ([[loc('app.py'),
|
459 |
{'attrib-starts': [('fine_tune_model|0|',
|
460 |
30)],
|
461 |
+
'code-line': " print(os.listdir('/data/results'))\n",
|
462 |
+
'first-line': 228,
|
463 |
'folded-linenos': [],
|
464 |
+
'sel-line': 234,
|
465 |
+
'sel-line-start': 10995,
|
466 |
+
'selection_end': 11045,
|
467 |
+
'selection_start': 11045,
|
468 |
'zoom': 0},
|
469 |
+
1733820110.295894],
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
470 |
[loc('app.py'),
|
471 |
{'attrib-starts': [('fine_tune_model|0|',
|
472 |
30)],
|
|
|
656 |
'selection_end': 10605,
|
657 |
'selection_start': 10605,
|
658 |
'zoom': 0},
|
659 |
+
1733883833.4841597],
|
660 |
+
[loc('selenium_click.py'),
|
661 |
+
{'attrib-starts': [],
|
662 |
+
'code-line': " text_areas = driver.find_elements(By.TAG_NAME, 'textarea')\n",
|
663 |
+
'first-line': 11,
|
664 |
+
'folded-linenos': [],
|
665 |
+
'sel-line': 21,
|
666 |
+
'sel-line-start': 771,
|
667 |
+
'selection_end': 833,
|
668 |
+
'selection_start': 833,
|
669 |
+
'zoom': 0},
|
670 |
+
1733883947.2524962],
|
671 |
+
[loc('app.py'),
|
672 |
+
{'attrib-starts': [],
|
673 |
+
'code-line': 'import spaces\n',
|
674 |
+
'first-line': 0,
|
675 |
+
'folded-linenos': [],
|
676 |
+
'sel-line': 0,
|
677 |
+
'sel-line-start': 0,
|
678 |
+
'selection_end': 0,
|
679 |
+
'selection_start': 0,
|
680 |
+
'zoom': 0},
|
681 |
+
1733883957.4314425],
|
682 |
+
[loc('app.py'),
|
683 |
+
{'attrib-starts': [('fine_tune_model|0|',
|
684 |
+
30)],
|
685 |
+
'code-line': " os.remove(os.path.join('/data/results', check))\n",
|
686 |
+
'first-line': 240,
|
687 |
+
'folded-linenos': [],
|
688 |
+
'sel-line': 252,
|
689 |
+
'sel-line-start': 11667,
|
690 |
+
'selection_end': 11734,
|
691 |
+
'selection_start': 11734,
|
692 |
+
'zoom': 0},
|
693 |
+
1733884182.266322]],
|
694 |
20),
|
695 |
'current-loc': loc('selenium_click.py'),
|
696 |
+
'editor-state-list': [(loc('app.py'),
|
697 |
+
{'attrib-starts': [('fine_tune_model|0|',
|
698 |
+
30)],
|
699 |
+
'code-line': " os.remove(os.path.join('/data/results', check))\n",
|
700 |
+
'first-line': 240,
|
701 |
+
'folded-linenos': [],
|
702 |
+
'sel-line': 252,
|
703 |
+
'sel-line-start': 11667,
|
704 |
+
'selection_end': 11734,
|
705 |
+
'selection_start': 11734,
|
706 |
+
'zoom': 0}),
|
707 |
+
(loc('selenium_click.py'),
|
708 |
{'attrib-starts': [],
|
709 |
+
'code-line': ' \n',
|
710 |
+
'first-line': 9,
|
711 |
'folded-linenos': [],
|
712 |
+
'sel-line': 23,
|
713 |
+
'sel-line-start': 835,
|
714 |
+
'selection_end': 835,
|
715 |
+
'selection_start': 835,
|
716 |
'zoom': 0})],
|
717 |
+
'has-focus': False,
|
718 |
'locked': False},
|
719 |
+
[loc('app.py'),
|
720 |
+
loc('selenium_click.py')]),
|
721 |
+
'open_files': ['app.py',
|
722 |
+
'selenium_click.py']},
|
723 |
'saved_notebook_display': None,
|
724 |
'split_percents': {0: 0.4410585404971933,
|
725 |
1: 0.5,
|
|
|
728 |
'tab_location': 'top',
|
729 |
'traversal_pos': ((1,
|
730 |
1),
|
731 |
+
1733884739.5002303),
|
732 |
'user_data': {}},
|
733 |
'saved_notebook_display': None,
|
734 |
'split_percents': {0: 0.49743589743589745},
|
|
|
736 |
'tab_location': 'left',
|
737 |
'traversal_pos': ((1,
|
738 |
0),
|
739 |
+
1733884739.4044967),
|
740 |
'user_data': {}},
|
741 |
'window-alloc': (0,
|
742 |
0,
|
743 |
1920,
|
744 |
793)}]}
|
745 |
+
guimgr.recent-documents = [loc('selenium_click.py'),
|
746 |
+
loc('app.py')]
|
747 |
guimgr.visual-state = {loc('../../envs/gradio-3/lib/python3.12/site-packages/selenium/webdriver/remote/errorhandler.py'): {'attrib-starts': [('ErrorHandler|0|',
|
748 |
140),
|
749 |
('ErrorHandler|0|.check_response|0|',
|
|
|
776 |
'sel-line-start': 0,
|
777 |
'selection_end': 537,
|
778 |
'selection_start': 0,
|
779 |
+
'zoom': 0},
|
780 |
+
loc('selenium_click.py'): {'attrib-starts': [],
|
781 |
+
'code-line': '',
|
782 |
+
'first-line': 0,
|
783 |
+
'folded-linenos': [],
|
784 |
+
'sel-line': 0,
|
785 |
+
'sel-line-start': 0,
|
786 |
+
'selection_end': 0,
|
787 |
+
'selection_start': 0,
|
788 |
'zoom': 0}}
|
789 |
proj.pyexec = {None: ('custom',
|
790 |
'/home/kevin/envs/gradio-3/bin/python3')}
|