|
@@ -97,10 +97,10 @@ class SampleWeightByICSampleTransfomer(SampleTransformer, instrumentation.Observ
|
|
|
|
|
|
# Apply softmax
|
|
|
sample_weights = {
|
|
|
- sample_uid: sample_ic_exp_tf / ic_exp_tf_sum
|
|
|
+ sample_uid: (sample_ic_exp_tf * len(samples)) / ic_exp_tf_sum
|
|
|
for sample_uid, sample_ic_exp_tf in sample_ics_exp_tf.items()
|
|
|
}
|
|
|
- sample_weight_array = np.asarray(list(sample_weights.values())) * len(samples)
|
|
|
+ sample_weight_array = np.asarray(list(sample_weights.values()))
|
|
|
self.log_info(
|
|
|
f"Weight*cnt mean {np.mean(sample_weight_array)}, std {np.std(sample_weight_array)}, median {np.median(sample_weight_array)}"
|
|
|
)
|