Skip to content

Conversation

@swolchok
Copy link
Contributor

@swolchok swolchok commented Mar 24, 2022

Stack from ghstack (oldest at bottom):

The wrapper just called through to methods on the underlying Tensor.

Differential Revision: D34689789

The wrapper just called through to methods on the underlying Tensor.

Differential Revision: [D34689789](https://our.internmc.facebook.com/intern/diff/D34689789/)

[ghstack-poisoned]
@facebook-github-bot
Copy link
Contributor

facebook-github-bot commented Mar 24, 2022

🔗 Helpful links

💊 CI failures summary and remediations

As of commit 8b3a629 (more details on the Dr. CI page):


💚 💚 Looks good so far! There are no failures yet. 💚 💚


This comment was automatically generated by Dr. CI (expand for details).

Please report bugs/suggestions to the (internal) Dr. CI Users group.

Click here to manually regenerate this comment.

swolchok added a commit that referenced this pull request Mar 24, 2022
The wrapper just called through to methods on the underlying Tensor.

Differential Revision: [D34689789](https://our.internmc.facebook.com/intern/diff/D34689789/)

ghstack-source-id: 152119329
Pull Request resolved: #74691
The wrapper just called through to methods on the underlying Tensor.

Differential Revision: [D34689789](https://our.internmc.facebook.com/intern/diff/D34689789/)

[ghstack-poisoned]
swolchok added a commit that referenced this pull request Mar 24, 2022
Pull Request resolved: #74691

The wrapper just called through to methods on the underlying Tensor.
ghstack-source-id: 152147833

Differential Revision: [D34689789](https://our.internmc.facebook.com/intern/diff/D34689789/)
The wrapper just called through to methods on the underlying Tensor.

Differential Revision: [D34689789](https://our.internmc.facebook.com/intern/diff/D34689789/)

[ghstack-poisoned]
swolchok added a commit that referenced this pull request Mar 24, 2022
Pull Request resolved: #74691

The wrapper just called through to methods on the underlying Tensor.
ghstack-source-id: 152159577

Differential Revision: [D34689789](https://our.internmc.facebook.com/intern/diff/D34689789/)
The wrapper just called through to methods on the underlying Tensor.

Differential Revision: [D34689789](https://our.internmc.facebook.com/intern/diff/D34689789/)

[ghstack-poisoned]
swolchok added a commit that referenced this pull request Mar 25, 2022
Pull Request resolved: #74691

The wrapper just called through to methods on the underlying Tensor.
ghstack-source-id: 152223291

Differential Revision: [D34689789](https://our.internmc.facebook.com/intern/diff/D34689789/)
The wrapper just called through to methods on the underlying Tensor.

Differential Revision: [D34689789](https://our.internmc.facebook.com/intern/diff/D34689789/)

[ghstack-poisoned]
@swolchok swolchok requested a review from bdhirsh as a code owner March 28, 2022 21:40
swolchok added a commit that referenced this pull request Mar 28, 2022
Pull Request resolved: #74691

The wrapper just called through to methods on the underlying Tensor.
ghstack-source-id: 152399357

Differential Revision: [D34689789](https://our.internmc.facebook.com/intern/diff/D34689789/)
The wrapper just called through to methods on the underlying Tensor.

Differential Revision: [D34689789](https://our.internmc.facebook.com/intern/diff/D34689789/)

[ghstack-poisoned]
swolchok added a commit that referenced this pull request Mar 29, 2022
Pull Request resolved: #74691

The wrapper just called through to methods on the underlying Tensor.
ghstack-source-id: 152433754

Differential Revision: [D34689789](https://our.internmc.facebook.com/intern/diff/D34689789/)
facebook-github-bot pushed a commit that referenced this pull request Mar 29, 2022
Summary:
Pull Request resolved: #74691

The wrapper just called through to methods on the underlying Tensor.
ghstack-source-id: 152433754

Test Plan: existing tests

Reviewed By: ezyang

Differential Revision: D34689789

fbshipit-source-id: cf53476780cf3ed00a3aa4add441300bfe8e27ce
@facebook-github-bot facebook-github-bot deleted the gh/swolchok/475/head branch April 2, 2022 14:17
@mattangus
Copy link

Now that the wrapper is deleted is there any way to distinguish between a nested tensor and a regular tensor? Currently I have two work arounds:

    try:
        tensor.shape
        is_nested = False
    except RuntimeError as ex:
        is_nested = "NestedTensorImpl" in str(ex)

or

    is_nested = "nested_tensor" in str(tensor)

The former is very slow because of the try except perfomace. The latter requires a copy to the CPU for the print.

@cpuhrsch
Copy link
Contributor

cpuhrsch commented Apr 8, 2022

@mattangus - I agree that we should have something here. Could I kindly ask you to open a separate issue? Also, as a user of this new prototype feature maybe you want to share more what your use case is and what you have planned for NestedTensor?

@mattangus
Copy link

@cpuhrsch I made a couple of feature requests. #75940 and #75939. The former showcases my usecase a bit.

@swolchok
Copy link
Contributor Author

#73999 added Tensor.is_nested

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

5 participants