Menu Close

katie-birchard

Forum Replies Created

Viewing 9 posts - 16 through 24 (of 24 total)
  • Author
    Posts
  • in reply to: Errors running the Omniscape example #21541
    katie-birchardkatie-birchard
    Keymaster

    Hi David,

    Thanks for your perseverance with this issue. It is definitely a strange one!

    First, how did you look at your PATH variable? When viewing the PATH variable from the Windows Control Panel or printing out the results of running “path” in the command prompt, the “.” (dots) are not visible. They are only visible when calling os.environ[“PATH”] from a Python interpreter.

    Second, you were able to import rasterio and pysyncrosim no problem from the Python interpreter because the issue only arises when running omniscape from the SyncroSim User Interface. This is because rasterio is looking for a GDAL DLL in all paths specified from running os.environ[“PATH”] in Python, and when running from the SyncroSim UI, the current directory (i.e., “.”) also contains a GDAL DLL. On import, rasterio enters all paths that contain a GDAL DLL into the os.add_dll_directory() function, including the “.”, which is invalid and results in the error you see here. When running from the Python interpreter, the current directory (i.e., “.”) does not contain a GDAL DLL, so all works as expected.

    Cheers,
    Katie

    in reply to: adding transitions using Pysyncrosim #21331
    katie-birchardkatie-birchard
    Keymaster

    Hi David,

    Version 1.0.19 of pysyncrosim is now available from conda-forge and PyPI. We’ve added two new arguments to the save_datasheet() method – append and force. When saving a Project-scoped Datasheet, the default is for append to be set to True, since overwriting this Datasheet can have consequences on Scenario-scoped Datasheets that reference Project-scoped Datasheet values. In order to overwrite a Project-scoped Datasheet, you must set append to False and force to True. This is the same functionality as the saveDatasheet() function in rsyncrosim. You can also now delete information in a Datasheet by saving an empty DataFrame (with force=True for Project-scoped Datasheets).

    Hope this makes your modeling a bit easier!

    Katie

    in reply to: ST-Sim Library with an external program example #21302
    katie-birchardkatie-birchard
    Keymaster

    There will be an example of an external program script using pysyncrosim forthcoming.

    in reply to: adding transitions using Pysyncrosim #21299
    katie-birchardkatie-birchard
    Keymaster

    Hi David,

    It looks like there is a bug in save_datasheet(). You should be able to overwrite the currently saved Datasheet and there should be no issue in saving an empty DataFrame as a Datasheet. We’ll fix these issues for the next release (v1.0.19) as well. Thanks for letting us know!

    Cheers,
    Katie

    in reply to: adding transitions using Pysyncrosim #21294
    katie-birchardkatie-birchard
    Keymaster

    Hi David,

    Currently, the only way to add to existing Datasheets in pysyncrosim is to reload the Datasheet as a pandas DataFrame, concatenate with your new data, and then overwrite the old saved Datasheet (as you are doing in your example above). However, the next version of pysyncrosim (v1.0.19) will have a new append argument in the save_datasheet() method that will take advantage of the SyncroSim core software to efficiently append new data to existing Datasheets. The next version will become available early next week.

    Cheers,
    Katie

    in reply to: pysyncrosim – scenarios, datafeeds and datasheets #20952
    katie-birchardkatie-birchard
    Keymaster

    Hi David,

    The feature that you suggested in which you are able to determine which datasheets are “active” is now available in pysyncrosim. It follows the same idea as what was already implemented in rsyncrosim – in rsyncrosim, if you call datasheet(myScenario, optional = TRUE), you will see a “data” column that contains “yes” or “no” for whether or not the datasheet contains data (i.e., is “active”). In the latest version of pysyncrosim we have added a similar feature, where if you call myScenario.datasheets(optional=True) you will find this same “data” column.

    You can now install the latest version of pysyncrosim from conda or PyPI following the instructions in the docs: https://pysyncrosim.readthedocs.io/en/latest/index.html

    Thanks for the suggestion and let us know if you think of any other useful features!

    in reply to: Can’t export Excel spreadsheets #20778
    katie-birchardkatie-birchard
    Keymaster

    Another thing to try if the above doesn’t work is a full online repair of Office 365. You can do this by navigating to “Programs and Features”, right-clicking on the “Microsoft 365” Application, and selecting “Change”. In the Microsoft pop-up box select the “Online Repair”, then click “Repair”.

    in reply to: Can’t export Excel spreadsheets #20777
    katie-birchardkatie-birchard
    Keymaster

    Hi again,

    In the “Turn Windows features on or off”, under the “.Net Framework 4.8 Advanced Services”, is there also a “WCF Services” box? If so, try selecting the “WCF Services” box, then select “TCP Port Sharing” below “WCF Services”.

    Cheers,
    Katie

    in reply to: Can’t export Excel spreadsheets #20775
    katie-birchardkatie-birchard
    Keymaster

    Hello,

    This error can occur when either Microsoft Excel is not installed, or the .Net programmability support is not enabled for Excel. If you have Excel installed, then you can follow these steps to enable the .Net programmability:

    For Excel 2007:

    1. Navigate to “Programs and Features” on your Windows machine (Control Panel > Programs > Programs and Features).
    2. Open the Microsoft installer to modify Excel.
    3. Make sure that “.Net Programmability Support” is checked, and click “Continue”.

    For Excel 365:

    1. Navigate to “Programs and Features” on your Windows machine (Control Panel > Programs > Programs and Features).
    2. Select “Turn windows features on/off”.
    3. Within this window, select “.NET framework 4.8 Advanced Services”, and click “OK”.

    Please let us know if this does not resolve your issue.

    Regards,
    Katie

Viewing 9 posts - 16 through 24 (of 24 total)