Phani1008's picture
Update app.py
e5c02b4 verified
raw
history blame
3.29 kB
import streamlit as st
from streamlit_lottie import st_lottie
import requests
# Function to load Lottie animations
def load_lottieurl(url: str):
r = requests.get(url)
if r.status_code != 200:
return None
return r.json()
# Load animations
robot_animation = load_lottieurl("https://lottie.host/45619748-3867-4f57-8f50-cac297eca2da/1q98CFxp2I.json")
hero_animation = load_lottieurl("https://assets9.lottiefiles.com/packages/lf20_touohxv0.json")
data_science_animation = load_lottieurl("https://assets9.lottiefiles.com/packages/lf20_jcikwtux.json")
ml_animation = load_lottieurl("https://assets3.lottiefiles.com/packages/lf20_vf9lvx3t.json")
dl_animation = load_lottieurl("https://assets10.lottiefiles.com/packages/lf20_kuhijlvx.json")
gen_ai_animation = load_lottieurl("https://assets4.lottiefiles.com/packages/lf20_x62chJ.json")
# Home Page
st.title("Zero to Hero in Machine Learning 🌟")
st_lottie(hero_animation, height=300, key="hero")
# Custom Styling for the text and animation
st.markdown(
"""
<style>
.top-right-message {
position: fixed;
top: 10px;
right: 10px;
font-size: 24px;
font-weight: bold;
color: #333;
display: flex;
align-items: center;
}
.top-right-message img {
margin-left: 10px;
width: 50px;
}
</style>
""",
unsafe_allow_html=True
)
# Add the animated line with robot animation to the top-right corner
st.markdown(
"""
<div class="top-right-message">
Hey User!! Are You Ready??
<img src="https://assets6.lottiefiles.com/packages/lf20_3867_4f57_8f50_cac297eca2da_1q98CFxp2I.json" alt="robot" />
</div>
""",
unsafe_allow_html=True
)
# About the Author Section
st.header("About the Author πŸ“–")
st.write("""
Hi, I'm Phaneendra Bharadwaj, an aspiring data scientist and machine learning enthusiast.
Here's a bit about me:
- **Skills:** Python, Data Analysis, Machine Learning, Deep Learning, Generative AI.
- **Experience:** I'm a Fresher, working on various ML related projects.
""")
# Sections
st.subheader("πŸ“Š Data Science")
st_lottie(data_science_animation, height=200, key="data_science")
st.write("""
Data Science involves extracting insights from data using statistical and computational techniques.
**Example:** Predicting sales based on historical data.
""")
st.subheader("πŸ€– Machine Learning")
st_lottie(ml_animation, height=200, key="machine_learning")
st.write("""
Machine Learning enables systems to learn from data and improve their performance without being explicitly programmed.
**Example:** Spam email detection.
""")
st.subheader("🧠 Deep Learning")
st_lottie(dl_animation, height=200, key="deep_learning")
st.write("""
Deep Learning is a subset of Machine Learning that uses neural networks with multiple layers to model complex patterns.
**Example:** Image recognition, like identifying cats in pictures.
""")
st.subheader("✨ Generative AI")
st_lottie(gen_ai_animation, height=200, key="gen_ai")
st.write("""
Generative AI creates new content by learning from existing data.
**Example:** ChatGPT for generating human-like text responses.
""")
# Footer with animation
st.write("---")
st.markdown("**Let's embark on this journey from Zero to Hero! πŸš€**")