How dalzihn/ti_final works
Project Identification
• Type & Purpose: This is a machine learning project focused on time series forecasting. The primary goal is to predict stock prices using deep learning techniques (LSTM and transformer-based models).
• Key Elements from Files:
• The Code folder holds the core logic: building model architectures (architecture.py), setting up and processing data (data_setup.py / experiment.ipynb), and training/testing routines (engine.py).
• The Data folder is pre-split into training and testing subsets with CSV files for different stock codes.
• The README provides context on the project by explaining the models and data organization.
Analyzing the File Structure
• Top-Level Separation: There are two main directories: Code and Data.
• Code: Contains the scripts for defining model architectures, preparing data, and executing training/testing routines.
• Data: Divided into 'train' and 'test' which hold the respective CSV files.
• Supplementary Files: .gitattributes, .gitignore, requirements.txt, and experiment.ipynb support version control, dependency management, and interactive experimentation.
Identifying Main Components
Components horizontally (from left to right) to emphasize data flow and modular processing:
• Data Sources:
• Data/Train CSV Files (multiple stock codes)
• Data/Test CSV Files
• Data Preparation Module:
• Code/data_setup.py (functions managing data extraction, organization, and possibly preprocessing)
• Model Architecture Module:
• Code/architecture.py (defines the three model architectures: LSTM, Transformer-based LSTM, and Transformer-based GRU)
• Training & Testing Engine:
• Code/engine.py (contains routines to train the chosen model and test performance)
• Experimentation & Evaluation:
• Code/experiment.ipynb (used for interactive experiments, visualizing results, and potentially fine-tuning or validating models)
Architectural Patterns and Design Principles
• Modular Design: Clear separation of concerns is maintained among data handling, model creation, and training/testing logic.
• Pipeline Flow: The data flows sequentially from raw input through processing, modeling, and evaluation.