<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>topic Re: Changing report names in Python tutorial 12 in ArcGIS CityEngine Questions</title>
    <link>https://community.esri.com/t5/arcgis-cityengine-questions/changing-report-names-in-python-tutorial-12/m-p/243244#M3183</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;I’ve changed the way reports where created in CE, and I got it to work, more or less.&lt;/P&gt;&lt;P&gt;How do I access the sum in the report, right now I’m only getting the average?&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Sun, 01 Dec 2019 22:57:16 GMT</pubDate>
    <dc:creator>KennethLindhardt1</dc:creator>
    <dc:date>2019-12-01T22:57:16Z</dc:date>
    <item>
      <title>Changing report names in Python tutorial 12</title>
      <link>https://community.esri.com/t5/arcgis-cityengine-questions/changing-report-names-in-python-tutorial-12/m-p/243243#M3182</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi, I’m stuck in the CE Python stuff. I need to create a semi colon separated list in a text file summed by the start shape.&lt;/P&gt;&lt;P&gt;So exactly like in Tutorial 12, I’m not getting any errors anymore on export, but as soon as I replace the names from the tutorial 12 to my own names in the reports, it’s not writing the text file any more. As soon as I misspell something in my report, it fails, so I guess I’m getting my strings correct. I also did changed the report names in the tutorial 12, to match my names, and as soon as I do that, it runs, but it don’t write the file.&lt;/P&gt;&lt;P&gt;Anyone knows what going on? Thanks&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;DIV style="color: #d4d4d4; background-color: #1e1e1e; font-weight: normal; font-size: 14px;"&gt;&lt;DIV&gt;&lt;SPAN style="color: #ce9178;"&gt;'''&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN style="color: #ce9178;"&gt;Created on 29/11/2019&lt;/SPAN&gt;&lt;/DIV&gt;&lt;BR /&gt;&lt;DIV&gt;&lt;SPAN style="color: #ce9178;"&gt;@author: Kenneth Lindhardt&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN style="color: #ce9178;"&gt;'''&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN style="color: #c586c0;"&gt;from&lt;/SPAN&gt;&lt;SPAN style="color: #d4d4d4;"&gt; scripting &lt;/SPAN&gt;&lt;SPAN style="color: #c586c0;"&gt;import&lt;/SPAN&gt;&lt;SPAN style="color: #d4d4d4;"&gt; &lt;/SPAN&gt;&lt;SPAN style="color: #d4d4d4;"&gt;*&lt;/SPAN&gt;&lt;/DIV&gt;&lt;BR /&gt;&lt;DIV&gt;&lt;SPAN style="color: #608b4e;"&gt;# Get a CityEngine instance&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN style="color: #d4d4d4;"&gt;ce &lt;/SPAN&gt;&lt;SPAN style="color: #d4d4d4;"&gt;=&lt;/SPAN&gt;&lt;SPAN style="color: #d4d4d4;"&gt; CE()&lt;/SPAN&gt;&lt;/DIV&gt;&lt;P&gt;&lt;/P&gt;&lt;DIV&gt;&lt;SPAN style="color: #608b4e;"&gt;# Globals&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN style="color: #d4d4d4;"&gt;gInstanceData &lt;/SPAN&gt;&lt;SPAN style="color: #d4d4d4;"&gt;=&lt;/SPAN&gt;&lt;SPAN style="color: #d4d4d4;"&gt; &lt;/SPAN&gt;&lt;SPAN style="color: #ce9178;"&gt;""&lt;/SPAN&gt;&lt;SPAN style="color: #d4d4d4;"&gt; &lt;/SPAN&gt;&lt;SPAN style="color: #608b4e;"&gt;# global string that collects all data to be written&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN style="color: #d4d4d4;"&gt;gInstanceCount &lt;/SPAN&gt;&lt;SPAN style="color: #d4d4d4;"&gt;=&lt;/SPAN&gt;&lt;SPAN style="color: #d4d4d4;"&gt; &lt;/SPAN&gt;&lt;SPAN style="color: #b5cea8;"&gt;0&lt;/SPAN&gt;&lt;SPAN style="color: #d4d4d4;"&gt; &lt;/SPAN&gt;&lt;SPAN style="color: #608b4e;"&gt;# global count to enumerate all instances&lt;/SPAN&gt;&lt;/DIV&gt;&lt;BR /&gt;&lt;DIV&gt;&lt;SPAN style="color: #d4d4d4;"&gt; &lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN style="color: #d4d4d4;"&gt; &lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN style="color: #608b4e;"&gt;# Called for each initial shape after generation.&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN style="color: #569cd6;"&gt;def&lt;/SPAN&gt;&lt;SPAN style="color: #d4d4d4;"&gt; &lt;/SPAN&gt;&lt;SPAN style="color: #dcdcaa;"&gt;finishModel&lt;/SPAN&gt;&lt;SPAN style="color: #d4d4d4;"&gt;(&lt;/SPAN&gt;&lt;SPAN style="color: #9cdcfe;"&gt;exportContextOID&lt;/SPAN&gt;&lt;SPAN style="color: #d4d4d4;"&gt;, &lt;/SPAN&gt;&lt;SPAN style="color: #9cdcfe;"&gt;shapeOID&lt;/SPAN&gt;&lt;SPAN style="color: #d4d4d4;"&gt;, &lt;/SPAN&gt;&lt;SPAN style="color: #9cdcfe;"&gt;modelOID&lt;/SPAN&gt;&lt;SPAN style="color: #d4d4d4;"&gt;&lt;span class="lia-unicode-emoji" title=":disappointed_face:"&gt;😞&lt;/span&gt;&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN style="color: #d4d4d4;"&gt; &lt;/SPAN&gt;&lt;SPAN style="color: #569cd6;"&gt;global&lt;/SPAN&gt;&lt;SPAN style="color: #d4d4d4;"&gt; gInstanceData, gInstanceCount&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN style="color: #d4d4d4;"&gt; model &lt;/SPAN&gt;&lt;SPAN style="color: #d4d4d4;"&gt;=&lt;/SPAN&gt;&lt;SPAN style="color: #d4d4d4;"&gt; Model(modelOID)&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN style="color: #d4d4d4;"&gt; &lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN style="color: #d4d4d4;"&gt; &lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN style="color: #d4d4d4;"&gt; &lt;/SPAN&gt;&lt;SPAN style="color: #c586c0;"&gt;if&lt;/SPAN&gt;&lt;SPAN style="color: #d4d4d4;"&gt;(model.getReports().has_key(&lt;/SPAN&gt;&lt;SPAN style="color: #ce9178;"&gt;'Bygningsanvendelse'&lt;/SPAN&gt;&lt;SPAN style="color: #d4d4d4;"&gt;)): &lt;/SPAN&gt;&lt;SPAN style="color: #608b4e;"&gt;# only write entry if report data available&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN style="color: #d4d4d4;"&gt; l &lt;/SPAN&gt;&lt;SPAN style="color: #d4d4d4;"&gt;=&lt;/SPAN&gt;&lt;SPAN style="color: #d4d4d4;"&gt; &lt;/SPAN&gt;&lt;SPAN style="color: #dcdcaa;"&gt;len&lt;/SPAN&gt;&lt;SPAN style="color: #d4d4d4;"&gt;(model.getReports()[&lt;/SPAN&gt;&lt;SPAN style="color: #ce9178;"&gt;'Bygningsanvendelse'&lt;/SPAN&gt;&lt;SPAN style="color: #d4d4d4;"&gt;]) &lt;/SPAN&gt;&lt;SPAN style="color: #608b4e;"&gt;# there might be more than one asset per model, therefore loop&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN style="color: #d4d4d4;"&gt; &lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN style="color: #d4d4d4;"&gt; &lt;/SPAN&gt;&lt;SPAN style="color: #c586c0;"&gt;for&lt;/SPAN&gt;&lt;SPAN style="color: #d4d4d4;"&gt; i &lt;/SPAN&gt;&lt;SPAN style="color: #569cd6;"&gt;in&lt;/SPAN&gt;&lt;SPAN style="color: #d4d4d4;"&gt; &lt;/SPAN&gt;&lt;SPAN style="color: #dcdcaa;"&gt;range&lt;/SPAN&gt;&lt;SPAN style="color: #d4d4d4;"&gt;(&lt;/SPAN&gt;&lt;SPAN style="color: #b5cea8;"&gt;0&lt;/SPAN&gt;&lt;SPAN style="color: #d4d4d4;"&gt;,l):&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN style="color: #d4d4d4;"&gt; instanceData &lt;/SPAN&gt;&lt;SPAN style="color: #d4d4d4;"&gt;=&lt;/SPAN&gt;&lt;SPAN style="color: #d4d4d4;"&gt; processInstance(model.getReports(),gInstanceCount, i&lt;/SPAN&gt;&lt;SPAN style="color: #d4d4d4;"&gt;-&lt;/SPAN&gt;&lt;SPAN style="color: #b5cea8;"&gt;1&lt;/SPAN&gt;&lt;SPAN style="color: #d4d4d4;"&gt;)&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN style="color: #d4d4d4;"&gt; gInstanceData &lt;/SPAN&gt;&lt;SPAN style="color: #d4d4d4;"&gt;=&lt;/SPAN&gt;&lt;SPAN style="color: #d4d4d4;"&gt; gInstanceData&lt;/SPAN&gt;&lt;SPAN style="color: #d4d4d4;"&gt;+&lt;/SPAN&gt;&lt;SPAN style="color: #d4d4d4;"&gt;instanceData&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN style="color: #d4d4d4;"&gt; gInstanceCount &lt;/SPAN&gt;&lt;SPAN style="color: #d4d4d4;"&gt;=&lt;/SPAN&gt;&lt;SPAN style="color: #d4d4d4;"&gt; gInstanceCount&lt;/SPAN&gt;&lt;SPAN style="color: #d4d4d4;"&gt;+&lt;/SPAN&gt;&lt;SPAN style="color: #b5cea8;"&gt;1&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN style="color: #d4d4d4;"&gt; &lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN style="color: #d4d4d4;"&gt; &lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN style="color: #608b4e;"&gt;# Called after all initial shapes are generated.&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN style="color: #569cd6;"&gt;def&lt;/SPAN&gt;&lt;SPAN style="color: #d4d4d4;"&gt; &lt;/SPAN&gt;&lt;SPAN style="color: #dcdcaa;"&gt;finishExport&lt;/SPAN&gt;&lt;SPAN style="color: #d4d4d4;"&gt;(&lt;/SPAN&gt;&lt;SPAN style="color: #9cdcfe;"&gt;exportContextOID&lt;/SPAN&gt;&lt;SPAN style="color: #d4d4d4;"&gt;&lt;span class="lia-unicode-emoji" title=":disappointed_face:"&gt;😞&lt;/span&gt;&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN style="color: #d4d4d4;"&gt; &lt;/SPAN&gt;&lt;SPAN style="color: #569cd6;"&gt;global&lt;/SPAN&gt;&lt;SPAN style="color: #d4d4d4;"&gt; gInstanceData, gInstanceCount&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN style="color: #d4d4d4;"&gt; &lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN style="color: #d4d4d4;"&gt; &lt;/SPAN&gt;&lt;SPAN style="color: #608b4e;"&gt;## path of the output file&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN style="color: #d4d4d4;"&gt; &lt;/SPAN&gt;&lt;SPAN style="color: #9cdcfe;"&gt;file&lt;/SPAN&gt;&lt;SPAN style="color: #d4d4d4;"&gt; &lt;/SPAN&gt;&lt;SPAN style="color: #d4d4d4;"&gt;=&lt;/SPAN&gt;&lt;SPAN style="color: #d4d4d4;"&gt; ce.toFSPath(&lt;/SPAN&gt;&lt;SPAN style="color: #ce9178;"&gt;"aseets"&lt;/SPAN&gt;&lt;SPAN style="color: #d4d4d4;"&gt;)&lt;/SPAN&gt;&lt;SPAN style="color: #d4d4d4;"&gt;+&lt;/SPAN&gt;&lt;SPAN style="color: #ce9178;"&gt;"/instanceMapHaps.txt"&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN style="color: #d4d4d4;"&gt; &lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN style="color: #d4d4d4;"&gt; &lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN style="color: #d4d4d4;"&gt; &lt;/SPAN&gt;&lt;SPAN style="color: #608b4e;"&gt;## write collected data to file&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN style="color: #d4d4d4;"&gt; &lt;/SPAN&gt;&lt;SPAN style="color: #608b4e;"&gt;# writeFile(file, gInstanceData)&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN style="color: #d4d4d4;"&gt; &lt;/SPAN&gt;&lt;SPAN style="color: #608b4e;"&gt;# print str(gInstanceCount)+" instances written to "+file +"\n"&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN style="color: #d4d4d4;"&gt; &lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN style="color: #d4d4d4;"&gt; &lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN style="color: #d4d4d4;"&gt; &lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN style="color: #d4d4d4;"&gt; &lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN style="color: #d4d4d4;"&gt; &lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN style="color: #ce9178;"&gt;''' Collect the instance information in a tab-separated string'''&lt;/SPAN&gt;&lt;SPAN style="color: #d4d4d4;"&gt; &lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN style="color: #569cd6;"&gt;def&lt;/SPAN&gt;&lt;SPAN style="color: #d4d4d4;"&gt; &lt;/SPAN&gt;&lt;SPAN style="color: #dcdcaa;"&gt;processInstance&lt;/SPAN&gt;&lt;SPAN style="color: #d4d4d4;"&gt;(&lt;/SPAN&gt;&lt;SPAN style="color: #9cdcfe;"&gt;reports&lt;/SPAN&gt;&lt;SPAN style="color: #d4d4d4;"&gt;, &lt;/SPAN&gt;&lt;SPAN style="color: #9cdcfe;"&gt;count&lt;/SPAN&gt;&lt;SPAN style="color: #d4d4d4;"&gt;, &lt;/SPAN&gt;&lt;SPAN style="color: #9cdcfe;"&gt;index&lt;/SPAN&gt;&lt;SPAN style="color: #d4d4d4;"&gt;&lt;span class="lia-unicode-emoji" title=":disappointed_face:"&gt;😞&lt;/span&gt;&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN style="color: #d4d4d4;"&gt; &lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN style="color: #d4d4d4;"&gt; &lt;/SPAN&gt;&lt;SPAN style="color: #608b4e;"&gt;## remove path from asset string&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN style="color: #d4d4d4;"&gt; asset &lt;/SPAN&gt;&lt;SPAN style="color: #d4d4d4;"&gt;=&lt;/SPAN&gt;&lt;SPAN style="color: #d4d4d4;"&gt; reports[&lt;/SPAN&gt;&lt;SPAN style="color: #ce9178;"&gt;'Bygningsanvendelse'&lt;/SPAN&gt;&lt;SPAN style="color: #d4d4d4;"&gt;][index] &lt;/SPAN&gt;&lt;SPAN style="color: #608b4e;"&gt;# Overordnet rapport&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN style="color: #d4d4d4;"&gt; asset &lt;/SPAN&gt;&lt;SPAN style="color: #d4d4d4;"&gt;=&lt;/SPAN&gt;&lt;SPAN style="color: #d4d4d4;"&gt; asset.rpartition(&lt;/SPAN&gt;&lt;SPAN style="color: #ce9178;"&gt;"/"&lt;/SPAN&gt;&lt;SPAN style="color: #d4d4d4;"&gt;)[&lt;/SPAN&gt;&lt;SPAN style="color: #b5cea8;"&gt;2&lt;/SPAN&gt;&lt;SPAN style="color: #d4d4d4;"&gt;]&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN style="color: #d4d4d4;"&gt; &lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN style="color: #d4d4d4;"&gt; &lt;/SPAN&gt;&lt;SPAN style="color: #608b4e;"&gt;## prepare the string for the instance map&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN style="color: #d4d4d4;"&gt; text &lt;/SPAN&gt;&lt;SPAN style="color: #d4d4d4;"&gt;=&lt;/SPAN&gt;&lt;SPAN style="color: #d4d4d4;"&gt; &lt;/SPAN&gt;&lt;SPAN style="color: #ce9178;"&gt;"&lt;/SPAN&gt;&lt;SPAN style="color: #569cd6;"&gt;%d&lt;/SPAN&gt;&lt;SPAN style="color: #d7ba7d;"&gt;\t&lt;/SPAN&gt;&lt;SPAN style="color: #ce9178;"&gt;"&lt;/SPAN&gt;&lt;SPAN style="color: #d4d4d4;"&gt; &lt;/SPAN&gt;&lt;SPAN style="color: #d4d4d4;"&gt;%&lt;/SPAN&gt;&lt;SPAN style="color: #d4d4d4;"&gt; count&lt;/SPAN&gt;&lt;SPAN style="color: #f44747;"&gt;;&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN style="color: #d4d4d4;"&gt; text &lt;/SPAN&gt;&lt;SPAN style="color: #d4d4d4;"&gt;+=&lt;/SPAN&gt;&lt;SPAN style="color: #d4d4d4;"&gt; &lt;/SPAN&gt;&lt;SPAN style="color: #ce9178;"&gt;"&lt;/SPAN&gt;&lt;SPAN style="color: #569cd6;"&gt;%s&lt;/SPAN&gt;&lt;SPAN style="color: #d7ba7d;"&gt;\t&lt;/SPAN&gt;&lt;SPAN style="color: #ce9178;"&gt;"&lt;/SPAN&gt;&lt;SPAN style="color: #d4d4d4;"&gt; &lt;/SPAN&gt;&lt;SPAN style="color: #d4d4d4;"&gt;%&lt;/SPAN&gt;&lt;SPAN style="color: #d4d4d4;"&gt; asset&lt;/SPAN&gt;&lt;SPAN style="color: #f44747;"&gt;;&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN style="color: #d4d4d4;"&gt; text &lt;/SPAN&gt;&lt;SPAN style="color: #d4d4d4;"&gt;+=&lt;/SPAN&gt;&lt;SPAN style="color: #d4d4d4;"&gt; &lt;/SPAN&gt;&lt;SPAN style="color: #ce9178;"&gt;"&lt;/SPAN&gt;&lt;SPAN style="color: #569cd6;"&gt;%s&lt;/SPAN&gt;&lt;SPAN style="color: #d7ba7d;"&gt;\t&lt;/SPAN&gt;&lt;SPAN style="color: #569cd6;"&gt;%s&lt;/SPAN&gt;&lt;SPAN style="color: #d7ba7d;"&gt;\t&lt;/SPAN&gt;&lt;SPAN style="color: #569cd6;"&gt;%s&lt;/SPAN&gt;&lt;SPAN style="color: #d7ba7d;"&gt;\n&lt;/SPAN&gt;&lt;SPAN style="color: #ce9178;"&gt;"&lt;/SPAN&gt;&lt;SPAN style="color: #d4d4d4;"&gt; &lt;/SPAN&gt;&lt;SPAN style="color: #d4d4d4;"&gt;%&lt;/SPAN&gt;&lt;SPAN style="color: #d4d4d4;"&gt; (reports[&lt;/SPAN&gt;&lt;SPAN style="color: #ce9178;"&gt;'Bruttoetageareal (BGF)'&lt;/SPAN&gt;&lt;SPAN style="color: #d4d4d4;"&gt;][index], reports[&lt;/SPAN&gt;&lt;SPAN style="color: #ce9178;"&gt;'Bygningens grundareal'&lt;/SPAN&gt;&lt;SPAN style="color: #d4d4d4;"&gt;][index], reports[&lt;/SPAN&gt;&lt;SPAN style="color: #ce9178;"&gt;'Antal etager (bygninger)'&lt;/SPAN&gt;&lt;SPAN style="color: #d4d4d4;"&gt;][index])&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN style="color: #d4d4d4;"&gt; &lt;/SPAN&gt;&lt;SPAN style="color: #608b4e;"&gt;#text += "%.3f\t%.3f\t%.3f\t" % (reports['xrot'][index], reports['yrot'][index], reports['zrot'][index])&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN style="color: #d4d4d4;"&gt; &lt;/SPAN&gt;&lt;SPAN style="color: #608b4e;"&gt;# text += "%.3f\t%.3f\n" % (reports['Tag'][index], reports['Bygningens grundareal'][index]) #Husk at fjerne efter text += Hvis der ændres&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN style="color: #d4d4d4;"&gt; &lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN style="color: #d4d4d4;"&gt; &lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN style="color: #d4d4d4;"&gt; &lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN style="color: #d4d4d4;"&gt; &lt;/SPAN&gt;&lt;SPAN style="color: #c586c0;"&gt;return&lt;/SPAN&gt;&lt;SPAN style="color: #d4d4d4;"&gt; text&lt;/SPAN&gt;&lt;/DIV&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;DIV&gt;&lt;SPAN style="color: #ce9178;"&gt;''' combining data (header and content) and writing file '''&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN style="color: #569cd6;"&gt;def&lt;/SPAN&gt;&lt;SPAN style="color: #d4d4d4;"&gt; &lt;/SPAN&gt;&lt;SPAN style="color: #dcdcaa;"&gt;writeFile&lt;/SPAN&gt;&lt;SPAN style="color: #d4d4d4;"&gt;(&lt;/SPAN&gt;&lt;SPAN style="color: #9cdcfe;"&gt;file&lt;/SPAN&gt;&lt;SPAN style="color: #d4d4d4;"&gt;, &lt;/SPAN&gt;&lt;SPAN style="color: #9cdcfe;"&gt;content&lt;/SPAN&gt;&lt;SPAN style="color: #d4d4d4;"&gt;&lt;span class="lia-unicode-emoji" title=":disappointed_face:"&gt;😞&lt;/span&gt;&lt;/SPAN&gt;&lt;/DIV&gt;&lt;BR /&gt;&lt;DIV&gt;&lt;SPAN style="color: #d4d4d4;"&gt; &lt;/SPAN&gt;&lt;SPAN style="color: #608b4e;"&gt;## prepare the head string&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN style="color: #d4d4d4;"&gt; head &lt;/SPAN&gt;&lt;SPAN style="color: #d4d4d4;"&gt;=&lt;/SPAN&gt;&lt;SPAN style="color: #d4d4d4;"&gt; &lt;/SPAN&gt;&lt;SPAN style="color: #ce9178;"&gt;"nr&lt;/SPAN&gt;&lt;SPAN style="color: #d7ba7d;"&gt;\t&lt;/SPAN&gt;&lt;SPAN style="color: #ce9178;"&gt;asset&lt;/SPAN&gt;&lt;SPAN style="color: #d7ba7d;"&gt;\t&lt;/SPAN&gt;&lt;SPAN style="color: #ce9178;"&gt;Bruttoetageareal (BGF)&lt;/SPAN&gt;&lt;SPAN style="color: #d7ba7d;"&gt;\t&lt;/SPAN&gt;&lt;SPAN style="color: #ce9178;"&gt;Bygningens grundareal&lt;/SPAN&gt;&lt;SPAN style="color: #d7ba7d;"&gt;\t&lt;/SPAN&gt;&lt;SPAN style="color: #ce9178;"&gt;Antal etager (bygninger)&lt;/SPAN&gt;&lt;SPAN style="color: #d7ba7d;"&gt;\n&lt;/SPAN&gt;&lt;SPAN style="color: #ce9178;"&gt;"&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN style="color: #d4d4d4;"&gt; &lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN style="color: #d4d4d4;"&gt; &lt;/SPAN&gt;&lt;SPAN style="color: #608b4e;"&gt;## combine header and content&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN style="color: #d4d4d4;"&gt; content &lt;/SPAN&gt;&lt;SPAN style="color: #d4d4d4;"&gt;=&lt;/SPAN&gt;&lt;SPAN style="color: #d4d4d4;"&gt; head &lt;/SPAN&gt;&lt;SPAN style="color: #d4d4d4;"&gt;+&lt;/SPAN&gt;&lt;SPAN style="color: #d4d4d4;"&gt; content&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN style="color: #d4d4d4;"&gt; &lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN style="color: #d4d4d4;"&gt; &lt;/SPAN&gt;&lt;SPAN style="color: #608b4e;"&gt;# write data to the file&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN style="color: #d4d4d4;"&gt; report &lt;/SPAN&gt;&lt;SPAN style="color: #d4d4d4;"&gt;=&lt;/SPAN&gt;&lt;SPAN style="color: #d4d4d4;"&gt; &lt;/SPAN&gt;&lt;SPAN style="color: #dcdcaa;"&gt;open&lt;/SPAN&gt;&lt;SPAN style="color: #d4d4d4;"&gt;(&lt;/SPAN&gt;&lt;SPAN style="color: #9cdcfe;"&gt;file&lt;/SPAN&gt;&lt;SPAN style="color: #d4d4d4;"&gt;, &lt;/SPAN&gt;&lt;SPAN style="color: #ce9178;"&gt;"w"&lt;/SPAN&gt;&lt;SPAN style="color: #d4d4d4;"&gt;)&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN style="color: #d4d4d4;"&gt; report.write(content)&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN style="color: #d4d4d4;"&gt; report.close() &lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN style="color: #d4d4d4;"&gt; &lt;/SPAN&gt;&lt;/DIV&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;DIV&gt;&lt;/DIV&gt;&lt;/DIV&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 29 Nov 2019 21:45:34 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-cityengine-questions/changing-report-names-in-python-tutorial-12/m-p/243243#M3182</guid>
      <dc:creator>KennethLindhardt1</dc:creator>
      <dc:date>2019-11-29T21:45:34Z</dc:date>
    </item>
    <item>
      <title>Re: Changing report names in Python tutorial 12</title>
      <link>https://community.esri.com/t5/arcgis-cityengine-questions/changing-report-names-in-python-tutorial-12/m-p/243244#M3183</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;I’ve changed the way reports where created in CE, and I got it to work, more or less.&lt;/P&gt;&lt;P&gt;How do I access the sum in the report, right now I’m only getting the average?&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Sun, 01 Dec 2019 22:57:16 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-cityengine-questions/changing-report-names-in-python-tutorial-12/m-p/243244#M3183</guid>
      <dc:creator>KennethLindhardt1</dc:creator>
      <dc:date>2019-12-01T22:57:16Z</dc:date>
    </item>
    <item>
      <title>Re: Changing report names in Python tutorial 12</title>
      <link>https://community.esri.com/t5/arcgis-cityengine-questions/changing-report-names-in-python-tutorial-12/m-p/243245#M3184</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Correction, it seems that it is using the min field from the reports.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 02 Dec 2019 08:20:01 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-cityengine-questions/changing-report-names-in-python-tutorial-12/m-p/243245#M3184</guid>
      <dc:creator>KennethLindhardt1</dc:creator>
      <dc:date>2019-12-02T08:20:01Z</dc:date>
    </item>
    <item>
      <title>Re: Changing report names in Python tutorial 12</title>
      <link>https://community.esri.com/t5/arcgis-cityengine-questions/changing-report-names-in-python-tutorial-12/m-p/243246#M3185</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;In the code above, there is a mistake in the output filepath definition.&amp;nbsp; &lt;SPAN style="font-family: 'courier new', courier, monospace;"&gt;ce.toFSPath()&lt;/SPAN&gt; needs a valid folder name.&amp;nbsp; I think you meant:&lt;/P&gt;&lt;PRE class="language-none line-numbers"&gt;&lt;CODE&gt;file = ce.toFSPath("assets")+"/instanceMapHaps.txt"&lt;SPAN class="line-numbers-rows"&gt;&lt;SPAN&gt;‍&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;/CODE&gt;&lt;/PRE&gt;&lt;P&gt;Once that is changed, your script seems to work.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;As for the reported values, every shape in the scene reports its own value, and this is what is written to the output file.&amp;nbsp; No averages or mins are calculated.&amp;nbsp; If you run the script on three buildings, your output file will have three rows (plus the header), one row for each building.&amp;nbsp; For each building, its stats (i.e. usage, GFA, footprint area, number of floors) are written.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;To get the sum, you&amp;nbsp;could keep a running sum of the desired report similar to how the running count is kept with &lt;SPAN style="font-family: 'courier new', courier, monospace;"&gt;gInstanceCount&lt;/SPAN&gt;.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 21 Jan 2020 17:45:11 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-cityengine-questions/changing-report-names-in-python-tutorial-12/m-p/243246#M3185</guid>
      <dc:creator>CherylLau</dc:creator>
      <dc:date>2020-01-21T17:45:11Z</dc:date>
    </item>
  </channel>
</rss>

