epyt-flow 0.14.2__py3-none-any.whl → 0.15.0__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.
Files changed (100) hide show
  1. epyt_flow/VERSION +1 -1
  2. epyt_flow/__init__.py +0 -37
  3. epyt_flow/data/benchmarks/battledim.py +2 -2
  4. epyt_flow/data/benchmarks/leakdb.py +12 -9
  5. epyt_flow/gym/scenario_control_env.py +32 -33
  6. epyt_flow/simulation/events/actuator_events.py +24 -18
  7. epyt_flow/simulation/events/leakages.py +59 -57
  8. epyt_flow/simulation/events/quality_events.py +21 -30
  9. epyt_flow/simulation/events/system_event.py +3 -3
  10. epyt_flow/simulation/scada/complex_control.py +14 -12
  11. epyt_flow/simulation/scada/custom_control.py +22 -21
  12. epyt_flow/simulation/scada/scada_data.py +107 -104
  13. epyt_flow/simulation/scada/simple_control.py +38 -31
  14. epyt_flow/simulation/scenario_simulator.py +368 -395
  15. epyt_flow/simulation/sensor_config.py +31 -32
  16. epyt_flow/topology.py +11 -10
  17. epyt_flow/uncertainty/model_uncertainty.py +146 -122
  18. {epyt_flow-0.14.2.dist-info → epyt_flow-0.15.0.dist-info}/METADATA +14 -19
  19. epyt_flow-0.15.0.dist-info/RECORD +65 -0
  20. epyt_flow/EPANET/EPANET/SRC_engines/AUTHORS +0 -28
  21. epyt_flow/EPANET/EPANET/SRC_engines/LICENSE +0 -21
  22. epyt_flow/EPANET/EPANET/SRC_engines/Readme_SRC_Engines.txt +0 -18
  23. epyt_flow/EPANET/EPANET/SRC_engines/enumstxt.h +0 -134
  24. epyt_flow/EPANET/EPANET/SRC_engines/epanet.c +0 -5578
  25. epyt_flow/EPANET/EPANET/SRC_engines/epanet2.c +0 -865
  26. epyt_flow/EPANET/EPANET/SRC_engines/epanet2.def +0 -131
  27. epyt_flow/EPANET/EPANET/SRC_engines/errors.dat +0 -73
  28. epyt_flow/EPANET/EPANET/SRC_engines/funcs.h +0 -193
  29. epyt_flow/EPANET/EPANET/SRC_engines/genmmd.c +0 -1000
  30. epyt_flow/EPANET/EPANET/SRC_engines/hash.c +0 -177
  31. epyt_flow/EPANET/EPANET/SRC_engines/hash.h +0 -28
  32. epyt_flow/EPANET/EPANET/SRC_engines/hydcoeffs.c +0 -1151
  33. epyt_flow/EPANET/EPANET/SRC_engines/hydraul.c +0 -1117
  34. epyt_flow/EPANET/EPANET/SRC_engines/hydsolver.c +0 -720
  35. epyt_flow/EPANET/EPANET/SRC_engines/hydstatus.c +0 -476
  36. epyt_flow/EPANET/EPANET/SRC_engines/include/epanet2.h +0 -431
  37. epyt_flow/EPANET/EPANET/SRC_engines/include/epanet2_2.h +0 -1786
  38. epyt_flow/EPANET/EPANET/SRC_engines/include/epanet2_enums.h +0 -468
  39. epyt_flow/EPANET/EPANET/SRC_engines/inpfile.c +0 -810
  40. epyt_flow/EPANET/EPANET/SRC_engines/input1.c +0 -707
  41. epyt_flow/EPANET/EPANET/SRC_engines/input2.c +0 -864
  42. epyt_flow/EPANET/EPANET/SRC_engines/input3.c +0 -2170
  43. epyt_flow/EPANET/EPANET/SRC_engines/main.c +0 -93
  44. epyt_flow/EPANET/EPANET/SRC_engines/mempool.c +0 -142
  45. epyt_flow/EPANET/EPANET/SRC_engines/mempool.h +0 -24
  46. epyt_flow/EPANET/EPANET/SRC_engines/output.c +0 -852
  47. epyt_flow/EPANET/EPANET/SRC_engines/project.c +0 -1359
  48. epyt_flow/EPANET/EPANET/SRC_engines/quality.c +0 -685
  49. epyt_flow/EPANET/EPANET/SRC_engines/qualreact.c +0 -743
  50. epyt_flow/EPANET/EPANET/SRC_engines/qualroute.c +0 -694
  51. epyt_flow/EPANET/EPANET/SRC_engines/report.c +0 -1489
  52. epyt_flow/EPANET/EPANET/SRC_engines/rules.c +0 -1362
  53. epyt_flow/EPANET/EPANET/SRC_engines/smatrix.c +0 -871
  54. epyt_flow/EPANET/EPANET/SRC_engines/text.h +0 -497
  55. epyt_flow/EPANET/EPANET/SRC_engines/types.h +0 -874
  56. epyt_flow/EPANET/EPANET-MSX/MSX_Updates.txt +0 -53
  57. epyt_flow/EPANET/EPANET-MSX/Src/dispersion.h +0 -27
  58. epyt_flow/EPANET/EPANET-MSX/Src/hash.c +0 -107
  59. epyt_flow/EPANET/EPANET-MSX/Src/hash.h +0 -28
  60. epyt_flow/EPANET/EPANET-MSX/Src/include/epanetmsx.h +0 -102
  61. epyt_flow/EPANET/EPANET-MSX/Src/include/epanetmsx_export.h +0 -42
  62. epyt_flow/EPANET/EPANET-MSX/Src/mathexpr.c +0 -937
  63. epyt_flow/EPANET/EPANET-MSX/Src/mathexpr.h +0 -39
  64. epyt_flow/EPANET/EPANET-MSX/Src/mempool.c +0 -204
  65. epyt_flow/EPANET/EPANET-MSX/Src/mempool.h +0 -24
  66. epyt_flow/EPANET/EPANET-MSX/Src/msxchem.c +0 -1285
  67. epyt_flow/EPANET/EPANET-MSX/Src/msxcompiler.c +0 -368
  68. epyt_flow/EPANET/EPANET-MSX/Src/msxdict.h +0 -42
  69. epyt_flow/EPANET/EPANET-MSX/Src/msxdispersion.c +0 -586
  70. epyt_flow/EPANET/EPANET-MSX/Src/msxerr.c +0 -116
  71. epyt_flow/EPANET/EPANET-MSX/Src/msxfile.c +0 -260
  72. epyt_flow/EPANET/EPANET-MSX/Src/msxfuncs.c +0 -175
  73. epyt_flow/EPANET/EPANET-MSX/Src/msxfuncs.h +0 -35
  74. epyt_flow/EPANET/EPANET-MSX/Src/msxinp.c +0 -1504
  75. epyt_flow/EPANET/EPANET-MSX/Src/msxout.c +0 -401
  76. epyt_flow/EPANET/EPANET-MSX/Src/msxproj.c +0 -791
  77. epyt_flow/EPANET/EPANET-MSX/Src/msxqual.c +0 -2010
  78. epyt_flow/EPANET/EPANET-MSX/Src/msxrpt.c +0 -400
  79. epyt_flow/EPANET/EPANET-MSX/Src/msxtank.c +0 -422
  80. epyt_flow/EPANET/EPANET-MSX/Src/msxtoolkit.c +0 -1164
  81. epyt_flow/EPANET/EPANET-MSX/Src/msxtypes.h +0 -551
  82. epyt_flow/EPANET/EPANET-MSX/Src/msxutils.c +0 -524
  83. epyt_flow/EPANET/EPANET-MSX/Src/msxutils.h +0 -56
  84. epyt_flow/EPANET/EPANET-MSX/Src/newton.c +0 -158
  85. epyt_flow/EPANET/EPANET-MSX/Src/newton.h +0 -34
  86. epyt_flow/EPANET/EPANET-MSX/Src/rk5.c +0 -287
  87. epyt_flow/EPANET/EPANET-MSX/Src/rk5.h +0 -39
  88. epyt_flow/EPANET/EPANET-MSX/Src/ros2.c +0 -293
  89. epyt_flow/EPANET/EPANET-MSX/Src/ros2.h +0 -35
  90. epyt_flow/EPANET/EPANET-MSX/Src/smatrix.c +0 -816
  91. epyt_flow/EPANET/EPANET-MSX/Src/smatrix.h +0 -29
  92. epyt_flow/EPANET/EPANET-MSX/readme.txt +0 -14
  93. epyt_flow/EPANET/compile_linux.sh +0 -4
  94. epyt_flow/EPANET/compile_macos.sh +0 -4
  95. epyt_flow/simulation/backend/__init__.py +0 -1
  96. epyt_flow/simulation/backend/my_epyt.py +0 -1101
  97. epyt_flow-0.14.2.dist-info/RECORD +0 -142
  98. {epyt_flow-0.14.2.dist-info → epyt_flow-0.15.0.dist-info}/WHEEL +0 -0
  99. {epyt_flow-0.14.2.dist-info → epyt_flow-0.15.0.dist-info}/licenses/LICENSE +0 -0
  100. {epyt_flow-0.14.2.dist-info → epyt_flow-0.15.0.dist-info}/top_level.txt +0 -0
@@ -1,39 +0,0 @@
1
- /******************************************************************************
2
- ** MODULE: MATHEXPR.H
3
- ** PROJECT: EPANET-MSX
4
- ** DESCRIPTION: header file for the math expression parser in mathexpr.c.
5
- ** AUTHORS: see AUTHORS
6
- ** Copyright: see AUTHORS
7
- ** License: see LICENSE
8
- ** VERSION: 2.0.00
9
- ** LAST UPDATE: 2/8/11
10
- ******************************************************************************/
11
-
12
- #ifndef MATHEXPR_H
13
- #define MATHEXPR_H
14
-
15
- // Node in a tokenized math expression list
16
- struct ExprNode
17
- {
18
- int opcode; // operator code
19
- int ivar; // variable index
20
- double fvalue; // numerical value
21
- struct ExprNode *prev; // previous node
22
- struct ExprNode *next; // next node
23
- };
24
- typedef struct ExprNode MathExpr;
25
-
26
- // Creates a tokenized math expression from a string
27
- MathExpr* mathexpr_create(char* s, int (*getVar) (char *));
28
-
29
- // Evaluates a tokenized math expression
30
- double mathexpr_eval(MathExpr* expr, double (*getVal) (int));
31
-
32
- // Deletes a tokenized math expression
33
- void mathexpr_delete(MathExpr* expr);
34
-
35
- // Returns reconstructed string version of a tokenized expression
36
- char * mathexpr_getStr(MathExpr* expr, char* exprStr,
37
- char * (*getVariableStr) (int, char *));
38
-
39
- #endif
@@ -1,204 +0,0 @@
1
- /* mempool.c
2
- **
3
- ** A simple fast memory allocation package.
4
- **
5
- ** By Steve Hill in Graphics Gems III, David Kirk (ed.),
6
- ** Academic Press, Boston, MA, 1992
7
- **
8
- ** Modified by Lew Rossman, 8/13/94.
9
- **
10
- ** AllocInit() - create an alloc pool, returns the old pool handle
11
- ** Alloc() - allocate memory
12
- ** AllocReset() - reset the current pool
13
- ** AllocSetPool() - set the current pool
14
- ** AllocFree() - free the memory used by the current pool.
15
- **
16
- */
17
-
18
- #include <stdlib.h>
19
-
20
- #include "mempool.h"
21
-
22
- /*
23
- ** ALLOC_BLOCK_SIZE - adjust this size to suit your installation - it
24
- ** should be reasonably large otherwise you will be mallocing a lot.
25
- */
26
-
27
- #define ALLOC_BLOCK_SIZE 64000 /*(62*1024)*/
28
-
29
- /*
30
- ** alloc_hdr_t - Header for each block of memory.
31
- */
32
-
33
- typedef struct alloc_hdr_s
34
- {
35
- struct alloc_hdr_s *next; /* Next Block */
36
- char *block, /* Start of block */
37
- *free, /* Next free in block */
38
- *end; /* block + block size */
39
- } alloc_hdr_t;
40
-
41
- /*
42
- ** alloc_root_t - Header for the whole pool.
43
- */
44
-
45
- typedef struct alloc_root_s
46
- {
47
- alloc_hdr_t *first, /* First header in pool */
48
- *current; /* Current header */
49
- } alloc_root_t;
50
-
51
- /*
52
- ** root - Pointer to the current pool.
53
- */
54
-
55
- static alloc_root_t *root;
56
-
57
-
58
- /*
59
- ** AllocHdr()
60
- **
61
- ** Private routine to allocate a header and memory block.
62
- */
63
-
64
- static alloc_hdr_t *AllocHdr(void);
65
-
66
- static alloc_hdr_t * AllocHdr()
67
- {
68
- alloc_hdr_t *hdr;
69
- char *block;
70
-
71
- block = (char *) malloc(ALLOC_BLOCK_SIZE);
72
- hdr = (alloc_hdr_t *) malloc(sizeof(alloc_hdr_t));
73
-
74
- if (hdr == NULL || block == NULL) return(NULL);
75
- hdr->block = block;
76
- hdr->free = block;
77
- hdr->next = NULL;
78
- hdr->end = block + ALLOC_BLOCK_SIZE;
79
-
80
- return(hdr);
81
- }
82
-
83
-
84
- /*
85
- ** AllocInit()
86
- **
87
- ** Create a new memory pool with one block.
88
- ** Returns pointer to the new pool.
89
- */
90
-
91
- alloc_handle_t * AllocInit()
92
- {
93
- alloc_handle_t *newpool;
94
-
95
- root = (alloc_root_t *) malloc(sizeof(alloc_root_t));
96
- if (root == NULL) return(NULL);
97
- if ( (root->first = AllocHdr()) == NULL) return(NULL);
98
- root->current = root->first;
99
- newpool = (alloc_handle_t *) root;
100
- return(newpool);
101
- }
102
-
103
-
104
- /*
105
- ** Alloc()
106
- **
107
- ** Use as a direct replacement for malloc(). Allocates
108
- ** memory from the current pool.
109
- */
110
-
111
- char * Alloc(long size)
112
- {
113
- alloc_hdr_t *hdr = root->current;
114
- char *ptr;
115
-
116
- /*
117
- ** Align to 4 byte boundary - should be ok for most machines.
118
- ** Change this if your machine has weird alignment requirements.
119
- */
120
- size = (size + 3) & 0xfffffffc;
121
-
122
- ptr = hdr->free;
123
- hdr->free += size;
124
-
125
- /* Check if the current block is exhausted. */
126
-
127
- if (hdr->free >= hdr->end)
128
- {
129
- /* Is the next block already allocated? */
130
-
131
- if (hdr->next != NULL)
132
- {
133
- /* re-use block */
134
- hdr->next->free = hdr->next->block;
135
- root->current = hdr->next;
136
- }
137
- else
138
- {
139
- /* extend the pool with a new block */
140
- if ( (hdr->next = AllocHdr()) == NULL) return(NULL);
141
- root->current = hdr->next;
142
- }
143
-
144
- /* set ptr to the first location in the next block */
145
- ptr = root->current->free;
146
- root->current->free += size;
147
- }
148
-
149
- /* Return pointer to allocated memory. */
150
-
151
- return(ptr);
152
- }
153
-
154
-
155
- /*
156
- ** AllocSetPool()
157
- **
158
- ** Change the current pool. Return the old pool.
159
- */
160
-
161
- alloc_handle_t * AllocSetPool(alloc_handle_t *newpool)
162
- {
163
- alloc_handle_t *old = (alloc_handle_t *) root;
164
- root = (alloc_root_t *) newpool;
165
- return(old);
166
- }
167
-
168
-
169
- /*
170
- ** AllocReset()
171
- **
172
- ** Reset the current pool for re-use. No memory is freed,
173
- ** so this is very fast.
174
- */
175
-
176
- void AllocReset()
177
- {
178
- root->current = root->first;
179
- root->current->free = root->current->block;
180
- }
181
-
182
-
183
- /*
184
- ** AllocFreePool()
185
- **
186
- ** Free the memory used by the current pool.
187
- ** Don't use where AllocReset() could be used.
188
- */
189
-
190
- void AllocFreePool()
191
- {
192
- alloc_hdr_t *tmp,
193
- *hdr = root->first;
194
-
195
- while (hdr != NULL)
196
- {
197
- tmp = hdr->next;
198
- free((char *) hdr->block);
199
- free((char *) hdr);
200
- hdr = tmp;
201
- }
202
- free((char *) root);
203
- root = NULL;
204
- }
@@ -1,24 +0,0 @@
1
- /*
2
- ** mempool.h
3
- **
4
- ** Header for mempool.c
5
- **
6
- ** The type alloc_handle_t provides an opaque reference to the
7
- ** alloc pool - only the alloc routines know its structure.
8
- */
9
-
10
- #ifndef MEMPOOL_H
11
- #define MEMPOOL_H
12
-
13
- typedef struct
14
- {
15
- long dummy;
16
- } alloc_handle_t;
17
-
18
- alloc_handle_t *AllocInit(void);
19
- char *Alloc(long);
20
- alloc_handle_t *AllocSetPool(alloc_handle_t *);
21
- void AllocReset(void);
22
- void AllocFreePool(void);
23
-
24
- #endif