mirror of
https://github.com/deepseek-ai/DeepSeek-Coder
synced 2025-06-26 18:25:53 +00:00
Update README.md
This commit is contained in:
@@ -203,6 +203,8 @@ def load_data():
|
|||||||
|
|
||||||
def evaluate_predictions(y_test, y_pred):
|
def evaluate_predictions(y_test, y_pred):
|
||||||
return accuracy_score(y_test, y_pred)
|
return accuracy_score(y_test, y_pred)
|
||||||
|
|
||||||
|
|
||||||
# model.py
|
# model.py
|
||||||
import torch
|
import torch
|
||||||
import torch.nn as nn
|
import torch.nn as nn
|
||||||
@@ -242,6 +244,8 @@ class IrisClassifier(nn.Module):
|
|||||||
outputs = self(X_test)
|
outputs = self(X_test)
|
||||||
_, predicted = outputs.max(1)
|
_, predicted = outputs.max(1)
|
||||||
return predicted.numpy()
|
return predicted.numpy()
|
||||||
|
|
||||||
|
|
||||||
# main.py
|
# main.py
|
||||||
from utils import load_data, evaluate_predictions
|
from utils import load_data, evaluate_predictions
|
||||||
from model import IrisClassifier as Classifier
|
from model import IrisClassifier as Classifier
|
||||||
|
|||||||
Reference in New Issue
Block a user