From ca3090353e96bf59ce22309a03452f907dcf4d0a Mon Sep 17 00:00:00 2001 From: Eugene Du Date: Fri, 27 Sep 2024 04:28:50 +0000 Subject: [PATCH] Address PR comments --- gnssanalysis/gn_io/sp3.py | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/gnssanalysis/gn_io/sp3.py b/gnssanalysis/gn_io/sp3.py index 24d20a8..f4cab4f 100644 --- a/gnssanalysis/gn_io/sp3.py +++ b/gnssanalysis/gn_io/sp3.py @@ -830,9 +830,11 @@ def sp3_hlm_trans(a: _pd.DataFrame, b: _pd.DataFrame, epochwise: bool = False) - :param bool epochwise: Epochwise HLM transformation. :return tuple[pandas.DataFrame, list]: A tuple containing the updated sp3_b DataFrame and the HLM array with applied computed parameters and residuals. """ + hlm = [] if epochwise: for epoch in b.index.get_level_values("J2000").unique(): - b.loc[epoch, [("EST", "X"), ("EST", "Y"), ("EST", "Z")]], hlm = hlm_trans(a.loc[epoch].EST[["X", "Y", "Z"]].values, b.loc[epoch].EST[["X", "Y", "Z"]].values) # Eugene: hlm will be overwritten in the loop + b.loc[epoch, [("EST", "X"), ("EST", "Y"), ("EST", "Z")]], hlm_epoch = hlm_trans(a.loc[epoch].EST[["X", "Y", "Z"]].values, b.loc[epoch].EST[["X", "Y", "Z"]].values) + hlm.append(hlm_epoch) else: b.iloc[:, :3], hlm = hlm_trans(a.EST[["X", "Y", "Z"]].values, b.EST[["X", "Y", "Z"]].values)