title: TypeError: 'module' object is not callable from Jupyter notebook
body: <p>I am trying to use a module located in the same directory as the script I am running and I get the following error:</p>
  <blockquote>
  <p>TypeError: 'module' object is not callable</p>
  </blockquote>
  <p>This was working before, but I did some modifications to the sys.path list since I wanted to call modules from other directories, and from that point it stopped working.</p>
  <p>This is my folder's structure:</p>
  <pre><code>Neural_Network/
    split_data.py
    test.ipynb
  </code></pre>
  <p>I get the error executing test.ipynb:</p>
  <pre><code>import split_data
  import os
  
  print(split_data.__file__)
  trainset, testset, valset = split_data.split_data_func(os.path('data'))
  </code></pre>
  <hr />
  <pre><code>TypeError                                 Traceback (most recent call last)
  ~\AppData\Local\Temp/ipykernel_4936/633432209.py in &lt;module&gt;
        4 
        5 print(split_data.__file__)
  ----&gt; 6 trainset, testset, valset = split_data.split_data_func(os.path('data'))
        7 
        8 &quot;&quot;&quot;&quot;
  
  TypeError: 'module' object is not callable
  </code></pre>
  <p><code>print(split_data.__file__)</code> is giving the right path to the module.</p>
  <p>The module split_data.py has a single function:</p>
  <pre><code>import math
  import os
  import random
  def split_data_func(path):
  ...
    return trainset, testset, valset
  </code></pre>
  <p>This was working before and I don't know what could have happened.</p>
  <p>In the sys.path I have the path to Neural_Network/ directory.</p>
  <p><strong>UPDATE</strong></p>
  <p>I was looking the error regarding the split_data module and the error was with the os module, I just changed to:</p>
  <pre><code>trainset, testset, valset = split_data.split_data_func(os.path.join(os.getcwd(),'dataset_days'))
  </code></pre>