0

how do i load data from parser using (from parser import load_data)

ImportError Traceback (most recent call last)

in ()

 13 import numpy as np #math

 14 

---> 15 from parser import load_data #data loading

 16 

ImportError: cannot import name 'load_data'

i am working on image classification and creating my own classifier and i am not getting the solution for this error. i am using python anaconda 3 and tensor flow framework for my project and all the packages are installed including: keras tensor flow ipython

screenshot

enter image description here

Waleed Ahmed
  • 41
  • 2
  • 3
  • import keras #ml from keras.models import Sequential from keras.layers import Dense, Activation #from keras.preprocessing.image import ImageDataGenerator #from keras.layers import Conv2D, MaxPooling2D #from keras.layers import Activation, Dropout, Flatten, Dense #from keras import backend as K #import parser #from Parsers import parser #from keras.layers import Dense, Activation, Conv2D, Model import numpy as np #math from parser import load_data #data loading – Waleed Ahmed Sep 25 '17 at 21:43
  • I was looking the Siraj videos and I have the same problem is import that on the video but when I try the same I have error like you – George C. Nov 26 '17 at 23:36
  • Try to use Keras instead. from keras.datasets import imdb train_data=imdb.load_data('yourdatapath') – J A S K I E R Nov 08 '19 at 12:22

1 Answers1

1

The python module parser doesn't contain a function or class called load_data.

Here are the docs I don't think this is the module that you have intended to use.

foxyblue
  • 2,859
  • 2
  • 21
  • 29
  • if parser doesn't contain any load data variable then what library should i use to load may data set. – Waleed Ahmed Sep 26 '17 at 13:32
  • What is the structure of your data? – foxyblue Sep 26 '17 at 13:33
  • import keras #ml from keras.models import Sequential import numpy as np #math from parser import load_data #data loading #1 training_data=load_data('adas') validation_data=load_data('adas') #2 model=sequential() model.add(Convolution2D(32,3,3 )) model.add(Activation('relu')) model.add(MaxPooling2D(pool_size=(2,2))) – Waleed Ahmed Sep 26 '17 at 14:04
  • i am using tensorflow and for my dataset i need library – Waleed Ahmed Sep 26 '17 at 14:07