Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Load model from huggingface #76

Open
wants to merge 82 commits into
base: master
Choose a base branch
from
Open
Changes from 1 commit
Commits
Show all changes
82 commits
Select commit Hold shift + click to select a range
8703ace
Test install
zhong-al Oct 11, 2024
26ecd62
Start tracks extractor test
zhong-al Oct 11, 2024
309c15d
Add data for tracks extractor test
zhong-al Oct 11, 2024
1ae921a
Check test on any push
zhong-al Oct 11, 2024
6da7f18
Try to fix torch missing
zhong-al Oct 11, 2024
9ac0c76
Try to fix torch missing
zhong-al Oct 11, 2024
c38275f
Fix hatchling missing
zhong-al Oct 12, 2024
6f66453
Add miniscene2behavior test
zhong-al Oct 12, 2024
af28c4b
Update tests
zhong-al Oct 14, 2024
f9dd66b
Start test for cvat2ultralytics and detector2cvat
zhong-al Oct 14, 2024
98b2b76
Fix cvat2ultralytics, move detection test files
zhong-al Oct 14, 2024
3407f48
Add miniscene2behavior test
zhong-al Oct 14, 2024
4ee974d
Ignore tool outputs
zhong-al Oct 14, 2024
15d1316
Adjust path
zhong-al Oct 14, 2024
6aa96f2
Update path
zhong-al Oct 14, 2024
d313209
Add player test and fix player globals
zhong-al Oct 14, 2024
a3347c5
Add cvat2slowfast test
zhong-al Oct 14, 2024
7076bb3
Comment out tests
zhong-al Oct 18, 2024
912d547
Add mocked tests
zhong-al Oct 18, 2024
06d01ee
Patch detector2cvat
zhong-al Oct 18, 2024
331ecc7
Patch player & add sample data
zhong-al Oct 18, 2024
1fe22af
Rename run functions
zhong-al Oct 18, 2024
869b17b
Test tracks extractor parser
zhong-al Oct 18, 2024
a25f893
Mock getTrackbarPos
zhong-al Oct 18, 2024
8b4c2c7
Test cvat2slowfast parser
zhong-al Oct 19, 2024
8308c60
Test cvat2ultralytics parsing
zhong-al Oct 19, 2024
c011e0e
Test detector2cvat parsing
zhong-al Oct 19, 2024
0348bd6
Test miniscene2behavior parsing
zhong-al Oct 19, 2024
ac12359
Test player parsing
zhong-al Oct 19, 2024
e761672
Update cvat2slowfast
zhong-al Oct 25, 2024
5a1478e
Update cvat2ultralytics
zhong-al Oct 25, 2024
656c40d
Update detector2cvat
zhong-al Oct 25, 2024
b55f1dc
Fix test
zhong-al Oct 25, 2024
520e1cc
Update miniscene2behavior
zhong-al Oct 25, 2024
316ab59
Update player
zhong-al Oct 25, 2024
9cfcfc0
Update tracks_extractor
zhong-al Oct 25, 2024
7606e6d
Extract model download + unzip
zhong-al Oct 25, 2024
b191425
Fix download
zhong-al Oct 25, 2024
7584e81
Download model at setup
zhong-al Oct 28, 2024
9ee7499
Add label2index json
zhong-al Oct 30, 2024
fdba887
Merge branch 'master' into enhancement/testing
zhong-al Nov 13, 2024
50feea9
Delete tracks_extractor output
zhong-al Nov 13, 2024
6a91fc2
Add clean up + runs
zhong-al Nov 13, 2024
da97183
Merge branch 'master' into enhancement/testing
zhong-al Nov 13, 2024
37dd750
Update arg parsing checks
zhong-al Nov 13, 2024
f7eb368
Remove slowfast model
zhong-al Nov 15, 2024
d69776b
Remove slowfast imports
zhong-al Nov 15, 2024
d883e40
Update requirements
zhong-al Nov 19, 2024
2b87a14
Add slowfast code
zhong-al Nov 19, 2024
1eed904
Just test 1 file on this branch
zhong-al Nov 19, 2024
d02c0a6
Correct requirements
zhong-al Nov 19, 2024
bab8b0c
Update model download and creation
zhong-al Nov 19, 2024
abf9369
Update dependencies
zhong-al Nov 19, 2024
bb855f2
Add slowfast license
zhong-al Nov 19, 2024
ce923b5
Update dependencies
zhong-al Nov 19, 2024
17f6a79
Update README
zhong-al Nov 19, 2024
a9f2deb
Fix TypeError: _BatchNorm.__init__()
zhong-al Nov 19, 2024
e4dee39
Add hub checkpoint check
zhong-al Nov 19, 2024
75bc26d
Fix format string
zhong-al Nov 19, 2024
e9f70e8
Check all loading methods
zhong-al Nov 21, 2024
71b6a5e
Check handling of invalid args/params
zhong-al Nov 21, 2024
a62d74a
Update path resolution
zhong-al Nov 21, 2024
9bb1726
Fix comparison
zhong-al Nov 21, 2024
6873627
Check test output
zhong-al Nov 21, 2024
8b40266
Correct reference annotation
zhong-al Nov 21, 2024
6510324
Fix bug: missing model.eval()
zhong-al Nov 21, 2024
7e20266
Remove debug print
zhong-al Nov 21, 2024
61bc4ad
Print diffs
zhong-al Nov 21, 2024
c8a26b3
Update diff print
zhong-al Nov 21, 2024
0d9ef0b
Try comparing using pandas
zhong-al Nov 21, 2024
236d015
Fix sep
zhong-al Nov 21, 2024
7c1d6ff
Check repr
zhong-al Nov 22, 2024
d0a2f5b
Check problem frame tensor
zhong-al Nov 22, 2024
758c4be
Try to force determinism
zhong-al Nov 22, 2024
d153a71
Merge branch 'master' into enhancement/model
zhong-al Dec 10, 2024
6ead110
Delete videos
zhong-al Dec 10, 2024
70843fa
Re-add a space
zhong-al Dec 10, 2024
9aff8aa
Fix merge issue
zhong-al Dec 10, 2024
068cda9
Try macos
zhong-al Dec 10, 2024
0026dd4
Fix merge issue
zhong-al Dec 10, 2024
d80112e
Fix config + example
zhong-al Dec 11, 2024
7a313c8
Apply suggestions from code review
zhong-al Dec 14, 2024
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
Next Next commit
Comment out tests
  • Loading branch information
zhong-al committed Oct 18, 2024
commit 7076bb38cf99d60151257d93963df06cebbdbfe9
20 changes: 10 additions & 10 deletions tests/test_cvat2slowfast.py
Original file line number Diff line number Diff line change
@@ -1,12 +1,12 @@
import unittest
import sys
from kabr_tools import cvat2slowfast
# import unittest
# import sys
# from kabr_tools import cvat2slowfast


class TestCvat2Slowfast(unittest.TestCase):
def test_cvat2slowfast(self):
sys.argv = ["cvat2slowfast.py",
"--miniscene", "tests/behavior_example",
"--dataset", "tests/slowfast",
"--classes", "ethogram/classes.json"]
cvat2slowfast.main()
# class TestCvat2Slowfast(unittest.TestCase):
# def test_cvat2slowfast(self):
# sys.argv = ["cvat2slowfast.py",
# "--miniscene", "tests/behavior_example",
# "--dataset", "tests/slowfast",
# "--classes", "ethogram/classes.json"]
# cvat2slowfast.main()
20 changes: 10 additions & 10 deletions tests/test_cvat2ultralytics.py
Original file line number Diff line number Diff line change
@@ -1,12 +1,12 @@
import unittest
import sys
from kabr_tools import cvat2ultralytics
# import unittest
# import sys
# from kabr_tools import cvat2ultralytics


class TestCvat2Ultralytics(unittest.TestCase):
def test_cvat2ultralytics(self):
sys.argv = ["cvat2ultralytics.py",
"--video", "tests/detection_example",
"--annotation", "tests/detection_example",
"--dataset", "tests/ultralytics"]
cvat2ultralytics.main()
# class TestCvat2Ultralytics(unittest.TestCase):
# def test_cvat2ultralytics(self):
# sys.argv = ["cvat2ultralytics.py",
# "--video", "tests/detection_example",
# "--annotation", "tests/detection_example",
# "--dataset", "tests/ultralytics"]
# cvat2ultralytics.main()
18 changes: 9 additions & 9 deletions tests/test_detector2cvat.py
Original file line number Diff line number Diff line change
@@ -1,11 +1,11 @@
import unittest
import sys
from kabr_tools import detector2cvat
# import unittest
# import sys
# from kabr_tools import detector2cvat


class TestDetector2Cvat(unittest.TestCase):
def test_detector(self):
sys.argv = ["detector2cvat.py",
"--video", "tests/detection_example",
"--save", "tests/detection_example/output"]
detector2cvat.main()
# class TestDetector2Cvat(unittest.TestCase):
# def test_detector(self):
# sys.argv = ["detector2cvat.py",
# "--video", "tests/detection_example",
# "--save", "tests/detection_example/output"]
# detector2cvat.main()
20 changes: 10 additions & 10 deletions tests/test_player.py
Original file line number Diff line number Diff line change
@@ -1,12 +1,12 @@
import unittest
import sys
from kabr_tools import player
# import unittest
# import sys
# from kabr_tools import player


class TestPlayer(unittest.TestCase):
def test_player(self):
# run player
sys.argv = ["player.py",
"--folder", "tests/behavior_example/DJI_0001",
"--save"]
player.main()
# class TestPlayer(unittest.TestCase):
# def test_player(self):
# # run player
# sys.argv = ["player.py",
# "--folder", "tests/behavior_example/DJI_0001",
# "--save"]
# player.main()
20 changes: 10 additions & 10 deletions tests/test_tracks_extractor.py
Original file line number Diff line number Diff line change
@@ -1,12 +1,12 @@
import unittest
import sys
from kabr_tools import tracks_extractor
# import unittest
# import sys
# from kabr_tools import tracks_extractor


class TestTracksExtractor(unittest.TestCase):
def test_extractor(self):
# run tracks_extractor
sys.argv = ["tracks_extractor.py",
"--video", "tests/detection_example/DJI_0068.mp4",
"--annotation", "tests/detection_example/DJI_0068.xml"]
tracks_extractor.main()
# class TestTracksExtractor(unittest.TestCase):
# def test_extractor(self):
# # run tracks_extractor
# sys.argv = ["tracks_extractor.py",
# "--video", "tests/detection_example/DJI_0068.mp4",
# "--annotation", "tests/detection_example/DJI_0068.xml"]
# tracks_extractor.main()