enable_sqrt_sampling = <property object>

Get or set whether sqrt sampling is allowed. Sqrt sampling means that given the size of the candidate set is N, only enumerate sqrt(N) tensors. When the number of tensors is very high, enabling this optimization will speed up the training.


import megengine as mge
mge.dtr.enable_sqrt_sampling = True