mirror of
https://github.com/k2-fsa/icefall.git
synced 2025-09-07 08:04:18 +00:00
Mess with thresholds for printing
This commit is contained in:
parent
3ba081e6d9
commit
eba025a6b4
@ -729,7 +729,7 @@ class SampleCombinedFunction(torch.autograd.Function):
|
|||||||
@staticmethod
|
@staticmethod
|
||||||
@custom_fwd
|
@custom_fwd
|
||||||
def forward(ctx, p: Tensor, K: int, input_is_log: bool) -> Tuple[Tensor, Tensor]:
|
def forward(ctx, p: Tensor, K: int, input_is_log: bool) -> Tuple[Tensor, Tensor]:
|
||||||
if random.random() < 0.0005:
|
if random.random() < 0.001:
|
||||||
print("dtype[1] = ", p.dtype)
|
print("dtype[1] = ", p.dtype)
|
||||||
with torch.no_grad():
|
with torch.no_grad():
|
||||||
weights, indexes = sample_combined_forward(p, K, input_is_log)
|
weights, indexes = sample_combined_forward(p, K, input_is_log)
|
||||||
@ -892,7 +892,7 @@ class WeightedMatrixLookupFunction(torch.autograd.Function):
|
|||||||
tensor of shape (*, D), containing weighted sums of rows of
|
tensor of shape (*, D), containing weighted sums of rows of
|
||||||
`knowledge_base`
|
`knowledge_base`
|
||||||
"""
|
"""
|
||||||
if random.random() < 0.0005:
|
if random.random() < 0.001:
|
||||||
print("dtype[1] = ", weights.dtype)
|
print("dtype[1] = ", weights.dtype)
|
||||||
ctx.save_for_backward(weights.detach(), indexes.detach(),
|
ctx.save_for_backward(weights.detach(), indexes.detach(),
|
||||||
knowledge_base.detach())
|
knowledge_base.detach())
|
||||||
|
Loading…
x
Reference in New Issue
Block a user