Is there a good way to automatically refresh the source data used in a web scene (i.e. space occupancy data)?The data feeding the layer is currently being updated (same fields and geometry) on a nightly basis after moves and space transfers have been processed. I would like to have this automated if possible without having to continually manually update the web scene by updating the layer(s) in CityEngine and re-exporting the scene. I am using CityEngine Basic 2015.2.
At present there is no way to update portions on a CityEngine webscene, such as an individual building or the attributes stored on a building. Once created they are static files, and we don't plan adding new functionality because they CityEngine webscene are being replaced (eventually) with the new AGOL/Portal based webscenes. Potentially you could write a Python script to load the data, apply a rule, export to a .3ws and then push the result to a specified location creating a nightly refresh.
At 2016.0 or 2016.1 we will be able to take a CityEngine scene, export it as a webscene package, and push that up to Portal or AGOL. However if the occupancy data you publishing is GIS based, you might want to published them directly to a webscene as feature services. Then any time the services updates, the layer in the scene would carry the new attributes or features.
To add on to this, if you decide to go through the python script route, one barrier I have encountered is it can be hard to group layers for web scene publishing through purely the python API. Another concern is scheduling tasks might be complicated by the fact that the interpreter is jython rather than python. Eric is it possible to even point to the interpreter to run python scripts outside of CE? Can scripts be run outside of the CE application?
Thanks for the input! My scripting options might be limited where I am using CE basic. Is there much Python integration I can do with this version, or would I need to look into upgrading CE? I will look into using feature services in the web scene. Might be my best bet at this point...
Just confirming Eric's post. Currently, there is no way to call Python externally without running the CityEngine GUI (in any current version of CE), but this might be something we would look into if there is a demand for it, so thanks for sharing your issues.
To my understanding, CE Basic has no access the python API, which is unfortunate.
Pro or other options using feature service would be the best long term option. Just getting CGA rules packages to work in Pro as I have read and discussed with others requires some modification before use, just keep that in mind.
Good luck. If you have any further questions, I can try to answer them.