File size: 2,325 Bytes
a1f13e3
3818d3f
a1f13e3
 
 
 
 
 
3818d3f
a1f13e3
 
 
 
e96dd1b
a1f13e3
e96dd1b
a1f13e3
e96dd1b
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
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
---
title: Weather Dashboard
emoji: πŸš€
colorFrom: red
colorTo: red
sdk: docker
app_port: 8501
tags:
- streamlit
pinned: false
short_description: Streamlit template space
---

Global Weather Dashboard

A professional weather dashboard built with Streamlit and powered by the Open-Meteo API. This app allows users to view current weather conditions, a 7-day forecast, and interactive visualizations for multiple cities worldwide.

Features City Input: Enter comma-separated city names or select from predefined cities (e.g., New York, London, Tokyo). Interactive Map: Visualize city locations with current temperatures on a global map. Weather Data: Displays current temperature, wind speed, weather conditions, and a 7-day forecast. Charts: Choose between separate or combined charts for temperature and precipitation probability. Data Export: Download forecast data as CSV for each city. Responsive Design: Professional styling with a sidebar for settings and a clean, modern UI.

Setup Instructions: Clone the Repository: Ensure all files (app.py, requirements.txt) are in the root directory of your Hugging Face Space. Install Dependencies: Hugging Face Spaces will automatically install dependencies listed in requirements.txt when the Space is built. Run the App: The Space will run streamlit run app.py automatically. Ensure the app is set to use Python as the runtime environment.

Security Note: The app uses verify=False for HTTP requests, which is insecure for production. For production deployment, ensure vali SSL certificates are used.

Usage Open the app in your Hugging Face Space. In the sidebar, enter city names (e.g., "New York, London, Tokyo") or select a predefined city. Choose a chart type (Separate Charts or Combined Chart). Click "Fetch Weather" to display the weather data, including a map, current conditions, forecast table, and charts.

Download forecast data as CSV files for each city.

Dependencies streamlit: Web app framework requests: HTTP requests for API calls pandas: Data manipulation plotly: Interactive visualizations pytz: Timezone handling retrying: Retry logic for API calls

Data Source Weather data provided by Open-Meteo under CC BY 4.0.

For non-commercial use only.

Contact

For issues or inquiries, contact info@open-meteo.com or refer to the Open-Meteo GitHub repository.