Jump to content
Simio Forum


  • Content Count

  • Joined

  • Last visited

  • Days Won


Posts posted by jdoran

  1. Nope, the 64bit version still will not open the model with a massive data table (at least not within the 5mins I was willing to wait for it).

    I left the model opening over night (via the 32bit client), and came in this morning to it opened. I have removed the datatable, and will have to explore using a database, etc.

  2. Has anyone else experienced significant performance hits when dealing with large tables in their models?

    One of my tables has a bit over 230k rows. Since adding the table the model can take up to 30seconds to save (on a SSD), and since closing the model, it no longer seems to load.

    I can see that tables are added directly into the model xml data which does not seem to make much sense.



  3. So each wait step would require a state/property, a timer and two assign blocks. It's simpler than making the re-usable process with passed tokens, and probably more durable.

    Thanks. I'll have to go back and update my models, and keep it in mind in the future.

  4. This fixed the outstanding bug where writing in an experiment would dump all csv files in the simulation root directory, ignoring the relative directories you specify in the file path in the file element. The fix was trivial, and I am sure I have raised it several times both on this forum. I made the fix a few months ago, and have kept meaning to post it here (if indeed I have not already). The problem with unofficial fixes is that it is another moving part to update, keep track of, and adds to installation complexity. I have lost previous fixes twice (due to fresh re-installs).

    Essentially "fileNameWithoutExtension = System.IO.Path.GetFileNameWithoutExtension(fileName);" was the culprit.

    I changed the "_writerFileName" directive from using the above variable to:

    _writerFileName = "fileName + "_" + simioScenarioName + "_Rep" + simioReplicationNumber + fileExtension;"

    I could do something neater (as the current output will have a ".csv" in the middle of the name), but did not spend any time on this. It would be appreciated if this was fixed and applied to the official write block (even if as a toggleable option), as due to the over-zealous licensing terms, the DLL will not load on an unlicensed client... meaning I have to choose between having the bug fixed and not dumping hundreds of thousands of CSV files in my simulation root... or causing clients considerable inconvenience by writing hundreds of thousands of CSV files into their simulation root.

    Here is the relevant code extract in the file element:

                if (String.IsNullOrEmpty(fileName) == false)
                   string fileRoot = null;
                   string fileDirectoryName = null;
                   string fileNameWithoutExtension = null;
                   string fileExtension = null;
                       fileRoot = System.IO.Path.GetPathRoot(fileName);
                       fileDirectoryName = System.IO.Path.GetDirectoryName(fileName);
                       fileNameWithoutExtension = System.IO.Path.GetFileNameWithoutExtension(fileName);
                       fileExtension = System.IO.Path.GetExtension(fileName);
                   catch (ArgumentException e)
                       data.ExecutionContext.ExecutionInformation.ReportError(String.Format("Failed to create runtime file element. Message: {0}", e.Message));
                   string simioProjectFolder = _data.ExecutionContext.ExecutionInformation.ProjectFolder;
                   string simioExperimentName = _data.ExecutionContext.ExecutionInformation.ExperimentName;
                   string simioScenarioName = _data.ExecutionContext.ExecutionInformation.ScenarioName;
                   string simioReplicationNumber = _data.ExecutionContext.ExecutionInformation.ReplicationNumber.ToString();
                   if (String.IsNullOrEmpty(fileDirectoryName) || String.IsNullOrEmpty(fileRoot))
                       fileDirectoryName = simioProjectFolder;
                       fileName = fileDirectoryName + "\\" + fileName;
                   _readerFileName = fileName;
                   if (String.IsNullOrEmpty(simioExperimentName))
                       _writerFileName = fileName;
                       _writerFileName = fileName + "_" + simioScenarioName + "_Rep" + simioReplicationNumber + fileExtension;


    Using relative file paths worked at one stage, and was later broken. Below are two threads with work around un-offical dlls that probably implement the fix nicer.

    10/07/2012 - http://www.simio.com/forums/viewtopic.php?f=19&t=829

    07/12/2012 - http://www.simio.com/forums/viewtopic.php?f=20&t=987



  5. I dont recall making a variable timer being an easy thing to do. I believe they required their own state variable.

    It will make the code harder to read and debug too.

    I currently execute side processes with delays that fire events. This is even worse in some ways as it makes multiple tokens that then need to be handled.

  6. Is it possible to implement a wait step that either waits for a specified time, or for an event to be fired (which ever comes first).

    I hacked together a model where I execute a process before the wait step, that delays for the time and fires an event. I then simply listen for either event at the wait step.

    I don't think this is very neat. Is there a better way?

    I can see there are timer elements, but I don't see how you would invoke one simply to act as a countdown.

  7. Just a tip from briefly reading your description:

    You will want to look at some of the SimBits around entities getting transported by transporters. In general I advise just looking at each SimBit as regardless of name, there are some interesting concepts/techniques that will apply regardless of the scenario you are trying to simulate.

    I will dig out the SimBit names when my model stops running. =P

  8. I was using entities to seize transporters as they entered servers, I then abstracted these chains of servers into sub-models, and then sub-models of these sub-models such that I could re-arrange and order these chains easily, and so I could have 12 or so of these long chains encapsulated in single objects that sit in the top level model where the transporters and entities start.

    When the entity enters one of these servers, it is added into the allocation queue for the transporter (I might be referring to the token... but for all intents and purpose it is the entity as these tokens are created and destroyed), you can verify this by clicking on a transporter and drawing a queue for its AllocationQueue and hovering your mouse over what turns up inside it.

    My problem stemmed from all of these asynchronous requests hitting the transporters making them all deadlock due to the ordering of the allocation queue. I ended up making proper expressions to evaluate these queues and also expression to avoid the extra seizes until they absolutely had to be made.

  9. I don't think I solved this one. I think I worked around it by making better logic to ensure that sure I didn't get into dead-locks in the first place.

    It is kind of awkward to do a looping find and remove on the AllocationQueue over many transporters before every seize in the model just to try and keep synchronicity between different levels of nested models that can't directly see each other.

    The downside with messing with the allocation queue (by either removing or only seizing when conditions are ideal), is that you can't generate any kind of Gantt chart to see what is SPECIFICALLY constrained.

    I think I put this in the too hard basket.

  10. Those are just the default schedules, modified to be a straight 30minute interval.



    As for that expression:

    StandardWeek.TimeUntilNextValue(TimeNow) * 60 <= 0.6

    In the latest sprint, we can now tap into the schedules to look at how long until the next scheduled change.

    Schedule || SIMIO FUNCTION || REFERENCE POINT TIME || 60 (to convert from hours to minutes) || 0.6 seconds (because we are using delays, we need to make sure we have a big enough window that we are likely to check within)

    Make sure you are running the latest copy of Simio.

  11. From Simio Support:

    See attached model.

    1) Server Reference in Parent Model must include sub model when referencing server (e.g.Model2_1.Server1).

    2) In the sub model when you added the match condition on the Search, the autocomplete was not finding the property in the repeating property. If you just type in the syntax, it works. "Entity.Location.Parent == Table1.Server"

    3) I don't think the Auto-set table reference will work. You will need to add the row number when referencing a property on a table (e.g. For process time for Server2 = Table1[2].RealProperty1 ).

    Hope this addresses your issue with repeat groups.


  • Create New...