serapieum-of-alex / hapi Goto Github PK
View Code? Open in Web Editor NEWHapi is a Python library for building Conceptual Distributed Model using HBV96 lumped model & Muskingum routing method
License: GNU General Public License v3.0
Hapi is a Python library for building Conceptual Distributed Model using HBV96 lumped model & Muskingum routing method
License: GNU General Public License v3.0
Hi
Thanks for sharing the repo. I tried to run the project , but there are some files missing in input data. Can you upload the some sample so that i can run end to end
Thanks
create a method to create the calibration UB and LB files
when trying to match two rasters or reproject point the below error appears
*** RuntimeError: b'no arguments in initialization list'
replace the function that calls functions from scipy by those in the statista package
[hapi] environment.yml (Line 15)
- scipy >=1.11.4
Created from JetBrains using CodeStream
all the functionality that was in the digitalearth package has already moved upstream to the pyramids package so thee is no need anymore for the digitalearth package, but still all the calls to these method have to be replaced by the new methods in the pyramids package
[hapi] environment.yml (Line 28)
- digitalearth >=0.1.11
Created from JetBrains using CodeStream
the cross-section module in the hm depends mainly on statsmodels which is not used anywhere else in the package and it is better to move the cross-section statistical derivation to the statista package
[hapi] Hapi/hm/crosssection.py (Lines 8-13)
from statsmodels import api as sm
class CrossSections:
"""Cross-Section class."""
Created from JetBrains using CodeStream
Both modules parameters
and the rrm.parameters
and both contains functionalities regarding the rrm parameters.
[hapi] Hapi/rrm/parameters.py (Lines 19-34)
class Parameters:
"""Distripute.
parameter class is used to distribute the values of the parameter vector in the calibration
process into the 3D array, considering if some of the parameters are lumped parameters, if you want to
distribute the parameters in HRUs.
the method included are
1- par3d
2- par3dLumped
3- par2dLumpedK1_lake
4- HRU
5- HRU_HAND
6- ParametersNumber
7- saveParameters
"""
Created from JetBrains using CodeStream
all the functionality that was in the digitalearth package has already moved upstream to the pyramids package so thee is no need anymore for the digitalearth package, but still all the calls to these method have to be replaced by the new methods in the pyramids package
[hapi] environment.yml (Line 28)
- digitalearth >=0.1.11
Created from JetBrains using CodeStream
[hapi] Hapi/rrm/distparameters.py (Lines 80-81)
if lumped_par_pos is None:
lumped_par_pos = []
Created from JetBrains using CodeStream
The reproject method depends on the reprojection of the two corner points of the raster (lower left and top right) (Picture 1)
for a location that is very close to the north pole the distortion is very high and for that, the reprojection of the corner points becomes distorted (picture 2)
the method creates a grid between the new reprojected corner points and recalculates the cells' values in this grid
any values out of this grid (to the right of the top right corner or left of the lower-left corner after being reprojected) will be out of the new reprojected raster (Picture 3)
add the rasters of the parameters to the package to enable loading it
gdal has to be installed from conda forge and when using YML file to create an environment the environment passes gdal to install from pip which conflict with python 3.7 (the only one that does not conflict with python 3.7 is conda forge version)
the total simulated discharge variable name (quz+qlz) is different if the lumped "Qsim" than the distributed model "Qtot"
Describe the bug
[A clear and concise description of what the bug is.]
To Reproduce
Steps to reproduce the behavior:
Expected behaviour
A clear and concise description of what you expected to happen.
Screenshots
File ~\OneDrive - ESCUELA COLOMBIANA DE INGENIERIA JULIO GARAVITO (1)\IHE\TESIS\HAPI\METEO_DATA\Get_Data.py:36 in
Coello.ECMWF(Waitbar=1)
File ~\Anaconda3\envs\HidroMod\lib\site-packages\Hapi\rs\remotesensing.py:133 in ECMWF
self.DownloadData(var, Waitbar) # CaseParameters=[SumMean, Min, Max]
File ~\Anaconda3\envs\HidroMod\lib\site-packages\Hapi\rs\remotesensing.py:286 in DownloadData
Raster.CreateRaster(Path=name_out, data=Data_end, geo=Geo_out, EPSG="WGS84")
TypeError: CreateRaster() got an unexpected keyword argument 'data'
Desktop (please complete the following information):
Smartphone (please complete the following information):
Additional context
Add any other context about the problem here.
replace the function that calls functions from scipy by those in the statista package
[hapi] environment.yml (Line 15)
- scipy >=1.11.4
Created from JetBrains using CodeStream
create a method to download ECMWF data for the model
check richdem module to use it in the DEM preparation data
richdem
Flow direction raster accepts the D8 rasters generated from ARC Map only at the moment, as the direction code representing the 8 directions differs in qgis
Use CUDA to parallelize the RunLumpedRRM loop
enable saving results in netcdf format
Documentation of all methods
Just a couple of bugs that need to be fixed:
In the module calibration.py
line 204
it is necessary to change the function name Dist_model
to HapiModel
since the name of the function has been changed in the new version of Hapi 0.3.0.
In the module distparameters.py
the arguments of the function par3dLumped
should be (par_g,raster,no_parameters,no_lumped_par=None,lumped_par_pos=None,kub=1,klb=0.5,Maskingum = True):
, although the variables no_lumped_par
and lumped_par_pos
are not needed (that's why it would be better to set them by default as None
), but because the function SaveParameters
states them in the line 707
. So it's either change this last line mentioned or state them as None
by default in the par3dLumped
.
It would be good to add this line of code: if ".DS_Store" in files: files.remove(".DS_Store")
under line 1947
on raster.py
module to ensure MacOS compatibility. (That could be done where needed as well)
The bot created this issue to inform you that pyup.io has been set up on this repo.
Once you have closed it, the bot will open pull requests for updates as soon as they are available.
the cross-section module in the hm depends mainly on statsmodels which is not used anywhere else in the package and it is better to move the cross-section statistical derivation to the statista package
[hapi] Hapi/hm/crosssection.py (Lines 8-13)
from statsmodels import api as sm
class CrossSections:
"""Cross-Section class."""
Created from JetBrains using CodeStream
validate the length and type of lake input inside the runHapiWithLake method
A declarative, efficient, and flexible JavaScript library for building user interfaces.
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google ❤️ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.