Skip to content

Commit

Permalink
.
Browse files Browse the repository at this point in the history
  • Loading branch information
Sasha committed Oct 4, 2019
1 parent 67e85bc commit 16b9aba
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion torch_struct/linearchain.py
Original file line number Diff line number Diff line change
Expand Up @@ -47,7 +47,7 @@ def _dp(self, edge, lengths=None, force_grad=False):
alpha[lengths[i] - 1][:, i]
for i in range(batch)
]
ret = torch.cat(ret, dim=1)
ret = torch.stack(ret, dim=1)
v = semiring.sum(ret)
return v, edge_store, alpha

Expand Down
2 changes: 1 addition & 1 deletion torch_struct/test_distributions.py
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@
@settings(max_examples=50, deadline=None)
def test_simple(data, seed):

model = data.draw(sampled_from([LinearChainCRF, SemiMarkovCRF]))
model = data.draw(sampled_from([LinearChainCRF]))
struct = model.struct
torch.manual_seed(seed)
vals, (batch, N) = struct._rand()
Expand Down

0 comments on commit 16b9aba

Please sign in to comment.