private ResultsContainer GatherSolutionLocally() { var rc = new ResultsContainer(Model.LateralDimensions); foreach (var observationLevel in _observationLevels) { var all = GatherAllFieldsAtLevelLocally(observationLevel, _eFields, _hFields); rc.Add(all); } _eFields.Clear(); _hFields.Clear(); return(rc); }
public static ResultsContainer Load(XDocument xdoc, LateralDimensions lateral = default(LateralDimensions)) { var xresult = xdoc.Element("ResultsMT"); if (xresult == null) { throw new ArgumentOutOfRangeException("xdoc"); } if (lateral == default(LateralDimensions)) { lateral = ModelReader.LateralDimensionsFromXElement(xresult); } if (lateral == default(LateralDimensions)) { throw new InvalidOperationException("no lateral dimensions"); } var xfreq = xresult.Element("Frequencies"); var xobs = xresult.Element("Observations"); var xvals = xresult.Element("Values"); if (xfreq == null) { throw new InvalidDataException("Frequencies"); } if (xobs == null) { throw new InvalidDataException("Observations"); } if (xvals == null) { throw new InvalidDataException("Values"); } var result = new ResultsContainer(lateral); return(result); }
private ResultsContainer GatherSolution() { Logger.WriteStatus("Gather results..."); var rc = new ResultsContainer(Model.LateralDimensions); if (!IsParallel || Mpi.Rank < Mpi.Size / 2) { foreach (var observationLevel in _observationLevels) { var all = GatherAllFieldsAtLevel(observationLevel, _eFields, _hFields); if (!IsParallel || Mpi.IsMaster) { rc.Add(all); } } } ClearLocalCalculatedFields(); return(rc); }
public PlainTextExporter(ResultsContainer container, double frequency) { _container = container; _frequency = frequency; }