import streamlit as st
# Custom styles
st.markdown(
"""
""",
unsafe_allow_html=True,
)
# Title
st.markdown("
General Algorithm
", unsafe_allow_html=True)
st.markdown("At the time of training, the machine requires two things: Data & Algorithm.
", unsafe_allow_html=True)
# Basic Steps
st.markdown("
", unsafe_allow_html=True)
st.markdown("1. While guiding the machine, the main guidance comes from how we preprocess our data and choose the algorithm.
", unsafe_allow_html=True)
st.markdown("2. If we preprocess the data incorrectly and choose the wrong algorithm, it leads to bad model performance.
", unsafe_allow_html=True)
st.markdown("3. Inside the algorithm, there will be steps that the machine must follow while learning.
", unsafe_allow_html=True)
# Based on the Algorithm
st.markdown("
", unsafe_allow_html=True)
st.markdown("1. Identify whether the algorithm is Supervised, Unsupervised, Semi-supervised, or Reinforcement Learning.
", unsafe_allow_html=True)
st.markdown("2. If we choose Supervised Learning, we must decide between Classification or Regression based on the problem and data.
", unsafe_allow_html=True)
# Preprocessing Steps
st.markdown("
", unsafe_allow_html=True)
st.markdown("1. When working with preprocessed tabular data, identify the feature variables and class variables.
", unsafe_allow_html=True)
st.markdown("Example: Iris Dataset
", unsafe_allow_html=True)
st.markdown("Feature Variables: Sepal Length, Sepal Width, Petal Length, Petal Width
", unsafe_allow_html=True)
st.markdown("Class Variable: Species
", unsafe_allow_html=True)
st.markdown("2. Divide the entire data into feature variables and class variables.
", unsafe_allow_html=True)
st.markdown("3. Now split the data into Training Set (DTrain) and Test Set (DTest).
", unsafe_allow_html=True)
# Conditions for splitting
st.markdown("
", unsafe_allow_html=True)
st.markdown("1. Majority of the data should be in DTrain.
", unsafe_allow_html=True)
st.markdown("2. Minority of the data should be in DTest.
", unsafe_allow_html=True)
st.markdown("3. Common splits are 80:20, 70:30, or 60:40.
", unsafe_allow_html=True)
st.markdown("4. No single data point should be in both DTrain and DTest.
", unsafe_allow_html=True)
st.markdown("5. The split should be random, without replacement.
", unsafe_allow_html=True)
st.markdown("6. Each data point should have an equal probability of selection.
", unsafe_allow_html=True)
# Navigation Buttons
st.markdown("
", unsafe_allow_html=True)
col1, col2, col3 = st.columns(3)
with col1:
if st.button("KNN Algorithm"):
st.switch_page("pages/KNN Algorithm.py")
with col2:
if st.button("Decision Tree"):
st.switch_page("pages/Decision Tree.py")
with col3:
if st.button("Ensemble Techniques"):
st.switch_page("pages/Ensemble Techniques.py")