Skip to content

[feat] Add unit_to_scale param for the activation function that only accept unitless input #15

@Routhleck

Description

@Routhleck

Add unit_to_scale param for the activation function that only accept unitless input. Allow the Quantity and unit_to_scale as inputs for some activation function together.

Like below:

import saiunit as u

x = 3 * u.mV
u.math.sigmoid(x)  #failed
u.math.sigmoid(x, unit_to_scale=u.mV)  #success

Metadata

Metadata

Assignees

No one assigned

    Labels

    enhancementNew feature or request

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions