I have the following code. Although, the problem is very simple but I cannot figure out the reason behind it.
The following is my main.py:
from model_MNIST import Model
def main():
model = Model()
if __name__ == '__main__':
main()
And the model_MNIST.py file is as follows:
# some import statements
class Model(object):
def __init__(self, input_dimensions, output_dimensions):
# some init statements
def train_on_data(self, training_data, training_labels):
N = training_labels.size
Whenever the class initialization is called I get an output as name 'training_labels' is not defined. This is preventing the execution of the program. Can someone point me out what I might be missing?
Edit1: Please refer to the shared link for the file. SharedFolder