Skip to content

Commit 4639b1c

Browse files
Merge pull request #56 from SatwikReddySripathi/main
Syncing with main
2 parents b634a3e + 6b71bd5 commit 4639b1c

File tree

1 file changed

+2
-4
lines changed

1 file changed

+2
-4
lines changed

dags/src/preprocessing.py

+2-4
Original file line numberDiff line numberDiff line change
@@ -21,7 +21,6 @@
2121
from sklearn.preprocessing import StandardScaler
2222
from tensorflow.keras.preprocessing.image import ImageDataGenerator
2323

24-
2524
PROJECT_DIR = '/opt/airflow'
2625
LOG_DIR = os.path.join(PROJECT_DIR, "logs")
2726
os.makedirs(LOG_DIR, exist_ok=True)
@@ -35,11 +34,10 @@
3534
STATS_FILE= os.path.join(PICKLE_DIR, 'demographics_stats_for_dummy.pkl')
3635

3736

38-
3937
logger = logging.getLogger()
4038
logger.setLevel(logging.DEBUG) # Setting to DEBUG to capture all log messages or else it might not log info and error messages(got this error already)
4139

42-
file_handler = logging.FileHandler(LOG_FILE_PATH)
40+
file_handler = logging.FileHandler(log_file_path)
4341
file_handler.setLevel(logging.DEBUG)
4442

4543
console_handler = logging.StreamHandler()
@@ -52,7 +50,7 @@
5250
logger.addHandler(file_handler)
5351
logger.addHandler(console_handler)
5452

55-
logger.info("Logging configuration is set. Logs will be saved to: {}".format(LOG_FILE_PATH))
53+
logger.info("Logging configuration is set. Logs will be saved to: {}".format(log_file_path))
5654

5755

5856
def load_label_indices(json_path):

0 commit comments

Comments
 (0)