protected void FindMissingObservedData(ParameterIdentification parameterIdentification, ISimulation oldSimulation, ISimulation newSimulation)
        {
            var mappingUsingSimulation = parameterIdentification.AllOutputMappingsFor(oldSimulation);

            mappingUsingSimulation.Where(mapping => !newSimulation.UsesObservedData(mapping.WeightedObservedData.ObservedData)).ToList().Each(mapping =>
                                                                                                                                              ActionForSimulationDoesNotUseObservedData(parameterIdentification, newSimulation, mapping));
        }
        protected void FindMissingOutputPaths(ParameterIdentification parameterIdentification, ISimulation oldSimulation, ISimulation newSimulation)
        {
            var outputMappings = parameterIdentification.AllOutputMappingsFor(oldSimulation);

            outputMappings.Where(outputMapping => !simulationHasEquivalentPath(outputMapping.OutputPath, newSimulation)).ToList().Each(outputPath =>
                                                                                                                                       ActionForSimulationDoesNotHaveOutputPath(parameterIdentification, newSimulation, outputPath));
        }
Exemplo n.º 3
0
        protected override void Context()
        {
            _newSimulation           = A.Fake <ISimulation>();
            _oldSimulation           = A.Fake <ISimulation>();
            _anotherSimulation       = A.Fake <ISimulation>();
            _parameterIdentification = A.Fake <ParameterIdentification>();
            _outputMapping           = A.Fake <OutputMapping>();
            _outputMappings          = new[] { _outputMapping };
            _identificationParameter = new IdentificationParameter();
            _linkedParameter         = new ParameterSelection(_oldSimulation, "parameter|path");
            _anotherParameter        = new ParameterSelection(_anotherSimulation, "parameter|path");

            A.CallTo(() => _parameterIdentification.AllOutputMappingsFor(_oldSimulation)).Returns(_outputMappings);

            var simulationQuantitySelectionFinder = new SimulationQuantitySelectionFinder();

            sut = new ParameterIdentificationSimulationSwapCorrector(simulationQuantitySelectionFinder);
        }