Questions tagged [bias-neuron]
68 questions
0
votes
1 answer
How to add a learnable bias to one of the network output channel in pytorch
class pu_fc(nn.Module):
def __init__(self, input_dim):
super(pu_fc, self).__init__()
self.input_dim = input_dim
self.fc1 = nn.Linear(input_dim, 50)
self.fc2 = nn.Linear(50, 2)
self.loss_fn =…

Kevin Hu
- 95
- 2
- 6
0
votes
1 answer
Neural network probability calculation in Python
I'm currently trying to manually compute the output probabilities of my neural network, using weights matrices and bias vectors, provided by the mlpclassifier from python's library. The goal is to have the same output from the mlp.predict_proba.…
0
votes
1 answer
keras convnet 1d has bias although activation=none
i have a convoutional neuronal network with keras:
x = tf.keras.layers.Conv1D(128, 65, padding='same', strides=2,activation=None)(input)
The input has the size (8192,1)
if i check my model summary, the layer has following properties,
output shape…

Khan
- 1,418
- 1
- 25
- 49
0
votes
1 answer
JavaScript : Simple perceptron predicting wrong for XOR gate
This JavaScript code represents the concept of simple perceptron in a neural network. Below code is predicting fine with all truth table except XOR table. please run this code in your browser's console window and find what is wrong.
Since this is a…
0
votes
1 answer
How do you calculate the gradient of bias in a conolutional neural network?
I am having a hard time finding resources online about how to preform backpropagation with the bias in a convolutional neural network. By bias I mean the number added to every number resulting from a convolution.
Here is a picture further…

cr5519
- 53
- 1
- 4
0
votes
1 answer
Is the bias neuron of a neural network equivalent to a y-intercept of a linear regression?
Is the above statement true? bias and \beta_0 are both weights that are independent of the input so the allow the model to add some constant value.

Quastiat
- 1,164
- 1
- 18
- 37
0
votes
1 answer
Count Neurons in Keras (with different layers), is my approach correct?
I'm trying to determine the number of 'neurons / nodes' within my Keras network not the parameter. I'm using an already implemented variant, so I didn't develop anything by myself.
That I can get an overview of the network and the number of…

Pascal Z.
- 23
- 6
0
votes
1 answer
Should I change the bias during training with a neural net?
I mean, should I adjust the bias the way weights are?

Ferdinand Stickstoff
- 43
- 1
- 4
0
votes
1 answer
What does the Bias exactly, is it for shifting or firing?
I still do not understand what bias is and when a neuron is activated.
So now i have some questions.
When exactly does an artificial neuron get fired? Does the neuron also fire when the result of the activation function is <0 or does the neuron only…

Tuals
- 11
- 1
0
votes
1 answer
Neural Network Underfitting with Dogs and Cats
Without necessarily getting into the code of it, but focusing more on the principles, I have a question about what I assume would be underfitting.
If I am training a network that recognizes true or false as to whether an image is of a dog, and I…

Jmeeks29ig
- 219
- 1
- 7
0
votes
5 answers
How to find Perceptron : weight1, weight2, and bias mathematically
How to find values of weight1, weight2, and bias? What's generalized mathematical way to find these 3 values for any problem!
import pandas as pd
weight1 = 0.0
weight2 = 0.0
bias = 0.0
test_inputs = [(0, 0), (0, 1), (1, 0), (1,…

Rahul Vansh
- 171
- 2
- 13
0
votes
0 answers
Error with bias in backpropagation
This is my nn.
and here is the code:
import numpy as np
def relu(x):
x = np.where(x>=0,x,x*.1)
return x
def deriv_relu(x):
x = np.where(x>=0,1,x*.1)
return x
def bias(x):
e = np.ones((x.shape[0],1))
e1 =…

filtertips
- 801
- 3
- 12
- 25
0
votes
1 answer
Backpropagating bias in a neural network
Following Andrew Traks's example, I want to implement a 3 layer neural network - 1 input, 1 hidden, 1 output - with a simple dropout, for binary classification.
If I include bias terms b1 and b2, then I would need to slightly modify Andrew's code as…

PyRsquared
- 6,970
- 11
- 50
- 86
0
votes
1 answer
Implement bias neurons neural network
I implemented bias units for my neural network with gradient descent. But I'm not 100% sure If I've implemented it the right way. Would be glade if you can quickly look through my code. Only the parts with
if bias:
are important.
And my second…

Peter234
- 1,052
- 7
- 24
0
votes
1 answer
How to use the "Bias" in Neuronal Networks
for 2 weeks now, i am working with a neuronal network. My activation function is the normal sigmoid function but there is one thing, i have read about on the internet, but found different ways of interpretations.
Currently I am adding up all input…

Luecx
- 160
- 1
- 12