public override void GlobalContext() { base.GlobalContext(); _simulation = _simulationPersister.LoadSimulation(HelperForSpecs.DataFile("not_ok_sim.pkml")); var containerTask = Api.GetContainerTask(); containerTask.AddQuantitiesToSimulationOutputByPath(_simulation, "DERMAL_APPLICATION_AREA|skin_compartment|SC_skin_sublayer|comp10_1|layer1|permeant"); _simulationBatch = new ConcurrentRunSimulationBatch ( _simulation, new SimulationBatchOptions { VariableParameters = new[] { "DERMAL_APPLICATION_AREA|skin_compartment|SC_skin_sublayer|SC_total_thickness", } } ); _parValues = new SimulationBatchRunValues { ParameterValues = new[] { 0.0002 } }; _simulationBatch.AddSimulationBatchRunValues(_parValues); sut.AddSimulationBatch(_simulationBatch); }
public override void GlobalContext() { base.GlobalContext(); _simulation = _simulationPersister.LoadSimulation(HelperForSpecs.DataFile("S1.pkml")); _simulationBatch = new ConcurrentRunSimulationBatch ( _simulation, new SimulationBatchOptions { VariableParameters = new[] { new[] { "Organism", "Liver", "Volume" }.ToPathString(), new[] { "Organism", "Hematocrit" }.ToPathString(), } } ); _parValues1 = new SimulationBatchRunValues { ParameterValues = new[] { 3.5, 0.53 } }; _parValues2 = new SimulationBatchRunValues { ParameterValues = new[] { 3.4, 0.50 } }; _simulationBatch.AddSimulationBatchRunValues(_parValues1); sut.AddSimulationBatch(_simulationBatch); sut.RunConcurrently(); sut.Dispose(); }
protected override void Because() { _simulationBatchRunValues.Add(new SimulationBatchRunValues { InitialValues = new[] { 10.0 }, ParameterValues = new[] { 3.5, 0.53 } }); _simulationBatchRunValues.Add(new SimulationBatchRunValues { InitialValues = new[] { 9.0 }, ParameterValues = new[] { 3.4, 0.50 } }); _simulationBatchRunValues.Add(new SimulationBatchRunValues { InitialValues = new[] { 10.5 }, ParameterValues = new[] { 3.6, 0.55 } }); _concurrentRunSimulationBatch.AddSimulationBatchRunValues(_simulationBatchRunValues[0]); _concurrentRunSimulationBatch.AddSimulationBatchRunValues(_simulationBatchRunValues[1]); _concurrentRunSimulationBatch.AddSimulationBatchRunValues(_simulationBatchRunValues[2]); _ids.AddRange(_concurrentRunSimulationBatch.SimulationBatchRunValues.Select(x => x.Id)); _results = sut.RunConcurrently(); }
public override void GlobalContext() { base.GlobalContext(); _simulation = _simulationPersister.LoadSimulation(HelperForSpecs.DataFile("sc_model_2c.pkml")); _simulationRunner = Api.GetSimulationRunner(); _containerTask = Api.GetContainerTask(); _containerTask.AddQuantitiesToSimulationOutputByPath(_simulation, "DERMAL_APPLICATION_AREA|permeant|Mass_balance_observer"); _containerTask.AddQuantitiesToSimulationOutputByPath(_simulation, "DERMAL_APPLICATION_AREA|permeant|Stratum_corneum_observer"); _containerTask.AddQuantitiesToSimulationOutputByPath(_simulation, "DERMAL_APPLICATION_AREA|permeant|Vehicle_observer"); _simulationBatch = new ConcurrentRunSimulationBatch ( _simulation, new SimulationBatchOptions { VariableParameters = new[] { "DERMAL_APPLICATION_AREA|skin_compartment|SC_skin_sublayer|SC_total_thickness", "DERMAL_APPLICATION_AREA|skin_compartment|Hydrated SC", } } ); _parValues = new SimulationBatchRunValues { ParameterValues = new[] { 0.0002, 1 } }; _simulationBatch.AddSimulationBatchRunValues(_parValues); sut.AddSimulationBatch(_simulationBatch); }
protected override void Because() { _simulationBatch.AddSimulationBatchRunValues(_parValues2); }