Skip to content

Commit

Permalink
fixing forgotten mask
Browse files Browse the repository at this point in the history
  • Loading branch information
jeandut committed Aug 16, 2024
1 parent b5e2f44 commit c5cb2c7
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions fedeca/strategies/fed_smd.py
Original file line number Diff line number Diff line change
Expand Up @@ -193,7 +193,7 @@ def compute_local_moments_per_group(
raw_data = pd.DataFrame(Xprop, columns=propensity_cols)

weights_df = pd.DataFrame(
np.repeat(weights[:, None], Xprop.shape[1]), columns=propensity_cols
np.repeat(weights, Xprop.shape[1], axis=1), columns=propensity_cols
)

results = {}
Expand All @@ -204,7 +204,7 @@ def compute_local_moments_per_group(
# Here we pass weights
results[res_name]["weighted"] = {
f"moment{k}": compute_uncentered_moment(
raw_data[mask_treatment], k, weights
raw_data[mask_treatment], k, weights[mask_treatment]
)
for k in range(1, 3)
}
Expand Down

0 comments on commit c5cb2c7

Please sign in to comment.