Skip to content
This repository has been archived by the owner on Nov 17, 2023. It is now read-only.

Pseudo 2D transpose kernel #16229

Merged
merged 12 commits into from
Oct 11, 2019
Merged

Pseudo 2D transpose kernel #16229

merged 12 commits into from
Oct 11, 2019

Conversation

dtracz
Copy link
Contributor

@dtracz dtracz commented Sep 20, 2019

Fast pseudo-2D transpose kernel.
Supports only transposes that satisfy:
Exists n and m such that:
params = (0, ..., n-1, n+m, ..., params.size, n, ..., n+m-1)
Example: (0, 2, 3, 1) or (0, 3, 1, 2), but not (0, 2, 1, 3).

@dtracz dtracz changed the title Pr transpose Pseudo 2D transpose kernel Sep 20, 2019
@ptrendx
Copy link
Member

ptrendx commented Sep 23, 2019

@sxjscience FYI

@dtracz Could you look into the CI failures?

Copy link
Member

@ptrendx ptrendx left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

Copy link
Member

@sxjscience sxjscience left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

@sxjscience sxjscience merged commit ca30ba8 into apache:master Oct 11, 2019
aaronmarkham pushed a commit to aaronmarkham/incubator-mxnet that referenced this pull request Oct 16, 2019
* add kernel

* pseudo2dtranspose test

* better calculating grid & block

* add checking max sizes

* test of transpose not fitting in the cuda grid

* support for large tensors

* estetic fixes

* change iterated dimension

* fix Windows issue

* chane types to intex_t

* fix build error
@ChaiBapchya
Copy link
Contributor

@access2rohit GPU pseudo 2d transpose

z = mx.nd.transpose(y, axes=axes)
assert_allclose(x_np, z.asnumpy().astype('uint8'))


Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@sxjscience this removes with_seed() from existing function. Should have been caught...

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Oops, you are right, could you make a PR to fix it?

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@ChaiBapchya Sorry, my bad. I should have caught this. Needs to be more careful next time.

Copy link
Contributor

@ChaiBapchya ChaiBapchya Oct 18, 2019

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Oops, you are right, could you make a PR to fix it?

Yes fixing it in 1 of my PRs.

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants