Git Product home page Git Product logo

importepanetinpfiles's People

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar

importepanetinpfiles's Issues

Curve Type

Not sure if this is an issue but I found that if your curve types are string and not integers then the inp file will not convert.

Uncaught RuntimeError: wrapped C/C++ object of type QProgressBar has been deleted

Steps to reproduce

  1. First
  2. Second
  3. Third
Traceback (most recent call last):
  File "C:/Users/utente/.qgis2/python/plugins\ImportEpanetInpFiles\main.py", line 32, in run
    s = epa2gis(filePath)
  File "C:/Users/utente/.qgis2/python/plugins\ImportEpanetInpFiles\Epa2GIS.py", line 136, in epa2gis
    pb.setValue(17)
RuntimeError: wrapped C/C++ object of type QProgressBar has been deleted

ImportEpanetInpFiles 0.3, QGIS 2.18.3 on Windows 8

Error in import inp file

Hi, get this error when i try upload the inp file:

Traceback (most recent call last):
File "C:/Users/usuario/.qgis2/python/plugins\ImportEpanetInpFiles\main.py", line 32, in run
s = epa2gis(filePath)
File "C:/Users/usuario/.qgis2/python/plugins\ImportEpanetInpFiles\Epa2GIS.py", line 160, in epa2gis
pb.setValue(18+bbLink); bbLink=bbLink+1
RuntimeError: wrapped C/C++ object of type QProgressBar has been deleted

Someone could help me?
Thanks!

Description offset when importing .inp-files from EPANET 2.2

I'm experiencing a problem when importing .inp files from EPANET 2.2.
The description in the imported .shp-file is offset by one.

Please see attached .inp-file. When this is imported in QGIS the resulting shapefile is missing the description for pipe 1 and pipe 2 is assigned the description of pipe 1.
image

epanet_2_2_inp_example.zip

[TITLE]

Example file illustrating description offset after importing inp file to shp.
Coordinatesystem is EPSG:25832

[JUNCTIONS]
;ID              	Elev        	Demand      	Pattern         
 1               	0           	0           	                	;
 2               	0           	0           	                	;
 3               	0           	0           	                	;

[RESERVOIRS]
;ID              	Head        	Pattern         

[TANKS]
;ID              	Elevation   	InitLevel   	MinLevel    	MaxLevel    	Diameter    	MinVol      	VolCurve        	Overflow

[PIPES]
;ID              	Node1           	Node2           	Length      	Diameter    	Roughness   	MinorLoss   	Status
 1               	2               	3               	1011.74     	200         	2           	0           	Open  	;Description for pipe 1
 2               	3               	1               	1002.55     	500         	1           	0           	Open  	;Description for pipe 2

[PUMPS]
;ID              	Node1           	Node2           	Parameters

[VALVES]
;ID              	Node1           	Node2           	Diameter    	Type	Setting     	MinorLoss   

[TAGS]

[DEMANDS]
;Junction        	Demand      	Pattern         	Category

[STATUS]
;ID              	Status/Setting

[PATTERNS]
;ID              	Multipliers

[CURVES]
;ID              	X-Value     	Y-Value

[CONTROLS]

[RULES]

[ENERGY]
 Global Efficiency  	75
 Global Price       	0
 Demand Charge      	0

[EMITTERS]
;Junction        	Coefficient

[QUALITY]
;Node            	InitQual

[SOURCES]
;Node            	Type        	Quality     	Pattern

[REACTIONS]
;Type     	Pipe/Tank       	Coefficient


[REACTIONS]
 Order Bulk            	1
 Order Tank            	1
 Order Wall            	1
 Global Bulk           	0
 Global Wall           	0
 Limiting Potential    	0
 Roughness Correlation 	0

[MIXING]
;Tank            	Model

[TIMES]
 Duration           	0
 Hydraulic Timestep 	1:00
 Quality Timestep   	0:05
 Pattern Timestep   	1:00
 Pattern Start      	0:00
 Report Timestep    	1:00
 Report Start       	0:00
 Start ClockTime    	12 am
 Statistic          	None

[REPORT]
 Status             	No
 Summary            	No
 Page               	0

[OPTIONS]
 Units              	LPS
 Headloss           	D-W
 Specific Gravity   	1
 Viscosity          	1
 Trials             	40
 Accuracy           	0.001
 CHECKFREQ          	2
 MAXCHECK           	10
 DAMPLIMIT          	0
 Unbalanced         	Continue 10
 Pattern            	1
 Demand Multiplier  	1.0
 Emitter Exponent   	0.5
 Quality            	None mg/L
 Diffusivity        	1
 Tolerance          	0.01

[COORDINATES]
;Node            	X-Coord           	Y-Coord
1               	592117.000        	6643054.000       
2               	594042.000        	6643539.000       
3               	593116.672        	6643129.881       

[VERTICES]
;Link            	X-Coord           	Y-Coord

[LABELS]
;X-Coord             Y-Coord             Label & Anchor Node

[BACKDROP]
  DIMENSIONS  	592020.750        	6643029.750       	594138.250        	6643563.250       
 UNITS          	None
 FILE           	
 OFFSET         	0.00            	0.00            

[END]

Import error inp file: KeyError: '23'

Error:
Traceback (most recent call last):
File "C:/Users/usuario/.qgis2/python/plugins\ImportEpanetInpFiles\main.py", line 32, in run
s = epa2gis(filePath)
File "C:/Users/usuario/.qgis2/python/plugins\ImportEpanetInpFiles\Epa2GIS.py", line 770, in epa2gis
feature.setAttribute(w+1, CurvesTmp[curveIndex][p][1])
KeyError: '23'

QGIS version:
Versión de Python: 2.7.4 (default, Apr 6 2013, 19:54:46) [MSC v.1500 32 bit (Intel)]
Versión de QGIS: 2.18.3 Las Palmas, 77b8c3d

SO
Windows 7 64bits

The repo contains dlls

These are not allowed, as the plugin should only contain free and open source software.

Base demand with null values

I've imported a inp file to shp. In the shp file, the junctions have values in the field demand1. When I export back to inp the field Base Demand only have null values.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.