wolfhece 2.0.44__py3-none-any.whl → 2.0.46__py3-none-any.whl
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- wolfhece/GraphProfile.py +26 -13
- wolfhece/Model1D.py +1562 -319
- wolfhece/PyCrosssections.py +9 -8
- wolfhece/PyDraw.py +17 -10
- wolfhece/PyVertexvectors.py +39 -27
- wolfhece/apps/version.py +1 -1
- wolfhece/drawing_obj.py +10 -0
- wolfhece/hydrology/Catchment.py +329 -5
- wolfhece/hydrology/Comparison.py +34 -25
- wolfhece/hydrology/Optimisation.py +1049 -117
- wolfhece/hydrology/RetentionBasin.py +200 -45
- wolfhece/hydrology/SubBasin.py +614 -31
- wolfhece/hydrology/constant.py +2 -2
- wolfhece/hydrology/cst_exchanges.py +35 -0
- wolfhece/hydrology/plot_hydrology.py +17 -19
- wolfhece/hydrology/read.py +63 -4
- wolfhece/libs/WolfDll.dll +0 -0
- wolfhece/libs/WolfDll_debug.dll +0 -0
- wolfhece/pyGui1D.py +114 -42
- wolfhece/scenario/check_scenario.py +1 -1
- wolfhece/scenario/config_manager.py +46 -1
- {wolfhece-2.0.44.dist-info → wolfhece-2.0.46.dist-info}/METADATA +1 -1
- {wolfhece-2.0.44.dist-info → wolfhece-2.0.46.dist-info}/RECORD +26 -26
- {wolfhece-2.0.44.dist-info → wolfhece-2.0.46.dist-info}/WHEEL +0 -0
- {wolfhece-2.0.44.dist-info → wolfhece-2.0.46.dist-info}/entry_points.txt +0 -0
- {wolfhece-2.0.44.dist-info → wolfhece-2.0.46.dist-info}/top_level.txt +0 -0
wolfhece/hydrology/Comparison.py
CHANGED
@@ -66,11 +66,11 @@ class Comparison:
|
|
66
66
|
def compare_now(self):
|
67
67
|
|
68
68
|
# Check and run all the functions to use
|
69
|
-
if(int(self.dictToCompar['hydro subbasin'][
|
69
|
+
if(int(self.dictToCompar['hydro subbasin'][key_Param.VALUE]) == 1):
|
70
70
|
self.hydro_subbasin()
|
71
|
-
if(int(self.dictToCompar['hydro junction'][
|
71
|
+
if(int(self.dictToCompar['hydro junction'][key_Param.VALUE]) == 1):
|
72
72
|
self.hydro_junction()
|
73
|
-
if(int(self.dictToCompar['hydro final'][
|
73
|
+
if(int(self.dictToCompar['hydro final'][key_Param.VALUE]) == 1):
|
74
74
|
self.hydro_final()
|
75
75
|
|
76
76
|
|
@@ -565,32 +565,37 @@ class Comparison:
|
|
565
565
|
curCatch = self.myCatchments[idCatch]['Object']
|
566
566
|
if(curCatch.myModel==cst.tom_UH):
|
567
567
|
|
568
|
-
tmp = curCatch.retentionBasinDict["J18"].directFluxInRB
|
569
|
-
tmpHydro = np.zeros(len(tmp))
|
568
|
+
# tmp = curCatch.retentionBasinDict["J18"].directFluxInRB
|
569
|
+
# tmpHydro = np.zeros(len(tmp))
|
570
570
|
|
571
|
-
index = math.floor(curCatch.retentionBasinDict["J18"].timeDelay/curCatch.retentionBasinDict["J18"].deltaT)
|
572
|
-
if(index==0):
|
573
|
-
|
574
|
-
elif(index<len(tmp)):
|
575
|
-
|
576
|
-
else:
|
577
|
-
|
578
|
-
|
571
|
+
# index = math.floor(curCatch.retentionBasinDict["J18"].timeDelay/curCatch.retentionBasinDict["J18"].deltaT)
|
572
|
+
# if(index==0):
|
573
|
+
# tmpHydro = tmp
|
574
|
+
# elif(index<len(tmp)):
|
575
|
+
# tmpHydro[:-index] = tmp[index:]
|
576
|
+
# else:
|
577
|
+
# print("ERROR: the simulation time is not long enough for this subbasin to be taken into account")
|
578
|
+
# sys.exit()
|
579
|
+
|
580
|
+
cur_module:RetentionBasin = curCatch.retentionBasinDict["J18"]
|
581
|
+
tmpHydro = cur_module.get_direct_insideRB_inlets(unit='m3/s')
|
579
582
|
|
580
583
|
y1.append(tmpHydro[:])
|
581
584
|
elif(curCatch.myModel==cst.tom_2layers_linIF or curCatch.myModel==cst.tom_2layers_UH):
|
582
585
|
|
583
|
-
tmp = curCatch.retentionBasinDict["J18"].directFluxInRB
|
584
|
-
tmpHydro = np.zeros(len(tmp))
|
586
|
+
# tmp = curCatch.retentionBasinDict["J18"].directFluxInRB
|
587
|
+
# tmpHydro = np.zeros(len(tmp))
|
585
588
|
|
586
|
-
index = math.floor(curCatch.retentionBasinDict["J18"].timeDelay/curCatch.retentionBasinDict["J18"].deltaT)
|
587
|
-
if(index==0):
|
588
|
-
|
589
|
-
elif(index<len(tmp)):
|
590
|
-
|
591
|
-
else:
|
592
|
-
|
593
|
-
|
589
|
+
# index = math.floor(curCatch.retentionBasinDict["J18"].timeDelay/curCatch.retentionBasinDict["J18"].deltaT)
|
590
|
+
# if(index==0):
|
591
|
+
# tmpHydro = tmp
|
592
|
+
# elif(index<len(tmp)):
|
593
|
+
# tmpHydro[:-index] = tmp[index:]
|
594
|
+
# else:
|
595
|
+
# print("ERROR: the simulation time is not long enough for this subbasin to be taken into account")
|
596
|
+
# sys.exit()
|
597
|
+
cur_module:RetentionBasin = curCatch.retentionBasinDict["J18"]
|
598
|
+
tmpHydro = cur_module.get_direct_insideRB_inlets(unit='m3/s')
|
594
599
|
|
595
600
|
y1.append(tmpHydro[:])
|
596
601
|
yLabels.append(curCatch.name)
|
@@ -793,6 +798,8 @@ class Comparison:
|
|
793
798
|
surfaceMeasure=Measures.surfaceDrainedHydro
|
794
799
|
elif(mySurf!=0.0):
|
795
800
|
surfaceMeasure = mySurf
|
801
|
+
else:
|
802
|
+
surfaceMeasure = -1.0
|
796
803
|
else:
|
797
804
|
myMeasure = []
|
798
805
|
Measures = None
|
@@ -948,8 +955,10 @@ class Comparison:
|
|
948
955
|
beginDateRB = []
|
949
956
|
endDateRB = []
|
950
957
|
for ii in range(nbCatchment):
|
951
|
-
beginDateRB.append(beginDate[ii] - timeDelay[ii]) # A ameliorer!!!
|
952
|
-
endDateRB.append(endDate[ii] - timeDelay[ii])
|
958
|
+
# beginDateRB.append(beginDate[ii] - timeDelay[ii]) # A ameliorer!!!
|
959
|
+
# endDateRB.append(endDate[ii] - timeDelay[ii])
|
960
|
+
beginDateRB.append(beginDate[ii]) # A ameliorer!!!
|
961
|
+
endDateRB.append(endDate[ii])
|
953
962
|
|
954
963
|
|
955
964
|
if("Station Name" in plotDict[RBNames[id]]):
|