Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
feat: add generate_forecasts script (#99)
* feat: add generate_forecasts script This commit introduces a new script named generate_forecasts.py that generates solar power forecasts for multiple photovoltaic (PV) sites. The script contains a function called generate_forecasts that takes a list of site information tuples and a forecast date as input. For each site, it creates a PVSite object, runs the forecast using the run_forecast function from the quartz_solar_forecast module, and generates a DataFrame containing the site's latitude, longitude, capacity, and power forecast values. The script then concatenates all the site DataFrames into a single DataFrame and returns it. The resulting DataFrame has columns for each site's latitude, longitude, capacity, and power forecast, with a column name in the format "{pv_id} Power". The index of the DataFrame is set to the forecast dates. The script also includes an example usage section that demonstrates how to call the generate_forecasts function with sample site information and a forecast date. The generated forecasts are then saved to a CSV file named pv_forecasts.csv. This script can be used to generate solar power forecasts for multiple PV sites, which can be useful for various applications, such as energy management, grid integration, and financial analysis.
- Loading branch information