You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Hi, I am having the following problem. I want to work with the CIFAR10 - data set (more specifically, I follow this course individually and I am trying to do the first assignment http://cs231n.github.io/assignments2018/assignment1/ ).
When I first open the code for linear_svm, the data set loads and everything is ok. But if I shut it down and open it some other time and try to run each sell again, then it gets stuck when I try to load again the data set. I have started learning python the last months, so I don't know what goes wrong.
The code for the first cell is:
# Run some setup code for this notebook.
from __future__ import print_function
import random
import numpy as np
from cs231n.data_utils import load_CIFAR10
import matplotlib.pyplot as plt
# This is a bit of magic to make matplotlib figures appear inline in the
# notebook rather than in a new window.
%matplotlib inline
plt.rcParams['figure.figsize'] = (10.0, 8.0) # set default size of plots
plt.rcParams['image.interpolation'] = 'nearest'
plt.rcParams['image.cmap'] = 'gray'
# Some more magic so that the notebook will reload external python modules;
# see http://stackoverflow.com/questions/1907993/autoreload-of-modules-in-ipython
%load_ext autoreload
%autoreload 2
Then the second cell is
# Load the raw CIFAR-10 data.
cifar10_dir = 'cs231n/datasets/cifar-10-batches-py'
# Cleaning up variables to prevent loading data multiple times (which may cause memory issue)
X_train, y_train, X_test, y_test = load_CIFAR10(cifar10_dir)
# As a sanity check, we print out the size of the training and test data.
print('Training data shape: ', X_train.shape)
print('Training labels shape: ', y_train.shape)
print('Test data shape: ', X_test.shape)
print('Test labels shape: ', y_test.shape)
Note: The command "from future import print_function" in the original notebook was after all the import commands. But when I runned this cell, it told me that it should be in the beginning of the file.
I would appreciate any help! I am a beginner in python and machine learning alone and currently I am highly stuck! Thanks
The text was updated successfully, but these errors were encountered:
Hi, I am having the following problem. I want to work with the CIFAR10 - data set (more specifically, I follow this course individually and I am trying to do the first assignment http://cs231n.github.io/assignments2018/assignment1/ ).
When I first open the code for linear_svm, the data set loads and everything is ok. But if I shut it down and open it some other time and try to run each sell again, then it gets stuck when I try to load again the data set. I have started learning python the last months, so I don't know what goes wrong.
The code for the first cell is:
Then the second cell is
Note: The command "from future import print_function" in the original notebook was after all the import commands. But when I runned this cell, it told me that it should be in the beginning of the file.
I would appreciate any help! I am a beginner in python and machine learning alone and currently I am highly stuck! Thanks
The text was updated successfully, but these errors were encountered: