Why does my simulation take so long to calculate?
The amount of time taken by S-Risk for calculating results is determined by several factors: (i) the application type, (ii) the number of chemicals, (iii) the number of risk endpoints, (iv) reading and saving data and (v) the calculation queueing procedure.
i) The application type
There is a fundamental difference in the way S-Risk performs calculations for Application II versus Application I & III simulations. The S-Risk model, in essence, is designed to take soil or groundwater concentration measurements as input and calculate human health risks as output. That is exactly what happens in application II: a forward calculation that only needs to be executed once to retrieve exact results.
Applications I and III, however, perform the reverse operation: they calculate soil or groundwater concentrations corresponding to a pre-defined risk level. This implies a backward calculation of the model, and in mathematical terms, this translates to a so-called optimization procedure. Since the core S-Risk model can only calculate forward, i.e., from soil concentrations to risks, the desired concentration value needs to be determined in an iterative manner: the S-Risk model is run repeatedly with varying input soil concentrations. The algorithm varies these concentration values itself, searching for the concentration that causes the risk to be equal to the pre-defined level. Finding this value can take 30 to 40 iterations, causing applications I & III simulations to take a lot longer to complete than application II simulations.
ii) The number of chemicals
A significant part of the S-Risk model calculations needs to be executed for every chemical added to the simulation. The more chemicals are present in a simulation, the longer calculation times are to be expected.
iii) The number of risk endpoints
For a single chemical, S-Risk calculates all possible risk and concentration indexes. This means that the calculation for a chemical with lots of toxicological reference values (e.g., Cadmium) takes longer than the calculation for a chemical with only a few toxicological reference values.
iv) Reading and saving data
Before any calculation can start on the S-Risk calculation server, the server first needs to retrieve the input data from the database server. After calculating results, the newly found values also have to be saved (written) back to the database server. These read/write operations typically take some time, as S-Risk simulations hold quite a lot of information in the form of input parameters, intermediate results and output results. These read/write operations also take longer when more chemicals are involved in the simulation.
v) The calculation queueing procedure
The number of calculation servers behind S-Risk is finite, and every calculation server processes one simulation at a time. This means that on busy moments with lots of customers working on S-Risk simulations, it is possible that all calculation servers are busy. In that case, the next simulation started (by any customer) ends up on a waiting queue, until one of the calculation servers becomes available for a new calculation. Currently, S-Risk has 6 calculation servers available to distribute the simulation workload. This number can be easily revised and expanded as our customer base grows. There are a few simple rules that determine which simulation is run:
- Our basic principle is FIFO: first-in-first-out. If you are the first to submit a simulation, and a calculation server is available, your simulation will be started first;
- The number of simultaneous simulations per account is limited to 2. If you start a 3rd calculation, and already have 2 simulations that are running, the 3rd simulation will be automatically moved to the waiting queue. This way, no single customer can block the calculation capacity for other customers;
- If there are more than 6 simulations in the waiting queue, new requests for calculations will be cancelled. In this case, S-Risk will show you a warning message that the servers are too busy. Try again at a later time.
last modified on 28/09/2016 - 14:18