Spaces:
Sleeping
Sleeping
| 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 your provided Lottie animation | |
| lottie_animation_url = "https://lottie.host/45619748-3867-4f57-8f50-cac297eca2da/1q98CFxp2I.json" | |
| hero_animation = load_lottieurl(lottie_animation_url) | |
| # App title | |
| st.title("Zero to Hero in Machine Learning π") | |
| # Add animated text and Lottie animation in the top-right corner | |
| st.markdown( | |
| """ | |
| <div style="position: fixed; top: 20px; left: 20px; display: flex; align-items: center;"> | |
| <div style="font-size:30px; color:#f39c12; font-weight:bold; animation: textAnimation 2s ease-in-out infinite; margin-right: 20px;"> | |
| Hey User! Are you Ready?? | |
| </div> | |
| <div> | |
| <!-- Lottie animation --> | |
| <div style="width: 100px; height: 100px;"> | |
| <script src="https://cdnjs.cloudflare.com/ajax/libs/bodymovin/5.7.10/lottie.min.js"></script> | |
| <div id="lottie"></div> | |
| <script> | |
| var animation = bodymovin.loadAnimation({ | |
| container: document.getElementById('lottie'), | |
| renderer: 'svg', | |
| loop: true, | |
| autoplay: true, | |
| path: 'https://lottie.host/45619748-3867-4f57-8f50-cac297eca2da/1q98CFxp2I.json' | |
| }); | |
| </script> | |
| </div> | |
| </div> | |
| </div> | |
| <style> | |
| @keyframes textAnimation { | |
| 0% { color: #f39c12; transform: scale(1.1); } | |
| 50% { color: #e74c3c; transform: scale(1.2); } | |
| 100% { color: #f39c12; transform: scale(1.1); } | |
| } | |
| </style> | |
| """, | |
| unsafe_allow_html=True | |
| ) | |
| # Author and skills section | |
| st.header("About the Author π") | |
| st.write(""" | |
| Hi, I'm [Your Name], a Machine Learning enthusiast and Data Scientist. | |
| **Skills:** | |
| - Python, Pandas, Scikit-Learn, TensorFlow | |
| - Streamlit, Generative AI | |
| - Data Visualization | |
| """) | |