clab / clab/dynet

sum_dim throws exception

Open
#1,463 4 comments 0 reactions 0 assignees View on GitHub
need more info
Dominant language
C++
Stars
3.4k
Forks
701
PR merge metrics
No merged PRs in 30d

Description

Hi,

I have an exception with is throwed by the following code:
`auto agg_v2 = dynet::sum_dim(v2, {1});`

The exception is:
```
terminate called after throwing an instance of 'std::invalid_argument'
what(): Out of bounds exception in Dim::delete_dims
```
The dimension of v2 is {200,17}. From the stack trace it is thrown by this line on of code: https://github.com/clab/dynet/blob/master/dynet/dim.h#L238

I am running on GPU with autobatch. I don't really know what else I can provide unfortunately...

Contributor guide

No contributing guide indexed for this repository

Research direction

Start with dynet/dim.h at line 238 and trace the dimensions produced by dynet::sum_dim(v2, {1}) for v2 shaped {200,17}. Reproduce the failure using GPU with autobatch enabled, then use the reported stack trace and issue discussion to isolate the cause; done means the call no longer throws unexpectedly and the behavior is covered by a regression test.

Written by the indexing model from the issue text.

Assessment

Tech stack
cpp
Domain
machine-learning
Issue type
Bug
Difficulty
4/5
Estimated time
3-5 days
Activity status
Stale
Clarity
Needs clarification
Newbie friendliness
35/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.