mkhodary101 commited on
Commit
397b8df
·
verified ·
1 Parent(s): d696ec6

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +3 -3
app.py CHANGED
@@ -12,7 +12,7 @@ class CrowdDetection:
12
  self.model_path = model_path
13
 
14
  @spaces.GPU
15
- def crowd_detection(self, video_path):
16
  try:
17
  device = torch.device("cuda" if torch.cuda.is_available() else "cpu")
18
  if not os.path.exists(self.model_path):
@@ -131,7 +131,7 @@ class FallDetection:
131
  self.model_path = yolo_model_path
132
 
133
  @spaces.GPU
134
- def fall_detection(self, video_path):
135
  try:
136
  device = torch.device("cuda" if torch.cuda.is_available() else "cpu")
137
  if not os.path.exists(self.model_path):
@@ -196,7 +196,7 @@ class FightDetection:
196
  self.model_path = yolo_model_path
197
 
198
  @spaces.GPU
199
- def fight_detection(self, video_path):
200
  try:
201
  device = torch.device("cuda" if torch.cuda.is_available() else "cpu")
202
  if not os.path.exists(self.model_path):
 
12
  self.model_path = model_path
13
 
14
  @spaces.GPU
15
+ def crowd_detect(self, video_path):
16
  try:
17
  device = torch.device("cuda" if torch.cuda.is_available() else "cpu")
18
  if not os.path.exists(self.model_path):
 
131
  self.model_path = yolo_model_path
132
 
133
  @spaces.GPU
134
+ def fall_detect(self, video_path):
135
  try:
136
  device = torch.device("cuda" if torch.cuda.is_available() else "cpu")
137
  if not os.path.exists(self.model_path):
 
196
  self.model_path = yolo_model_path
197
 
198
  @spaces.GPU
199
+ def fight_detect(self, video_path):
200
  try:
201
  device = torch.device("cuda" if torch.cuda.is_available() else "cpu")
202
  if not os.path.exists(self.model_path):