OiO.lk Community platform!

Oio.lk is an excellent forum for developers, providing a wide range of resources, discussions, and support for those in the developer community. Join oio.lk today to connect with like-minded professionals, share insights, and stay updated on the latest trends and technologies in the development field.
  You need to log in or register to access the solved answers to this problem.
  • You have reached the maximum number of guest views allowed
  • Please register below to remove this limitation

Cant import xarray file

  • Thread starter Thread starter Pooplover800
  • Start date Start date
P

Pooplover800

Guest
I am having a problem, where python cant seem to find to find t file that is in the same folder as the Jupiter notebook. I have tried copying the whole address, but it doesn't work. I have recently switched computer, where it worked on the old computer, but on the new it doesn't work. I get the following error message:

Code:
KeyError: [<class 'netCDF4._netCDF4.Dataset'>, ('c:\\Users\\rasmu\\OneDrive\\Skrivebord\\1 Python fysik\\3. år\\PUK\\Dataset.nc',), 'r', (('clobber', True), ('diskless', False), ('format', 'NETCDF4'), ('persist', False)), '3c8f0647-26f8-41da-8245-aec6e4ddd30c']

and

Code:
FileNotFoundError: [Errno 2] No such file or directory: 'c:\\Users\\rasmu\\OneDrive\\Skrivebord\\1 Python fysik\\3. år\\PUK\\Dataset.nc'

I only have this line of code:

Code:
    data = xr.open_dataset('Dataset.nc')
<p>I am having a problem, where python cant seem to find to find t file that is in the same folder as the Jupiter notebook. I have tried copying the whole address, but it doesn't work.
I have recently switched computer, where it worked on the old computer, but on the new it doesn't work. I get the following error message:</p>
<pre><code>KeyError: [<class 'netCDF4._netCDF4.Dataset'>, ('c:\\Users\\rasmu\\OneDrive\\Skrivebord\\1 Python fysik\\3. år\\PUK\\Dataset.nc',), 'r', (('clobber', True), ('diskless', False), ('format', 'NETCDF4'), ('persist', False)), '3c8f0647-26f8-41da-8245-aec6e4ddd30c']
</code></pre>
<p>and</p>
<pre><code>FileNotFoundError: [Errno 2] No such file or directory: 'c:\\Users\\rasmu\\OneDrive\\Skrivebord\\1 Python fysik\\3. år\\PUK\\Dataset.nc'
</code></pre>
<p>I only have this line of code:</p>
<pre><code> data = xr.open_dataset('Dataset.nc')
</code></pre>
 

Latest posts

Top