clab / clab/dynet

Updatable sparse input

Open
#1,496 0 comments 1 reaction 0 assignees View on GitHub
Dominant language
C++
Stars
3.4k
Forks
701
PR merge metrics
No merged PRs in 30d

Description

Hi,

The source code says:

> This doesn't support pointer input, because this would require dynamic changing of the size of auxiliary memory on GPUs, although this could possibly be fixed in the future.

https://github.com/clab/dynet/blob/8260090904d6b4b6e2ca90da0561c602858541b2/dynet/param-nodes.h#L53
Is there anyway we can fix that?

CPU can be avalaible out of the box, for GPU could we have something like a "maximum number of non-null values" as a parameter? Then when cg.forward() is called, we can check is the size of the vector.

Would a pull request with this change be welcome?

Best,
Caio

Contributor guide

No contributing guide indexed for this repository

Research direction

Start with the pointer-input limitation described in dynet/param-nodes.h around line 53, then trace how sparse input sizes are handled for CPU and GPU execution. Review the proposed maximum-non-null-values approach and cg.forward() behavior. Done would mean a settled, tested design for updatable sparse input support, including the GPU case.

Written by the indexing model from the issue text.

Assessment

Tech stack
cpp
Domain
machine-learning
Issue type
Feature
Difficulty
5/5
Estimated time
Over a week
Activity status
Stale
Clarity
Needs clarification
Newbie friendliness
25/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.