Closed Nucobi closed 1 year ago
This is an auto-generated grading output. Your code failed to run. Please check again.
This is an auto-generated grading output. Your code failed to run. Please check again.
This is an auto-generated grading output. Checking code of Nucobi {'Nucobi': 70.0}
This is an auto-generated grading output. Checking code of Nucobi {'Nucobi': 70.0}
I think this is not enough. Since answer is either 0 or 1, maybe you can get 50/100 when you always return 0.
This is an auto-generated grading output. Your code failed to run. Please check again.
This is an auto-generated grading output. Your code failed to run. Please check again.
This is an auto-generated grading output. Your code failed to run. Please check again.
import math import torch from random import random from typing import Callable, List, Tuple
Problem 1
Arbitary x_train, y_train are given.
In function predict(), you should return
list y_test corresponding to x_test.
y_train only contains 0 and 1.
Therefore, use logstic regression.
Made by @jangyoujin0917
NOTE : 1. Feel free to use torch.optim and tensor.
2. In this problem, we will only grade 'predict' function.
Function 'training' is only for modularization.
def training(x_train: list[list[float]], y_train: list[float]): # DO NOT MODIFY FUNCTION NAME
IMPLEMENT FROM HERE
def predict(x_train: list[list[float]], y_train: list[float], x_test: list[list[float]]) -> list[float]: # DO NOT MODIFY FUNCTION NAME
IMPLEMENT FROM HERE
if name == "main":
This is very simple case. Passing this testcase do not mean that the code is perfect.