clab / clab/dynet

Concatenate batch fails if vectors are of sizes (dim,) and (dim, 1)

Open
#531 3 comments 0 reactions 0 assignees View on GitHub
good first issue moderate bug
Dominant language
C++
Stars
3.4k
Forks
701
PR merge metrics
No merged PRs in 30d

Description

Hi! The title sums it up. If you try to concatenate d-dimensional vectors but some vectors' shape is (d,) while others is (d, 1), dynet.concatenate_batch fails. However, if you do dynet.concatenate_cols and then a reshape, everything works fine.

Contributor guide

No contributing guide indexed for this repository

Research direction

Start by reproducing the failure with dynet.concatenate_batch using vectors shaped (dim,) and (dim, 1), then compare it with dynet.concatenate_cols followed by reshape. Trace the concatenate_batch entry point and identify the expected behavior for mixed vector shapes. Done means concatenate_batch accepts both shapes consistently without requiring the workaround.

Written by the indexing model from the issue text.

Assessment

Tech stack
cpp
Domain
machine-learning
Issue type
Bug
Difficulty
3/5
Estimated time
1-2 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
42/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.