Skip to content
This repository was archived by the owner on Aug 11, 2020. It is now read-only.
This repository was archived by the owner on Aug 11, 2020. It is now read-only.

Row wise normalization of tensor #318

@rayjs

Description

@rayjs

Hi,
I am new to mshadow. I am seeking some help regarding a tensor operation. I see there are examples to implement elementwise tensor operations as below:
https://github.com/dmlc/mshadow/tree/3d87ed2a4b47ef749c616f208cee45d920fb6e6e/guide#user-defined-operator

But I am looking for slightly different that is, row wise normalization of a tensor
A= [row1; row2;... rowN]; Anormalized = [row1/norm(row1); ....; rowN/norm(rowN)];
norm refers to the 2-norm.
This can be also thought of as reduction and then broadcast along the rows of the tensor.

Is there any implementation or any pointer would be helpful?

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions