-
Notifications
You must be signed in to change notification settings - Fork 4
Expand file tree
/
Copy pathsettings.py
More file actions
24 lines (18 loc) · 817 Bytes
/
settings.py
File metadata and controls
24 lines (18 loc) · 817 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
import os
from dotenv import load_dotenv
from distutils.util import strtobool
load_dotenv()
DB_ENGINE = 'postgresql+psycopg2'
DB_USER = os.getenv('RDS_USERNAME')
DB_PASSWORD = os.getenv('RDS_PASSWORD')
DB_HOSTNAME = os.getenv('RDS_HOSTNAME')
DB_DATABASE_NAME = os.getenv('RDS_DB_NAME')
IPINFO_TOKEN = os.getenv('IPINFO_TOKEN')
S3_BUCKET = 'audioexplorer'
S3_STREAMED = f'https://s3.eu-central-1.amazonaws.com/{S3_BUCKET}/'
AWS_REGION = 'eu-central-1'
SERVE_LOCAL = strtobool(os.getenv('LOCAL', 'False'))
SAMPLING_RATE = 16000 # All audio will be resampled to this frequency
AUDIO_MARGIN = 0.05 # Margin applied to start and end of the audio to make it longer and improve UX. Not applied to any calculations.
TEMP_STORAGE = '/tmp/' # Temporary storage location
AUDIO_DB = -1 # Normalise input audio to this value