Skip to content

Commit

Permalink
linting
Browse files Browse the repository at this point in the history
  • Loading branch information
bigbitbus committed Nov 3, 2023
1 parent d345a9b commit 3eb1e43
Showing 1 changed file with 5 additions and 5 deletions.
10 changes: 5 additions & 5 deletions roboflow/models/inference.py
Original file line number Diff line number Diff line change
Expand Up @@ -260,8 +260,8 @@ def predict_video(
models = [
{
"model_id": self.dataset_id,
"model_version":self.version,
"inference_type": self.type
"model_version": self.version,
"inference_type": self.type,
}
]

Expand Down Expand Up @@ -324,12 +324,12 @@ def poll_for_video_results(self, job_id: str = None) -> dict:
raise Exception(f"Error getting video inference results: {response.text}")
data = response.json()
if "status" not in data:
return {} # No status available
return {} # No status available
if data.get("status") > 1:
return(data) # Error
return data # Error
elif data.get("status") == 1:
return {} # Still running
else: # done
else: # done
output_signed_url = data["output_signed_url"]
inference_data = requests.get(
output_signed_url, headers={"Content-Type": "application/json"}
Expand Down

0 comments on commit 3eb1e43

Please sign in to comment.