Register
Login
Resources
Docs Blog Datasets Glossary Case Studies Tutorials & Webinars
Product
Data Engine LLMs Platform Enterprise
Pricing Explore
Connect to our Discord channel

main.py 2.1 KB

You have to be logged in to leave a comment. Sign In
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
  1. from src.mlProject import logger
  2. from src.mlProject.pipeline.stage_01_data_ingestion import DataIngestionTrainingPipeline
  3. from src.mlProject.pipeline.stage_02_data_validation import DataValidationTrainingPipeline
  4. from src.mlProject.pipeline.stage_03_data_transformation import DataTransformationTrainingPipeline
  5. from src.mlProject.pipeline.stage_04_model_trainer import ModelTrainerTrainingPipeline
  6. from src.mlProject.pipeline.stage_05_model_evaluation import ModelEvaluationTrainingPipeline
  7. STAGE_NAME = "Data Ingestion stage"
  8. try:
  9. logger.info(f">>>>>> stage {STAGE_NAME} started <<<<<<")
  10. data_ingestion = DataIngestionTrainingPipeline()
  11. data_ingestion.main()
  12. logger.info(f">>>>>> stage {STAGE_NAME} completed <<<<<<\n\nx==========x")
  13. except Exception as e:
  14. logger.exception(e)
  15. raise e
  16. STAGE_NAME = "Data Validation stage"
  17. try:
  18. logger.info(f">>>>>> stage {STAGE_NAME} started <<<<<<")
  19. data_ingestion = DataValidationTrainingPipeline()
  20. data_ingestion.main()
  21. logger.info(f">>>>>> stage {STAGE_NAME} completed <<<<<<\n\nx==========x")
  22. except Exception as e:
  23. logger.exception(e)
  24. raise e
  25. STAGE_NAME = "Data Transformation stage"
  26. try:
  27. logger.info(f">>>>>> stage {STAGE_NAME} started <<<<<<")
  28. data_ingestion = DataTransformationTrainingPipeline()
  29. data_ingestion.main()
  30. logger.info(f">>>>>> stage {STAGE_NAME} completed <<<<<<\n\nx==========x")
  31. except Exception as e:
  32. logger.exception(e)
  33. raise e
  34. STAGE_NAME = "Model Trainer stage"
  35. try:
  36. logger.info(f">>>>>> stage {STAGE_NAME} started <<<<<<")
  37. data_ingestion = ModelTrainerTrainingPipeline()
  38. data_ingestion.main()
  39. logger.info(f">>>>>> stage {STAGE_NAME} completed <<<<<<\n\nx==========x")
  40. except Exception as e:
  41. logger.exception(e)
  42. raise e
  43. # STAGE_NAME = "Model evaluation stage"
  44. # try:
  45. # logger.info(f">>>>>> stage {STAGE_NAME} started <<<<<<")
  46. # data_ingestion = ModelEvaluationTrainingPipeline()
  47. # data_ingestion.main()
  48. # logger.info(f">>>>>> stage {STAGE_NAME} completed <<<<<<\n\nx==========x")
  49. # except Exception as e:
  50. # logger.exception(e)
  51. # raise e
Tip!

Press p or to see the previous file or, n or to see the next file

Comments

Loading...