Closed rcojocaru closed 4 years ago
In editsim.pyx:
def gen_profile(self, th_=5, sigma=5): ................................................... for uidx, mats in zip(uidxs, mats_list): profile = regularize_profile(barton_sternberg(mats, self._sim_bp, 2*len(mats))) if profile.sum() >= th_: self.profiles[uidx] = regularize_profile(barton_sternberg(mats, self._sim_bp, 2*len(mats))) return self
I think you could just use: if profile.sum() >= th_: self.profiles[uidx] = profile
because you are computing the same thing twice. This would save some time.
Thanks for the report! That's exactly right. Let me fix that shortly...
Ok, thanks!
Done! https://github.com/KeitaW/spykesim/commit/12d71bf525175af1dadd530aa70bda30c81c8c97
In editsim.pyx:
I think you could just use: if profile.sum() >= th_: self.profiles[uidx] = profile
because you are computing the same thing twice. This would save some time.