Skip to content

Instantly share code, notes, and snippets.

@sunilkumardash9
Created January 30, 2022 12:00
Show Gist options
  • Save sunilkumardash9/54ef25cb7111c5e824a48595e53218a8 to your computer and use it in GitHub Desktop.
Save sunilkumardash9/54ef25cb7111c5e824a48595e53218a8 to your computer and use it in GitHub Desktop.
def predict(self,X):
z = dot(self.initialize(X)[1],self.weights)
lis = []
for i in self.sigmoid(z):
if i>0.5:
lis.append(1)
else:
lis.append(0)
return lis
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment