architecture-building-systems / CityEnergyAnalyst

The City Energy Analyst (CEA)
https://www.cityenergyanalyst.com/
MIT License
196 stars 66 forks source link

Simple project creation with the Dashboard does not work #2091

Closed CarlosSantosSilvaTecnico closed 5 years ago

CarlosSantosSilvaTecnico commented 5 years ago

I tried to create a new project from scratch using the dashboard. I choose the zone in the map, i make the polygon of one building, included the information of number of floors etc, but when I push the create bottom , I have an error.

See the outputs bellow. Apparently, something wrong with the REFERENCE field. I have tried creating the district etc, but the error seems to be always the same. om scratch using the dashboard.

Output

File "C:\Users\Carlos\Documents\CityEnergyAnalyst\Dependencies\Python\lib\site-packages\pandas\core\indexing.py", line 1327, in _convert_to_indexer .format(mask=objarr[mask])) KeyError: "['REFERENCE'] not in index" 127.0.0.1 - - [24/Jun/2019 22:13:37] "POST /landing/create-scenario/save HTTP/1.1" 500 - 127.0.0.1 - - [24/Jun/2019 22:13:38] "GET /favicon.ico HTTP/1.1" 404 -

daren-thomas commented 5 years ago

@CarlosSantosSilvaTecnico I just tried to reproduce this with the following steps:

I had no issues.

What version are you running? How did you install? What buildings are you selecting?

CarlosSantosSilvaTecnico commented 5 years ago

Dear Daren, thanks for your prompt answer, but it does not work…I made this file using windows step recorder so you can see…

I have python 3.7, but as I understand, CEA runs inside an environment with Python 2.7, so no problem there I believe.

I did just one building, but I don´t thin that is the issue… I think this version is the same that I had before (I am using this since beginning of may, after you stopped with the Arcgis tool)

I am preparing a course for a summer school about urban modeling tools, I believe CEA is a great tool, but sometimes it seems it is too hardcoded for the examples in Zurich and Singapure.

I tried in other locations, always the same problem

From: Daren Thomas notifications@github.com Sent: 26 June 2019 08:45 To: architecture-building-systems/CityEnergyAnalyst CityEnergyAnalyst@noreply.github.com Cc: CarlosSantosSilvaTecnico carlos.santos.silva@tecnico.ulisboa.pt; Mention mention@noreply.github.com Subject: Re: [architecture-building-systems/CityEnergyAnalyst] Simple project creation with the Dashboard does not work (#2091)

@CarlosSantosSilvaTecnico https://github.com/CarlosSantosSilvaTecnico I just tried to reproduce this with the following steps:

I had no issues.

What version are you running? How did you install? What buildings are you selecting?

— You are receiving this because you were mentioned. Reply to this email directly, view it on GitHub https://github.com/architecture-building-systems/CityEnergyAnalyst/issues/2091?email_source=notifications&email_token=AJLUAFK6FRHSEOHMUIX6433P4MM6NA5CNFSM4H3FUXY2YY3PNVWWK3TUL52HS4DFVREXG43VMVBW63LNMVXHJKTDN5WW2ZLOORPWSZGODYSUV4Q#issuecomment-505760498 , or mute the thread https://github.com/notifications/unsubscribe-auth/AJLUAFMVQPCWC64N6AF5XQTP4MM6NANCNFSM4H3FUXYQ .

daren-thomas commented 5 years ago

@CarlosSantosSilvaTecnico I'm sorry, I don't see the windows step recorder file?

CarlosSantosSilvaTecnico commented 5 years ago

Sorry, please see the PDF

From: Daren Thomas notifications@github.com Sent: 26 June 2019 09:44 To: architecture-building-systems/CityEnergyAnalyst CityEnergyAnalyst@noreply.github.com Cc: CarlosSantosSilvaTecnico carlos.santos.silva@tecnico.ulisboa.pt; Mention mention@noreply.github.com Subject: Re: [architecture-building-systems/CityEnergyAnalyst] Simple project creation with the Dashboard does not work (#2091)

@CarlosSantosSilvaTecnico https://github.com/CarlosSantosSilvaTecnico I'm sorry, I don't see the windows step recorder?

— You are receiving this because you were mentioned. Reply to this email directly, https://github.com/architecture-building-systems/CityEnergyAnalyst/issues/2091?email_source=notifications&email_token=AJLUAFIC2THO5K5PMVSJBGDP4MT6ZA5CNFSM4H3FUXY2YY3PNVWWK3TUL52HS4DFVREXG43VMVBW63LNMVXHJKTDN5WW2ZLOORPWSZGODYSZYCI#issuecomment-505781257 view it on GitHub, or https://github.com/notifications/unsubscribe-auth/AJLUAFK6SUQLGE5AJO5LAQ3P4MT6ZANCNFSM4H3FUXYQ mute the thread.

daren-thomas commented 5 years ago

@CarlosSantosSilvaTecnico which PDF? Could you try adding it on the github interface (as opposed to email?)

CarlosSantosSilvaTecnico commented 5 years ago

Dear Daren, i follow all your steps...the one i might be doing wrong is selecting 2 buildings... in the picture that follows when i finish one polygon and move to other building, CEA considers the same polygon...

2_buildings

daren-thomas commented 5 years ago

@CarlosSantosSilvaTecnico did you update to the newest CEA? I'm unclear on exactly where the problem is?

CarlosSantosSilvaTecnico commented 5 years ago

I did reinstall, followed all the steps... the error in the console is alwyas a problem in the REFERENCE...

her eis a link to a video to make it more clear....

https://www.dropbox.com/s/gcgwj6jm6o70zbp/City%20Energy%20Analyst%20_%20New%20Project%20-%20Google%20Chrome%2026_06_2019%2011_39_49.mp4?dl=0

daren-thomas commented 5 years ago

@CarlosSantosSilvaTecnico can you please post the contents of the Dashboard output (the terminal which shows the error? (basically, more of what you posted in the original description of your issue). Also, can you check at the top of the output what version of CEA is being used?

@reyery do you have any idea what is causing this? if i remember correctly, this was fixed a few sprints ago, right?

CarlosSantosSilvaTecnico commented 5 years ago

CEA 2.16 (just downloaded and installed from scratched again) The full output is this:

INFO:werkzeug: * Running on http://localhost:5050/ (Press CTRL+C to quit) INFO:werkzeug:127.0.0.1 - - [26/Jun/2019 13:09:57] "GET / HTTP/1.1" 302 - INFO:werkzeug:127.0.0.1 - - [26/Jun/2019 13:09:57] "GET /landing/welcome HTTP/1.1" 200 - INFO:werkzeug:127.0.0.1 - - [26/Jun/2019 13:09:57] "GET /landing/welcome HTTP/1.1" 200 - INFO:werkzeug:127.0.0.1 - - [26/Jun/2019 13:11:44] "GET /landing/create-project HTTP/1.1" 200 - INFO:werkzeug:127.0.0.1 - - [26/Jun/2019 13:11:44] "GET /landing/create-project HTTP/1.1" 200 - join_paths(['C:\', 'Users', 'Carlos', 'Documents', 'CityEnergyAnalyst', 'Projects', 'singapure'], 1) --> C:\ join_paths(['C:\', 'Users', 'Carlos', 'Documents', 'CityEnergyAnalyst', 'Projects', 'singapure'], 2) --> C:\Users join_paths(['C:\', 'Users', 'Carlos', 'Documents', 'CityEnergyAnalyst', 'Projects', 'singapure'], 3) --> C:\Users\Carlos join_paths(['C:\', 'Users', 'Carlos', 'Documents', 'CityEnergyAnalyst', 'Projects', 'singapure'], 4) --> C:\Users\Carlos\Documents join_paths(['C:\', 'Users', 'Carlos', 'Documents', 'CityEnergyAnalyst', 'Projects', 'singapure'], 5) --> C:\Users\Carlos\Documents\CityEnergyAnalyst join_paths(['C:\', 'Users', 'Carlos', 'Documents', 'CityEnergyAnalyst', 'Projects', 'singapure'], 6) --> C:\Users\Carlos\Documents\CityEnergyAnalyst\Projects join_paths(['C:\', 'Users', 'Carlos', 'Documents', 'CityEnergyAnalyst', 'Projects', 'singapure'], 7) --> C:\Users\Carlos\Documents\CityEnergyAnalyst\Projects\singapure INFO:werkzeug:127.0.0.1 - - [26/Jun/2019 13:11:47] "GET /landing/open-folder-dialog/general:project HTTP/1.1" 200 - join_paths([u'C:\', u'Users', u'Carlos', u'Documents', u'CityEnergyAnalyst', u'Projects'], 1) --> C:\ join_paths([u'C:\', u'Users', u'Carlos', u'Documents', u'CityEnergyAnalyst', u'Projects'], 2) --> C:\Users join_paths([u'C:\', u'Users', u'Carlos', u'Documents', u'CityEnergyAnalyst', u'Projects'], 3) --> C:\Users\Carlos join_paths([u'C:\', u'Users', u'Carlos', u'Documents', u'CityEnergyAnalyst', u'Projects'], 4) --> C:\Users\Carlos\Documents join_paths([u'C:\', u'Users', u'Carlos', u'Documents', u'CityEnergyAnalyst', u'Projects'], 5) --> C:\Users\Carlos\Documents\CityEnergyAnalyst join_paths([u'C:\', u'Users', u'Carlos', u'Documents', u'CityEnergyAnalyst', u'Projects'], 6) --> C:\Users\Carlos\Documents\CityEnergyAnalyst\Projects INFO:werkzeug:127.0.0.1 - - [26/Jun/2019 13:11:50] "GET /landing/open-folder-dialog/general:project?current_folder=C%3A%5CUsers%5CCarlos%5CDocuments%5CCityEnergyAnalyst%5CProjects&folder=. HTTP/1.1" 200 - INFO:werkzeug:127.0.0.1 - - [26/Jun/2019 13:11:50] "GET /landing/create-project HTTP/1.1" 200 - INFO:werkzeug:127.0.0.1 - - [26/Jun/2019 13:11:56] "POST /landing/create-project/save HTTP/1.1" 302 - INFO:werkzeug:127.0.0.1 - - [26/Jun/2019 13:11:56] "GET /landing/project-overview HTTP/1.1" 200 - INFO:werkzeug:127.0.0.1 - - [26/Jun/2019 13:11:56] "GET /landing/project-overview HTTP/1.1" 200 - INFO:werkzeug:127.0.0.1 - - [26/Jun/2019 13:11:58] "GET /landing/create-scenario HTTP/1.1" 200 - INFO:werkzeug:127.0.0.1 - - [26/Jun/2019 13:11:58] "GET /landing/create-scenario HTTP/1.1" 200 - DEBUG:fiona:Creating a not-responsible GDALEnv in drivers() DEBUG:Fiona:GDAL_DATA: C:\Users\Carlos\Documents\CityEnergyAnalyst\Dependencies\Python\Library\share\gdal DEBUG:Fiona:PROJ_LIB: C:\Users\Carlos\Documents\CityEnergyAnalyst\Dependencies\Python\Library\share DEBUG:Fiona:GDAL_DATA: C:\Users\Carlos\Documents\CityEnergyAnalyst\Dependencies\Python\Library\share\gdal DEBUG:Fiona:PROJ_LIB: C:\Users\Carlos\Documents\CityEnergyAnalyst\Dependencies\Python\Library\share DEBUG:Fiona:Created layer site DEBUG:Fiona:Created fields DEBUG:Fiona:Writing started DEBUG:Fiona:Creating feature in layer: {'geometry': {'type': 'Polygon', 'coordinates': (((5.716758, 45.191267), (5.716758, 45.191267), (5.717027, 45.191244), (5.717692, 45.191206), (5.717896, 45.191191), (5.717799, 45.191456), (5.717778, 45.191509), (5.716758, 45.19132), (5.716758, 45.19132), (5.716758, 45.191267)),)}, 'type': 'Feature', 'id': '0', 'properties': {}} DEBUG:Fiona:Adding ring ((5.716758, 45.191267), (5.716758, 45.191267), (5.717027, 45.191244), (5.717692, 45.191206), (5.717896, 45.191191), (5.717799, 45.191456), (5.717778, 45.191509), (5.716758, 45.19132), (5.716758, 45.19132), (5.716758, 45.191267)) DEBUG:Fiona:Adding point (5.716758, 45.191267) DEBUG:Fiona:Adding point (5.716758, 45.191267) DEBUG:Fiona:Adding point (5.717027, 45.191244) DEBUG:Fiona:Adding point (5.717692, 45.191206) DEBUG:Fiona:Adding point (5.717896, 45.191191) DEBUG:Fiona:Adding point (5.717799, 45.191456) DEBUG:Fiona:Adding point (5.717778, 45.191509) DEBUG:Fiona:Adding point (5.716758, 45.19132) DEBUG:Fiona:Adding point (5.716758, 45.19132) DEBUG:Fiona:Adding point (5.716758, 45.191267) DEBUG:Fiona:Closing ring DEBUG:Fiona:Built ring DEBUG:Fiona:Added ring ((5.716758, 45.191267), (5.716758, 45.191267), (5.717027, 45.191244), (5.717692, 45.191206), (5.717896, 45.191191), (5.717799, 45.191456), (5.717778, 45.191509), (5.716758, 45.19132), (5.716758, 45.19132), (5.716758, 45.191267)) DEBUG:Fiona:Flushed data source cache DEBUG:fiona.collection:Flushed buffer DEBUG:fiona.collection:Stopped session site.shp file created at C:\Users\Carlos\Documents\CityEnergyAnalyst\Projects\Grenoble\baseline\inputs\building-geometry\site.shp City Energy Analyst version 2.16 Running cea zone-helper with the following parameters:

daren-thomas commented 5 years ago

@CarlosSantosSilvaTecnico thank you :)

@reyery: any ideas?

reyery commented 5 years ago

Have been trying to emulate and follow the steps taken as closely as possible but I was unable to recreate the error on my end.

@reyery do you have any idea what is causing this? if i remember correctly, this was fixed a few sprints ago, right?

I don't think it is the same issue here, those were to do with files created by zone-helper. But in this case the zone-helper could not even create the files.

Not too sure why REFERENCE could not be found since it would have been created here. https://github.com/architecture-building-systems/CityEnergyAnalyst/blob/5ae082c2ea2c0272bf5998fea0c6f2c37ffa21b6/cea/datamanagement/zone_helper.py#L45-L53

There might be something else that I am missing here. Will test this again on a new windows VM to see if it has anything to do with the installation.

CarlosSantosSilvaTecnico commented 5 years ago

I dont know if it helps, but i add ghe zip... he basiclly creates the site shape files but not the zone, district etc... inputs.zip

daren-thomas commented 5 years ago

We can't replicate this error.

CarlosSantosSilvaTecnico commented 5 years ago

OK, thanks for the time spent, i have tried in another computer and it does not work either. I will wait for 2.17 version.

daren-thomas commented 5 years ago

I was able to reproduce the error when setting floors_ag and floors_bg in the zone settings while creating a new scenario.

daren-thomas commented 5 years ago

ah. i see the PR #2108 was already merged.

daren-thomas commented 5 years ago

This will be part of the 2.17 release.