Add PackSegmentsFix operator in caffe2#9048
Conversation
facebook-github-bot
left a comment
There was a problem hiding this comment.
@nateanl has imported this pull request. If you are a Facebook employee, you can view this diff on Phabricator.
bddppq
left a comment
There was a problem hiding this comment.
IIUC what you wanna achieve is to use an argument (currently named dim, I suggest to rename it to max_length) to override the max_length dimension in the output? If so you can simply add this argument to the existing PackSegmentsOp operator.
caffe2/operators/pack_segments.cc
Outdated
This comment was marked as off-topic.
This comment was marked as off-topic.
Sorry, something went wrong.
This comment was marked as off-topic.
This comment was marked as off-topic.
Sorry, something went wrong.
caffe2/operators/pack_segments.h
Outdated
This comment was marked as off-topic.
This comment was marked as off-topic.
Sorry, something went wrong.
caffe2/operators/pack_segments.cu
Outdated
This comment was marked as off-topic.
This comment was marked as off-topic.
Sorry, something went wrong.
This comment was marked as off-topic.
This comment was marked as off-topic.
Sorry, something went wrong.
This comment was marked as off-topic.
This comment was marked as off-topic.
Sorry, something went wrong.
This comment was marked as off-topic.
This comment was marked as off-topic.
Sorry, something went wrong.
This comment was marked as off-topic.
This comment was marked as off-topic.
Sorry, something went wrong.
|
@pytorchbot retest this please |
This comment was marked as off-topic.
This comment was marked as off-topic.
Sorry, something went wrong.
This comment was marked as off-topic.
This comment was marked as off-topic.
Sorry, something went wrong.
This comment was marked as off-topic.
This comment was marked as off-topic.
Sorry, something went wrong.
…ment (pytorch#9048) Summary: Closes pytorch#9048 max_length argument helps fix the shape of the output to be N * max_length * D, where N is the batch_size, D is the feature_dim. Differential Revision: D8702782 fbshipit-source-id: 599dd40821a5ca119acb4d61162f194f222cfbfb
…ment (pytorch#9048) Summary: Closes pytorch#9048 max_length argument helps fix the shape of the output to be N * max_length * D, where N is the batch_size, D is the feature_dim. Reviewed By: bddppq Differential Revision: D8702782 fbshipit-source-id: e30555608fee1c4a61cc95922f4a71c7f54903af
Summary:
This operator is similar to PackSegmentsOp but with an additional option dim.
Input: a UNKNOWN_DIM * D tensor and a lengths tensor. The shape of lengths is UNKNOWN_DIM
The output will be UNKNOWN_DIM * dim * D
Differential Revision: D8702782