コード例 #1
0
        /// <summary>
        /// 从观测文件中提取MW原始值。作为具有卫星和接收机硬件延迟的宽巷模糊度。
        /// </summary>
        /// <returns></returns>
        private ObjectTableManager ExtractRawMwValueFromObsFiles(string namePostfix = "_MwRaw")
        {
            //提取MW值    //并行提速.
            var dic = new ConcurrentDictionary <string, ObjectTableStorage>();

            Parallel.ForEach <string>(FilePathes, filePath =>
            {
                var builder           = new RawMwTableBuilder(filePath, AngleCut, RowCountToBeEmpty, SatelliteTypes);
                builder.Completed    += Builder_Completed;
                builder.IsSmoothRange = IsSmoothRange;
                var table             = builder.Build();
                if (table != null)
                {
                    var siteName = RinexObsFileReader.ReadSiteName(filePath, 8).Trim() + namePostfix;

                    //var fileName = Path.GetFileName(filePath);
                    dic.TryAdd(siteName, table);
                }
            });
            var mwTables = new ObjectTableManager(dic)
            {
                OutputDirectory = OutputDirectory
            };

            OneFileProcessed?.Invoke();

            return(mwTables);
        }