Activa is a Python package that calculates the activation functions of a set of input numerical values while outputting clear visualization of these values for further analysis.
Features of Activa
- Calculates activation functions (ReLU, Sigmoid, Tanh, Softplus, Gaussian)
- Provides visual displays of each function against it's derivatives
- Outputs a comparison table for each values across all activation functions available
Quick Start
First, install the library:
$ pip install Activa
Example
For the example, we will be using the default data in the package, data = [-1, 0, 1]
To import libraries
>> from Activa import ReLU, Sigmoid, Gaussian, Table
- Implementing the ReLU activation function
>> relu = ReLU()
>> relu.relu_values
array([0, 0, 1])
- Implementing the Sigmoid activation function
>> sig = Sigmoid()
>> sig.sigmoid_values
array([0.26894142, 0.5 , 0.73105858])
- Implementing the Gaussian activation function
>> gs = Gaussian()
>> gs.gaussian_values
array([0.36787944, 1. , 0.36787944])
- Implementing the comparison table for all activation functions
>> tb = Table()
>> tb.show
actual_values sigmoid relu tanh softplus gaussian
0 -1 0.268941 0 -0.761594 0.313262 0.367879
1 0 0.500000 0 0.000000 0.693147 1.000000
2 1 0.731059 1 0.761594 1.313262 0.367879
More information
Kindly checkout the github repo for more updates
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Activa-1.0.5.tar.gz
(4.3 kB
view details)
File details
Details for the file Activa-1.0.5.tar.gz.
File metadata
- Download URL: Activa-1.0.5.tar.gz
- Upload date:
- Size: 4.3 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/4.0.1 CPython/3.7.6
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
980248d3bd3ae9b3a2eed9bed9c6e8c094758cd8b531cb3677cdb35fac091ce9
|
|
| MD5 |
c9ee386a609fd65c6ffaebffe9387cc4
|
|
| BLAKE2b-256 |
df7ca7e3b142f90ce2dfc930363c4379182ae450e5fc6459b4ff2d21b2a78a83
|