Skip to content
This repository was archived by the owner on Jul 1, 2025. It is now read-only.

Conversation

bertmaher
Copy link
Contributor

params->pWend = pad[0];
params->pHbegin = pad[1];
params->pHend = pad[1];
params->pHbegin = pad[0];
Copy link
Contributor

Choose a reason for hiding this comment

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

Lol, whoops.


chk(synCreateGenericNode(&tensors[NI->getInput()].get(),
&tensors[NI].get(), 1, 1, (void *)params.get(),
"lrn_f32", NI->getName().str().c_str(), nullptr,
Copy link
Contributor

Choose a reason for hiding this comment

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

Is the datatype intentionally hardcoded? Does this operator not exist for other datatypes? It makes sense that it wouldn't, but I just want to confirm.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Good eye - LRN does indeed only exist for f32. We could assert that here, although it'll already be caught by isOpSupported.

@SplitInfinity
Copy link
Contributor

Also, it's interesting that we need LRN because I haven't heard of it being used for months now.

@bertmaher
Copy link
Contributor Author

It's used in inception_v1 and bvlc_alexnet. Unless it usually gets optimized away somehow?

@SplitInfinity
Copy link
Contributor

SplitInfinity commented May 1, 2019

Ah, those two are 4-8 years old at this point. This PR made me think some recent models use them.

* Introduced LRN, fixed pytorch#144
* Added Concat node to the list of supported quantized nodes
* Added RescaleQuantized node, replaced quantized MatMul with GEMM
@bertmaher bertmaher merged commit 421d0a5 into pytorch:master May 2, 2019
@bertmaher bertmaher deleted the upstreaming branch May 2, 2019 05:00
@sergeigofman
Copy link

LRN indeed aren't used in modern topologies. I introduced it more like an exe4cise and to enable inception_v1. Besides, Habana supports it so why not? Indeed it is only available for fp32.

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

Successfully merging this pull request may close these issues.

4 participants