Skip to content

Commit

Permalink
Update environment variable handling to provide defaults for dataset …
Browse files Browse the repository at this point in the history
…ID and target resolution settings
  • Loading branch information
GoldenAnpu committed Dec 16, 2024
1 parent cdbdf6e commit 490a1d9
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions src/globals.py
Original file line number Diff line number Diff line change
Expand Up @@ -26,10 +26,10 @@
TEAM_ID = int(os.environ['context.teamId'])
WORKSPACE_ID = int(os.environ['context.workspaceId'])
PROJECT_ID = int(os.environ['modal.state.slyProjectId'])
DATASET_ID = int(os.environ['modal.state.slyDatasetId'])
CHANGE_RESOLUTION = bool(strtobool(os.environ['modal.state.changeResolution']))
TARGET_HEIGHT = int(os.environ['modal.state.targetResolutionHeight'])
TARGET_WIDTH = int(os.environ['modal.state.targetResolutionWidth'])
DATASET_ID = int(os.environ.get('modal.state.slyDatasetId', None))
CHANGE_RESOLUTION = bool(strtobool(os.environ.get('modal.state.changeResolution', 'false')))
TARGET_HEIGHT = int(os.environ.get('modal.state.targetResolutionHeight'), 1280)
TARGET_WIDTH = int(os.environ.get('modal.state.targetResolutionWidth'), 720)
target_resolution = (TARGET_WIDTH, TARGET_HEIGHT)

TARGET_FPS = float(os.environ['modal.state.targetFps'])
Expand Down

0 comments on commit 490a1d9

Please sign in to comment.