Opening netCDF file with large number of variables but size is small in R

classic Classic list List threaded Threaded
4 messages Options
Reply | Threaded
Open this post in threaded view
|

Opening netCDF file with large number of variables but size is small in R

കുഞ്ഞായി kunjaai
Dear all,

  I am trying to open a netcdf file with size 1.2 MB contains more than
3000 variables using 'netcdf' package.

 I am facing problem that it taking more than  10 minute to open this small
nc file.

Is any way to make it fast ?

 I have attached one sample nc-file along with this mail.


 Thank you all in advance.




--
DILEEPKUMAR. R
J R F, IIT DELHI

______________________________________________
[hidden email] mailing list
https://stat.ethz.ch/mailman/listinfo/r-help
PLEASE do read the posting guide http://www.R-project.org/posting-guide.html
and provide commented, minimal, self-contained, reproducible code.
Reply | Threaded
Open this post in threaded view
|

Re: Opening netCDF file with large number of variables but size is small in R

Thiago V. dos Santos
Dileepkumar,

Which function are you using to open the netcdf file?

Without a sample of your data it is not possible to reproduce your issue. However, opening a netcdf file should be straightforward with 'raster' (from raster package) or 'nc.open' (from ncdf4 package).
 
Greetings,
--
Thiago V. dos Santos
PhD student
Land and Atmospheric Science
University of Minnesota
http://www.laas.umn.edu/CurrentStudents/MeettheStudents/ThiagodosSantos/index.htm
Phone: (612) 323 9898


On Wednesday, October 1, 2014 6:11 AM, കുഞ്ഞായി kunjaai <[hidden email]> wrote:
 


Dear all,

  I am trying to open a netcdf file with size 1.2 MB contains more than
3000 variables using 'netcdf' package.

I am facing problem that it taking more than  10 minute to open this small
nc file.

Is any way to make it fast ?

I have attached one sample nc-file along with this mail.


Thank you all in advance.




--
DILEEPKUMAR. R
J R F, IIT DELHI

______________________________________________
[hidden email] mailing list
https://stat.ethz.ch/mailman/listinfo/r-help
PLEASE do read the posting guide http://www.R-project.org/posting-guide.html
and provide commented, minimal, self-contained, reproducible code.
        [[alternative HTML version deleted]]

______________________________________________
[hidden email] mailing list
https://stat.ethz.ch/mailman/listinfo/r-help
PLEASE do read the posting guide http://www.R-project.org/posting-guide.html
and provide commented, minimal, self-contained, reproducible code.
Reply | Threaded
Open this post in threaded view
|

Re: Opening netCDF file with large number of variables but size is small in R

Michael Sumner-2
In reply to this post by കുഞ്ഞായി kunjaai
This is really a question for a package maintainer, but you don't say which
package. Potentially ncdf4 may be slow with that many vars, try the open
with

suppress_dimvals=TRUE

as an outrageously optimistic guess if that package is the one you use. We
need more details from you, as per the posting guide.

Cheers, Mike
Dear all,

  I am trying to open a netcdf file with size 1.2 MB contains more than
3000 variables using 'netcdf' package.

 I am facing problem that it taking more than  10 minute to open this small
nc file.

Is any way to make it fast ?

 I have attached one sample nc-file along with this mail.


 Thank you all in advance.




--
DILEEPKUMAR. R
J R F, IIT DELHI

______________________________________________
[hidden email] mailing list
https://stat.ethz.ch/mailman/listinfo/r-help
PLEASE do read the posting guide http://www.R-project.org/posting-guide.html
and provide commented, minimal, self-contained, reproducible code.

        [[alternative HTML version deleted]]

______________________________________________
[hidden email] mailing list
https://stat.ethz.ch/mailman/listinfo/r-help
PLEASE do read the posting guide http://www.R-project.org/posting-guide.html
and provide commented, minimal, self-contained, reproducible code.
Reply | Threaded
Open this post in threaded view
|

Re: Opening netCDF file with large number of variables but size is small in R

Marc Girondot-2
In reply to this post by കുഞ്ഞായി kunjaai
Le 01/10/2014 13:11, കുഞ്ഞായി kunjaai a écrit :
> Dear all,
>
>    I am trying to open a netcdf file with size 1.2 MB contains more than
> 3000 variables using 'netcdf' package.
>
>   I am facing problem that it taking more than  10 minute to open this small
> nc file.
>
> Is any way to make it fast ?

Have you tried the ncdf4 package ?
You can find a comparison of these package here:
http://max2.ese.u-psud.fr/epc/conservation/Girondot/Publications/Blog_r/Entrees/2014/4/27_Comparison_between_packages_RnetCDF%2C_ncdf4_and_ncdf.html


>   I have attached one sample nc-file along with this mail.

The attachments are not showing on the list.

Marc

______________________________________________
[hidden email] mailing list
https://stat.ethz.ch/mailman/listinfo/r-help
PLEASE do read the posting guide http://www.R-project.org/posting-guide.html
and provide commented, minimal, self-contained, reproducible code.