Skip to content
This repository has been archived by the owner on Feb 24, 2022. It is now read-only.

Image-classification One Hot Encoding test passing with wrong solution #213

Closed
jirivrany opened this issue May 15, 2017 · 0 comments
Closed

Comments

@jirivrany
Copy link

jirivrany commented May 15, 2017

Hello,
I found that the provided unit test for one_hot_encode is passing with following code:

def one_hot_encode(x):
    """
    One hot encode a list of sample labels. Return a one-hot encoded vector for each label.
    : x: List of sample Labels
    : return: Numpy array of one-hot encoded labels
    """
    # TODO: Implement Function
    y = np.zeros((len(x), 10))
    return y

It seems that the third test: assert np.array_equal(enc_labels, new_enc_labels) is always passing.

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants