Last active
November 29, 2019 12:52
-
-
Save tonyroberts/538b0b5020c78cc5589a2b604f2c7dd9 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
from pyxll import xl_func | |
import torch.nn as nn | |
@xl_func | |
def nn_Linear(in_features: int, out_features: int, bias: bool=True): | |
"""Create a linear transformation layer.""" | |
return nn.Linear(in_features, out_features, bias) | |
@xl_func | |
def nn_Tanh(): | |
"""Create a Tanh transformation layer.""" | |
return nn.Tanh() | |
@xl_func | |
def nn_Sigmoid(): | |
"""Create a Sigmoid transformation layer.""" | |
return nn.Sigmoid() |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment