Coder Social home page Coder Social logo

Data file download failed about imdlib HOT 10 CLOSED

pradeep2c1 avatar pradeep2c1 commented on June 25, 2024
Data file download failed

from imdlib.

Comments (10)

iamsaswata avatar iamsaswata commented on June 25, 2024

What version of imdlib you are using?

from imdlib.

pradeep2c1 avatar pradeep2c1 commented on June 25, 2024

I downloaded it using conda with python 3.7.9
it is: imdlib-0.1.8.1

from imdlib.

pradeep2c1 avatar pradeep2c1 commented on June 25, 2024

Also, actually I want to work with real time data (date-wise)
But there also I got error:
image

from imdlib.

iamsaswata avatar iamsaswata commented on June 25, 2024

Yes, real time date (date-wise) will work if you update your imdlib to the newest version. Also, it will solve the earlier error (File Download Failed! Error: 404 Client Error) you were facing. Update the imdlib and make sure it has version 0.1.15 (as of now February, 2023). You can try something like : pip install imdlib==0.1.15 or pip install --force-reinstall -v "imdlib==0.1.15".

from imdlib.

pradeep2c1 avatar pradeep2c1 commented on June 25, 2024

Thanks, it worked for downloading yearly data.
But still there is issue with daily data:
image
image
Can you please help out with this

from imdlib.

iamsaswata avatar iamsaswata commented on June 25, 2024

Happy to know it solved your problem.

Regarding your mentioned issue in the last comment " But still there is issue with daily data:", I can confirm you that it is not a problem of the IMDLIB library. I have attached a screenshot from my notebook for your reference.

If i have to make it simple, imd only stores real time daily data for the recent time period (that's why newer date woks, e.g., 2020 in the example), but not the data from long back (that's why 2013 in your example is not working).

github_imdlib_issue_feb_2023

from imdlib.

pradeep2c1 avatar pradeep2c1 commented on June 25, 2024

Yes, finally I got access to real-time data after 2016.
But, I needed to work with data since 2000 or so. And that data is available at the IMD website too. But there you can only download for a day at one time, and for example, 100 days per year for so many years would be just too time consuming.
So, is there some way or solution to that?

from imdlib.

iamsaswata avatar iamsaswata commented on June 25, 2024

Happy it worked for you. If you need daily data ( which is not real time), it is possible ( take the archive data and extract as per your need). Otherwise, I am not sure. But in practice, real time data are used in real time and historical data for long term applications.

from imdlib.

pradeep2c1 avatar pradeep2c1 commented on June 25, 2024

Maybe, my words were not that precise.
I wanted to mean that I want data like for dates 01-04-2001, 02-04-2001, ...

from imdlib.

iamsaswata avatar iamsaswata commented on June 25, 2024

That's fine.
If you can read the data in imdlib, then you can achieve this in two step. Assuming you have the long data in a variable called 'data', (1) you convert it to xarray format by using imdlib function get_xarray() function ( e.g. ds=data.get_xarray()) ( available at documentation site:https://imdlib.readthedocs.io) and finally (2) get your required days ( e.g. 01-04-2001) using xarray slice syntax ( e.g., ds.sel(time='YYYY-MM-DD')).

from imdlib.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.