gphys 1.1.1a
Sign up to get free protection for your applications and to get access to all the features.
- data/ChangeLog +1777 -0
- data/LICENSE.txt +34 -0
- data/README +33 -0
- data/Rakefile +57 -0
- data/TODO_ep_flux +6 -0
- data/bin/gdir_client +27 -0
- data/bin/gdir_server +129 -0
- data/bin/gpaop +146 -0
- data/bin/gpcat +148 -0
- data/bin/gpcut +102 -0
- data/bin/gpedit +228 -0
- data/bin/gplist +68 -0
- data/bin/gpmath +120 -0
- data/bin/gpmaxmin +128 -0
- data/bin/gpprint +60 -0
- data/bin/gpvect +706 -0
- data/bin/gpview +704 -0
- data/bin/grads2nc_with_gphys +61 -0
- data/doc/attribute.html +19 -0
- data/doc/attributenetcdf.html +15 -0
- data/doc/axis.html +376 -0
- data/doc/coordmapping.html +111 -0
- data/doc/coordtransform.html +36 -0
- data/doc/derivative/gphys-derivative.html +80 -0
- data/doc/derivative/index.html +21 -0
- data/doc/derivative/index.rd +14 -0
- data/doc/derivative/math-doc/document/document.css +30 -0
- data/doc/derivative/math-doc/document/document.html +57 -0
- data/doc/derivative/math-doc/document/images.aux +1 -0
- data/doc/derivative/math-doc/document/images.log +385 -0
- data/doc/derivative/math-doc/document/images.pl +186 -0
- data/doc/derivative/math-doc/document/images.tex +364 -0
- data/doc/derivative/math-doc/document/img1.png +0 -0
- data/doc/derivative/math-doc/document/img10.png +0 -0
- data/doc/derivative/math-doc/document/img11.png +0 -0
- data/doc/derivative/math-doc/document/img12.png +0 -0
- data/doc/derivative/math-doc/document/img13.png +0 -0
- data/doc/derivative/math-doc/document/img14.png +0 -0
- data/doc/derivative/math-doc/document/img15.png +0 -0
- data/doc/derivative/math-doc/document/img16.png +0 -0
- data/doc/derivative/math-doc/document/img17.png +0 -0
- data/doc/derivative/math-doc/document/img18.png +0 -0
- data/doc/derivative/math-doc/document/img19.png +0 -0
- data/doc/derivative/math-doc/document/img2.png +0 -0
- data/doc/derivative/math-doc/document/img20.png +0 -0
- data/doc/derivative/math-doc/document/img21.png +0 -0
- data/doc/derivative/math-doc/document/img22.png +0 -0
- data/doc/derivative/math-doc/document/img23.png +0 -0
- data/doc/derivative/math-doc/document/img24.png +0 -0
- data/doc/derivative/math-doc/document/img25.png +0 -0
- data/doc/derivative/math-doc/document/img26.png +0 -0
- data/doc/derivative/math-doc/document/img27.png +0 -0
- data/doc/derivative/math-doc/document/img28.png +0 -0
- data/doc/derivative/math-doc/document/img29.png +0 -0
- data/doc/derivative/math-doc/document/img3.png +0 -0
- data/doc/derivative/math-doc/document/img30.png +0 -0
- data/doc/derivative/math-doc/document/img4.png +0 -0
- data/doc/derivative/math-doc/document/img5.png +0 -0
- data/doc/derivative/math-doc/document/img6.png +0 -0
- data/doc/derivative/math-doc/document/img7.png +0 -0
- data/doc/derivative/math-doc/document/img8.png +0 -0
- data/doc/derivative/math-doc/document/img9.png +0 -0
- data/doc/derivative/math-doc/document/index.html +57 -0
- data/doc/derivative/math-doc/document/labels.pl +13 -0
- data/doc/derivative/math-doc/document/next.png +0 -0
- data/doc/derivative/math-doc/document/next_g.png +0 -0
- data/doc/derivative/math-doc/document/node1.html +238 -0
- data/doc/derivative/math-doc/document/node2.html +75 -0
- data/doc/derivative/math-doc/document/prev.png +0 -0
- data/doc/derivative/math-doc/document/prev_g.png +0 -0
- data/doc/derivative/math-doc/document/up.png +0 -0
- data/doc/derivative/math-doc/document/up_g.png +0 -0
- data/doc/derivative/math-doc/document.pdf +0 -0
- data/doc/derivative/math-doc/document.tex +158 -0
- data/doc/derivative/numru-derivative.html +129 -0
- data/doc/ep_flux/ep_flux.html +469 -0
- data/doc/ep_flux/ggraph_on_merdional_section.html +71 -0
- data/doc/ep_flux/index.html +31 -0
- data/doc/ep_flux/index.rd +24 -0
- data/doc/ep_flux/math-doc/document/WARNINGS +1 -0
- data/doc/ep_flux/math-doc/document/contents.png +0 -0
- data/doc/ep_flux/math-doc/document/crossref.png +0 -0
- data/doc/ep_flux/math-doc/document/document.css +30 -0
- data/doc/ep_flux/math-doc/document/document.html +101 -0
- data/doc/ep_flux/math-doc/document/images.aux +1 -0
- data/doc/ep_flux/math-doc/document/images.log +1375 -0
- data/doc/ep_flux/math-doc/document/images.pl +1328 -0
- data/doc/ep_flux/math-doc/document/images.tex +1471 -0
- data/doc/ep_flux/math-doc/document/img1.png +0 -0
- data/doc/ep_flux/math-doc/document/img10.png +0 -0
- data/doc/ep_flux/math-doc/document/img100.png +0 -0
- data/doc/ep_flux/math-doc/document/img101.png +0 -0
- data/doc/ep_flux/math-doc/document/img102.png +0 -0
- data/doc/ep_flux/math-doc/document/img103.png +0 -0
- data/doc/ep_flux/math-doc/document/img104.png +0 -0
- data/doc/ep_flux/math-doc/document/img105.png +0 -0
- data/doc/ep_flux/math-doc/document/img106.png +0 -0
- data/doc/ep_flux/math-doc/document/img107.png +0 -0
- data/doc/ep_flux/math-doc/document/img108.png +0 -0
- data/doc/ep_flux/math-doc/document/img109.png +0 -0
- data/doc/ep_flux/math-doc/document/img11.png +0 -0
- data/doc/ep_flux/math-doc/document/img110.png +0 -0
- data/doc/ep_flux/math-doc/document/img111.png +0 -0
- data/doc/ep_flux/math-doc/document/img112.png +0 -0
- data/doc/ep_flux/math-doc/document/img113.png +0 -0
- data/doc/ep_flux/math-doc/document/img114.png +0 -0
- data/doc/ep_flux/math-doc/document/img115.png +0 -0
- data/doc/ep_flux/math-doc/document/img116.png +0 -0
- data/doc/ep_flux/math-doc/document/img117.png +0 -0
- data/doc/ep_flux/math-doc/document/img118.png +0 -0
- data/doc/ep_flux/math-doc/document/img119.png +0 -0
- data/doc/ep_flux/math-doc/document/img12.png +0 -0
- data/doc/ep_flux/math-doc/document/img120.png +0 -0
- data/doc/ep_flux/math-doc/document/img121.png +0 -0
- data/doc/ep_flux/math-doc/document/img122.png +0 -0
- data/doc/ep_flux/math-doc/document/img123.png +0 -0
- data/doc/ep_flux/math-doc/document/img124.png +0 -0
- data/doc/ep_flux/math-doc/document/img125.png +0 -0
- data/doc/ep_flux/math-doc/document/img126.png +0 -0
- data/doc/ep_flux/math-doc/document/img127.png +0 -0
- data/doc/ep_flux/math-doc/document/img128.png +0 -0
- data/doc/ep_flux/math-doc/document/img129.png +0 -0
- data/doc/ep_flux/math-doc/document/img13.png +0 -0
- data/doc/ep_flux/math-doc/document/img130.png +0 -0
- data/doc/ep_flux/math-doc/document/img131.png +0 -0
- data/doc/ep_flux/math-doc/document/img132.png +0 -0
- data/doc/ep_flux/math-doc/document/img133.png +0 -0
- data/doc/ep_flux/math-doc/document/img134.png +0 -0
- data/doc/ep_flux/math-doc/document/img135.png +0 -0
- data/doc/ep_flux/math-doc/document/img136.png +0 -0
- data/doc/ep_flux/math-doc/document/img137.png +0 -0
- data/doc/ep_flux/math-doc/document/img138.png +0 -0
- data/doc/ep_flux/math-doc/document/img139.png +0 -0
- data/doc/ep_flux/math-doc/document/img14.png +0 -0
- data/doc/ep_flux/math-doc/document/img140.png +0 -0
- data/doc/ep_flux/math-doc/document/img141.png +0 -0
- data/doc/ep_flux/math-doc/document/img142.png +0 -0
- data/doc/ep_flux/math-doc/document/img143.png +0 -0
- data/doc/ep_flux/math-doc/document/img144.png +0 -0
- data/doc/ep_flux/math-doc/document/img145.png +0 -0
- data/doc/ep_flux/math-doc/document/img146.png +0 -0
- data/doc/ep_flux/math-doc/document/img147.png +0 -0
- data/doc/ep_flux/math-doc/document/img148.png +0 -0
- data/doc/ep_flux/math-doc/document/img149.png +0 -0
- data/doc/ep_flux/math-doc/document/img15.png +0 -0
- data/doc/ep_flux/math-doc/document/img150.png +0 -0
- data/doc/ep_flux/math-doc/document/img151.png +0 -0
- data/doc/ep_flux/math-doc/document/img152.png +0 -0
- data/doc/ep_flux/math-doc/document/img153.png +0 -0
- data/doc/ep_flux/math-doc/document/img154.png +0 -0
- data/doc/ep_flux/math-doc/document/img155.png +0 -0
- data/doc/ep_flux/math-doc/document/img156.png +0 -0
- data/doc/ep_flux/math-doc/document/img157.png +0 -0
- data/doc/ep_flux/math-doc/document/img158.png +0 -0
- data/doc/ep_flux/math-doc/document/img159.png +0 -0
- data/doc/ep_flux/math-doc/document/img16.png +0 -0
- data/doc/ep_flux/math-doc/document/img160.png +0 -0
- data/doc/ep_flux/math-doc/document/img161.png +0 -0
- data/doc/ep_flux/math-doc/document/img162.png +0 -0
- data/doc/ep_flux/math-doc/document/img163.png +0 -0
- data/doc/ep_flux/math-doc/document/img164.png +0 -0
- data/doc/ep_flux/math-doc/document/img165.png +0 -0
- data/doc/ep_flux/math-doc/document/img166.png +0 -0
- data/doc/ep_flux/math-doc/document/img167.png +0 -0
- data/doc/ep_flux/math-doc/document/img168.png +0 -0
- data/doc/ep_flux/math-doc/document/img169.png +0 -0
- data/doc/ep_flux/math-doc/document/img17.png +0 -0
- data/doc/ep_flux/math-doc/document/img170.png +0 -0
- data/doc/ep_flux/math-doc/document/img171.png +0 -0
- data/doc/ep_flux/math-doc/document/img172.png +0 -0
- data/doc/ep_flux/math-doc/document/img173.png +0 -0
- data/doc/ep_flux/math-doc/document/img174.png +0 -0
- data/doc/ep_flux/math-doc/document/img175.png +0 -0
- data/doc/ep_flux/math-doc/document/img176.png +0 -0
- data/doc/ep_flux/math-doc/document/img177.png +0 -0
- data/doc/ep_flux/math-doc/document/img178.png +0 -0
- data/doc/ep_flux/math-doc/document/img179.png +0 -0
- data/doc/ep_flux/math-doc/document/img18.png +0 -0
- data/doc/ep_flux/math-doc/document/img180.png +0 -0
- data/doc/ep_flux/math-doc/document/img181.png +0 -0
- data/doc/ep_flux/math-doc/document/img182.png +0 -0
- data/doc/ep_flux/math-doc/document/img183.png +0 -0
- data/doc/ep_flux/math-doc/document/img184.png +0 -0
- data/doc/ep_flux/math-doc/document/img185.png +0 -0
- data/doc/ep_flux/math-doc/document/img186.png +0 -0
- data/doc/ep_flux/math-doc/document/img187.png +0 -0
- data/doc/ep_flux/math-doc/document/img188.png +0 -0
- data/doc/ep_flux/math-doc/document/img189.png +0 -0
- data/doc/ep_flux/math-doc/document/img19.png +0 -0
- data/doc/ep_flux/math-doc/document/img190.png +0 -0
- data/doc/ep_flux/math-doc/document/img191.png +0 -0
- data/doc/ep_flux/math-doc/document/img192.png +0 -0
- data/doc/ep_flux/math-doc/document/img193.png +0 -0
- data/doc/ep_flux/math-doc/document/img194.png +0 -0
- data/doc/ep_flux/math-doc/document/img195.png +0 -0
- data/doc/ep_flux/math-doc/document/img196.png +0 -0
- data/doc/ep_flux/math-doc/document/img197.png +0 -0
- data/doc/ep_flux/math-doc/document/img198.png +0 -0
- data/doc/ep_flux/math-doc/document/img199.png +0 -0
- data/doc/ep_flux/math-doc/document/img2.png +0 -0
- data/doc/ep_flux/math-doc/document/img20.png +0 -0
- data/doc/ep_flux/math-doc/document/img200.png +0 -0
- data/doc/ep_flux/math-doc/document/img21.png +0 -0
- data/doc/ep_flux/math-doc/document/img22.png +0 -0
- data/doc/ep_flux/math-doc/document/img23.png +0 -0
- data/doc/ep_flux/math-doc/document/img24.png +0 -0
- data/doc/ep_flux/math-doc/document/img25.png +0 -0
- data/doc/ep_flux/math-doc/document/img26.png +0 -0
- data/doc/ep_flux/math-doc/document/img27.png +0 -0
- data/doc/ep_flux/math-doc/document/img28.png +0 -0
- data/doc/ep_flux/math-doc/document/img29.png +0 -0
- data/doc/ep_flux/math-doc/document/img3.png +0 -0
- data/doc/ep_flux/math-doc/document/img30.png +0 -0
- data/doc/ep_flux/math-doc/document/img31.png +0 -0
- data/doc/ep_flux/math-doc/document/img32.png +0 -0
- data/doc/ep_flux/math-doc/document/img33.png +0 -0
- data/doc/ep_flux/math-doc/document/img34.png +0 -0
- data/doc/ep_flux/math-doc/document/img35.png +0 -0
- data/doc/ep_flux/math-doc/document/img36.png +0 -0
- data/doc/ep_flux/math-doc/document/img37.png +0 -0
- data/doc/ep_flux/math-doc/document/img38.png +0 -0
- data/doc/ep_flux/math-doc/document/img39.png +0 -0
- data/doc/ep_flux/math-doc/document/img4.png +0 -0
- data/doc/ep_flux/math-doc/document/img40.png +0 -0
- data/doc/ep_flux/math-doc/document/img41.png +0 -0
- data/doc/ep_flux/math-doc/document/img42.png +0 -0
- data/doc/ep_flux/math-doc/document/img43.png +0 -0
- data/doc/ep_flux/math-doc/document/img44.png +0 -0
- data/doc/ep_flux/math-doc/document/img45.png +0 -0
- data/doc/ep_flux/math-doc/document/img46.png +0 -0
- data/doc/ep_flux/math-doc/document/img47.png +0 -0
- data/doc/ep_flux/math-doc/document/img48.png +0 -0
- data/doc/ep_flux/math-doc/document/img49.png +0 -0
- data/doc/ep_flux/math-doc/document/img5.png +0 -0
- data/doc/ep_flux/math-doc/document/img50.png +0 -0
- data/doc/ep_flux/math-doc/document/img51.png +0 -0
- data/doc/ep_flux/math-doc/document/img52.png +0 -0
- data/doc/ep_flux/math-doc/document/img53.png +0 -0
- data/doc/ep_flux/math-doc/document/img54.png +0 -0
- data/doc/ep_flux/math-doc/document/img55.png +0 -0
- data/doc/ep_flux/math-doc/document/img56.png +0 -0
- data/doc/ep_flux/math-doc/document/img57.png +0 -0
- data/doc/ep_flux/math-doc/document/img58.png +0 -0
- data/doc/ep_flux/math-doc/document/img59.png +0 -0
- data/doc/ep_flux/math-doc/document/img6.png +0 -0
- data/doc/ep_flux/math-doc/document/img60.png +0 -0
- data/doc/ep_flux/math-doc/document/img61.png +0 -0
- data/doc/ep_flux/math-doc/document/img62.png +0 -0
- data/doc/ep_flux/math-doc/document/img63.png +0 -0
- data/doc/ep_flux/math-doc/document/img64.png +0 -0
- data/doc/ep_flux/math-doc/document/img65.png +0 -0
- data/doc/ep_flux/math-doc/document/img66.png +0 -0
- data/doc/ep_flux/math-doc/document/img67.png +0 -0
- data/doc/ep_flux/math-doc/document/img68.png +0 -0
- data/doc/ep_flux/math-doc/document/img69.png +0 -0
- data/doc/ep_flux/math-doc/document/img7.png +0 -0
- data/doc/ep_flux/math-doc/document/img70.png +0 -0
- data/doc/ep_flux/math-doc/document/img71.png +0 -0
- data/doc/ep_flux/math-doc/document/img72.png +0 -0
- data/doc/ep_flux/math-doc/document/img73.png +0 -0
- data/doc/ep_flux/math-doc/document/img74.png +0 -0
- data/doc/ep_flux/math-doc/document/img75.png +0 -0
- data/doc/ep_flux/math-doc/document/img76.png +0 -0
- data/doc/ep_flux/math-doc/document/img77.png +0 -0
- data/doc/ep_flux/math-doc/document/img78.png +0 -0
- data/doc/ep_flux/math-doc/document/img79.png +0 -0
- data/doc/ep_flux/math-doc/document/img8.png +0 -0
- data/doc/ep_flux/math-doc/document/img80.png +0 -0
- data/doc/ep_flux/math-doc/document/img81.png +0 -0
- data/doc/ep_flux/math-doc/document/img82.png +0 -0
- data/doc/ep_flux/math-doc/document/img83.png +0 -0
- data/doc/ep_flux/math-doc/document/img84.png +0 -0
- data/doc/ep_flux/math-doc/document/img85.png +0 -0
- data/doc/ep_flux/math-doc/document/img86.png +0 -0
- data/doc/ep_flux/math-doc/document/img87.png +0 -0
- data/doc/ep_flux/math-doc/document/img88.png +0 -0
- data/doc/ep_flux/math-doc/document/img89.png +0 -0
- data/doc/ep_flux/math-doc/document/img9.png +0 -0
- data/doc/ep_flux/math-doc/document/img90.png +0 -0
- data/doc/ep_flux/math-doc/document/img91.png +0 -0
- data/doc/ep_flux/math-doc/document/img92.png +0 -0
- data/doc/ep_flux/math-doc/document/img93.png +0 -0
- data/doc/ep_flux/math-doc/document/img94.png +0 -0
- data/doc/ep_flux/math-doc/document/img95.png +0 -0
- data/doc/ep_flux/math-doc/document/img96.png +0 -0
- data/doc/ep_flux/math-doc/document/img97.png +0 -0
- data/doc/ep_flux/math-doc/document/img98.png +0 -0
- data/doc/ep_flux/math-doc/document/img99.png +0 -0
- data/doc/ep_flux/math-doc/document/index.html +101 -0
- data/doc/ep_flux/math-doc/document/internals.pl +258 -0
- data/doc/ep_flux/math-doc/document/labels.pl +265 -0
- data/doc/ep_flux/math-doc/document/next.png +0 -0
- data/doc/ep_flux/math-doc/document/next_g.png +0 -0
- data/doc/ep_flux/math-doc/document/node1.html +104 -0
- data/doc/ep_flux/math-doc/document/node10.html +164 -0
- data/doc/ep_flux/math-doc/document/node11.html +86 -0
- data/doc/ep_flux/math-doc/document/node12.html +166 -0
- data/doc/ep_flux/math-doc/document/node13.html +897 -0
- data/doc/ep_flux/math-doc/document/node14.html +1065 -0
- data/doc/ep_flux/math-doc/document/node15.html +72 -0
- data/doc/ep_flux/math-doc/document/node16.html +81 -0
- data/doc/ep_flux/math-doc/document/node2.html +82 -0
- data/doc/ep_flux/math-doc/document/node3.html +91 -0
- data/doc/ep_flux/math-doc/document/node4.html +149 -0
- data/doc/ep_flux/math-doc/document/node5.html +330 -0
- data/doc/ep_flux/math-doc/document/node6.html +99 -0
- data/doc/ep_flux/math-doc/document/node7.html +98 -0
- data/doc/ep_flux/math-doc/document/node8.html +83 -0
- data/doc/ep_flux/math-doc/document/node9.html +140 -0
- data/doc/ep_flux/math-doc/document/prev.png +0 -0
- data/doc/ep_flux/math-doc/document/prev_g.png +0 -0
- data/doc/ep_flux/math-doc/document/up.png +0 -0
- data/doc/ep_flux/math-doc/document/up_g.png +0 -0
- data/doc/ep_flux/math-doc/document.pdf +0 -0
- data/doc/ep_flux/math-doc/document.tex +2018 -0
- data/doc/gdir.html +412 -0
- data/doc/gdir_client.html +16 -0
- data/doc/gdir_connect_ftp-like.html +61 -0
- data/doc/gdir_server.html +45 -0
- data/doc/ggraph.html +1615 -0
- data/doc/gpcat.html +44 -0
- data/doc/gpcut.html +41 -0
- data/doc/gphys.html +532 -0
- data/doc/gphys_fft.html +324 -0
- data/doc/gphys_grads_io.html +69 -0
- data/doc/gphys_grib_io.html +82 -0
- data/doc/gphys_io.html +120 -0
- data/doc/gphys_io_common.html +18 -0
- data/doc/gphys_netcdf_io.html +283 -0
- data/doc/gplist.html +24 -0
- data/doc/gpmath.html +51 -0
- data/doc/gpmaxmin.html +31 -0
- data/doc/gpprint.html +34 -0
- data/doc/gpview.html +270 -0
- data/doc/grads2nc_with_gphys.html +21 -0
- data/doc/grads_gridded.html +307 -0
- data/doc/grib.html +144 -0
- data/doc/grid.html +212 -0
- data/doc/index.html +133 -0
- data/doc/index.rd +127 -0
- data/doc/netcdf_convention.html +136 -0
- data/doc/unumeric.html +176 -0
- data/doc/update +64 -0
- data/doc/varray.html +299 -0
- data/doc/varraycomposite.html +67 -0
- data/ext_coord.c +209 -0
- data/ext_init.c +7 -0
- data/extconf.rb +42 -0
- data/install.rb +130 -0
- data/interpo.c +497 -0
- data/lib/numru/dcl_mouse.rb +71 -0
- data/lib/numru/dclext_datetime_ax.rb +220 -0
- data/lib/numru/derivative.rb +348 -0
- data/lib/numru/ganalysis/covariance.rb +154 -0
- data/lib/numru/ganalysis/eof.rb +298 -0
- data/lib/numru/ganalysis/histogram.rb +252 -0
- data/lib/numru/ganalysis/met.rb +317 -0
- data/lib/numru/ganalysis/planet.rb +182 -0
- data/lib/numru/ganalysis.rb +7 -0
- data/lib/numru/gdir.rb +1038 -0
- data/lib/numru/gdir_connect_ftp-like.rb +149 -0
- data/lib/numru/ggraph.rb +5838 -0
- data/lib/numru/ggraph_on_merdional_section.rb +178 -0
- data/lib/numru/gphys/assoccoords.rb +359 -0
- data/lib/numru/gphys/attribute.rb +129 -0
- data/lib/numru/gphys/attributenetcdf.rb +80 -0
- data/lib/numru/gphys/axis.rb +963 -0
- data/lib/numru/gphys/coordmapping.rb +286 -0
- data/lib/numru/gphys/coordtransform.rb +209 -0
- data/lib/numru/gphys/derivative.rb +314 -0
- data/lib/numru/gphys/ep_flux.rb +868 -0
- data/lib/numru/gphys/gpcommon.rb +52 -0
- data/lib/numru/gphys/gphys.rb +1207 -0
- data/lib/numru/gphys/gphys_fft.rb +886 -0
- data/lib/numru/gphys/gphys_grads_io.rb +212 -0
- data/lib/numru/gphys/gphys_grib_io.rb +214 -0
- data/lib/numru/gphys/gphys_gtool3_io.rb +162 -0
- data/lib/numru/gphys/gphys_hdfeos5_io.rb +672 -0
- data/lib/numru/gphys/gphys_io.rb +452 -0
- data/lib/numru/gphys/gphys_io_common.rb +126 -0
- data/lib/numru/gphys/gphys_netcdf_io.rb +800 -0
- data/lib/numru/gphys/gphys_nusdas_io.rb +132 -0
- data/lib/numru/gphys/grads_gridded.rb +1638 -0
- data/lib/numru/gphys/grib.rb +2049 -0
- data/lib/numru/gphys/grib_params.rb +1465 -0
- data/lib/numru/gphys/grid.rb +723 -0
- data/lib/numru/gphys/gtool3.rb +771 -0
- data/lib/numru/gphys/interpolate.rb +854 -0
- data/lib/numru/gphys/narray_ext.rb +34 -0
- data/lib/numru/gphys/netcdf_convention.rb +406 -0
- data/lib/numru/gphys/subsetmapping.rb +332 -0
- data/lib/numru/gphys/unumeric.rb +522 -0
- data/lib/numru/gphys/varray.rb +1109 -0
- data/lib/numru/gphys/varraycomposite.rb +415 -0
- data/lib/numru/gphys/varraygrads.rb +225 -0
- data/lib/numru/gphys/varraygrib.rb +177 -0
- data/lib/numru/gphys/varraygtool3.rb +226 -0
- data/lib/numru/gphys/varrayhdfeos5.rb +451 -0
- data/lib/numru/gphys/varraynetcdf.rb +350 -0
- data/lib/numru/gphys/varraynusdas.rb +59 -0
- data/lib/numru/gphys.rb +9 -0
- data/lib/numru/htdir.rb +170 -0
- data/multibitIO.c +567 -0
- data/sample/cira86_to_nc.rb +122 -0
- data/sample/druby_cli1.rb +21 -0
- data/sample/druby_cli2.rb +34 -0
- data/sample/druby_serv1.rb +30 -0
- data/sample/druby_serv2.rb +64 -0
- data/sample/ep_flux/demo_NCEP_1.rb +48 -0
- data/sample/ep_flux/demo_NCEP_2.rb +57 -0
- data/sample/ep_flux/demo_NCEP_3.rb +81 -0
- data/sample/ggraph_latlon_labelling_dr002690.rb +159 -0
- data/sample/ggraph_mapfit-axes_dr002687.rb +131 -0
- data/sample/map_projection.rb +121 -0
- data/sample/ncep_theta_coord.rb +79 -0
- data/test/eof_slp.rb +28 -0
- data/test/mltbit.dat +0 -0
- data/test/test_ep_flux.rb +533 -0
- data/test/test_multibitIO.rb +19 -0
- data/testdata/T.jan.ctl +12 -0
- data/testdata/T.jan.dat +0 -0
- data/testdata/T.jan.grib +0 -0
- data/testdata/T.jan.nc +0 -0
- data/testdata/T.jan.packed.withmiss.nc +0 -0
- data/testdata/UV.jan.nc +0 -0
- data/testdata/assoc_crds.nc +0 -0
- data/testdata/cira86.dat +1332 -0
- metadata +621 -0
@@ -0,0 +1,34 @@
|
|
1
|
+
require "narray"
|
2
|
+
|
3
|
+
class NArray
|
4
|
+
|
5
|
+
@@dump_size_limit = -1 # max len to allow dump / no limit if negative
|
6
|
+
def self.dump_size_limit=(lmt)
|
7
|
+
@@dump_size_limit = lmt
|
8
|
+
end
|
9
|
+
def self.dump_size_limit
|
10
|
+
@@dump_size_limit
|
11
|
+
end
|
12
|
+
|
13
|
+
def self.endian
|
14
|
+
NArray[1].to_s[1] == 1 ? :little : :big
|
15
|
+
end
|
16
|
+
|
17
|
+
def _dump(limit)
|
18
|
+
if (@@dump_size_limit <= 0) || (size <= @@dump_size_limit)
|
19
|
+
Marshal.dump([typecode, shape, NArray.endian, to_s])
|
20
|
+
else
|
21
|
+
raise "size of the NArray (#{size}) is too large to dump "+
|
22
|
+
"(limit: #{DUMP_SIZE_LIMIT})"
|
23
|
+
end
|
24
|
+
end
|
25
|
+
|
26
|
+
def self._load(str)
|
27
|
+
ary = Marshal.load(str)
|
28
|
+
typecode, shape, endian, str = ary
|
29
|
+
na = NArray.to_na(str, typecode, *shape)
|
30
|
+
na = na.swap_byte unless endian == NArray.endian
|
31
|
+
return na
|
32
|
+
end
|
33
|
+
|
34
|
+
end
|
@@ -0,0 +1,406 @@
|
|
1
|
+
require "numru/netcdf"
|
2
|
+
require "numru/netcdf_miss"
|
3
|
+
require "numru/gphys/varray" # for constants of VArray
|
4
|
+
|
5
|
+
=begin
|
6
|
+
|
7
|
+
==INDEX
|
8
|
+
* ((<module NumRu::NetCDF_Conventions>))
|
9
|
+
* ((<module NumRu::NetCDF_Convention_Users_Guide>))
|
10
|
+
* ((<module NumRu::NetCDF_Convention_Users_Guide::Attribute_Mixin>))
|
11
|
+
* ((<module NumRu::NetCDF_Convention_Users_Guide::VArray_Mixin>))
|
12
|
+
* ((<module NumRu::NetCDF_Convention_Wind_Profiler>))
|
13
|
+
|
14
|
+
=module NumRu::NetCDF_Conventions
|
15
|
+
|
16
|
+
NetCDF_Conventions is the general handler of NetCDF conventions for the
|
17
|
+
GPhys library.
|
18
|
+
|
19
|
+
==Module Functions
|
20
|
+
|
21
|
+
---find( netcdf )
|
22
|
+
|
23
|
+
Figures out what NetCDF convention a netcdf file is following.
|
24
|
+
|
25
|
+
ARGUMENTS
|
26
|
+
* ((|netcdf|)) (NetCDF): the file
|
27
|
+
|
28
|
+
RETURN VALUE
|
29
|
+
* a Module (NumRu::NetCDF_Convention_Users_Guide etc.)
|
30
|
+
|
31
|
+
REMARK
|
32
|
+
* The convention is figured out from the 'Conventions' global attribute.
|
33
|
+
You can instead fix the convention by using ((<fix_to>)).
|
34
|
+
|
35
|
+
---fix_to( convention )
|
36
|
+
|
37
|
+
Fix the convention to be returned by ((<find>)) regardless the value
|
38
|
+
of the 'Conventions' attribute.
|
39
|
+
|
40
|
+
ARGUMENTS
|
41
|
+
* ((|convention|)) (Module): NumRu::NetCDF_Convention_Users_Guide etc.
|
42
|
+
|
43
|
+
RETURN VALUE
|
44
|
+
* convention
|
45
|
+
|
46
|
+
---add_history(netcdf, str=nil)
|
47
|
+
|
48
|
+
Adds a line to the 'history' global convention of ((|netcdf|)).
|
49
|
+
The line consists of date, time, user name, and ((|str|))
|
50
|
+
if present (e.g., '2004-03-02 17:52:25 JST horinout> '+str).
|
51
|
+
|
52
|
+
ARGUMENTS
|
53
|
+
* ((|netcdf|)) (NetCDF): the file in which the history is updated
|
54
|
+
* ((|str|)) (nil or String): if present, added to the end of the line.
|
55
|
+
|
56
|
+
=module NumRu::NetCDF_Convention_Users_Guide
|
57
|
+
|
58
|
+
The NetCDF Users Guide Convention
|
59
|
+
(http://www.unidata.ucar.edu/packages/netcdf/docs.html).
|
60
|
+
|
61
|
+
==Constants
|
62
|
+
|
63
|
+
---Attribute_Mixin
|
64
|
+
|
65
|
+
See below: ((<module NumRu::NetCDF_Convention_Users_Guide::Attribute_Mixin>)).
|
66
|
+
|
67
|
+
---VArray_Mixin
|
68
|
+
|
69
|
+
See below: ((<module NumRu::NetCDF_Convention_Users_Guide::VArray_Mixin>)).
|
70
|
+
|
71
|
+
|
72
|
+
==Module Functions
|
73
|
+
|
74
|
+
---to_s
|
75
|
+
Returns a string to be used as representing the convention.
|
76
|
+
The Users Guide Convention does not have one, so a string
|
77
|
+
was tentatively assigned by Horinouchi.
|
78
|
+
|
79
|
+
---coord_var_names(ncvar)
|
80
|
+
Returns the names of coordinate variables for all the dimensions
|
81
|
+
of ((|ncvar|)).
|
82
|
+
|
83
|
+
ARGUMENTS
|
84
|
+
* ((|ncvar|)) (NetCDFVar)
|
85
|
+
|
86
|
+
RETURN VALUE
|
87
|
+
* Array of strings, whose length is the rank of ((|ncvar|)).
|
88
|
+
|
89
|
+
---cell_bounds?(coord_var)
|
90
|
+
Document to be written. (returns false&nil in this convention.)
|
91
|
+
Might be reorganized in future when the gtool4 convention is supported.
|
92
|
+
|
93
|
+
---cell_center?(coord_var)
|
94
|
+
Document to be written. (returns false&nil in this convention.)
|
95
|
+
Might be reorganized in future when the gtool4 convention is supported.
|
96
|
+
|
97
|
+
--------------------------------------------------
|
98
|
+
==module NumRu::NetCDF_Convention_Users_Guide::Attribute_Mixin
|
99
|
+
|
100
|
+
The module to be mixed in NumRu::AttributeNetCDF.
|
101
|
+
|
102
|
+
===Instance Methods
|
103
|
+
|
104
|
+
Methods below will become sigular methods of NumRu::AttributeNetCDF.
|
105
|
+
|
106
|
+
---copy(to=nil)
|
107
|
+
Same as (('super')) (the one overridden by this method),
|
108
|
+
but edits some standard attributes if (('to')) is nil (copy onto memory)):
|
109
|
+
* scale_factor, add_offset: removed, since data copying includes
|
110
|
+
"unpaking" by interpreting them
|
111
|
+
* valid_*, missing_value: unpacked if packed.
|
112
|
+
* _FillValue, FORTRAN_format, C_format: eliminated
|
113
|
+
|
114
|
+
---------------------------------------------------
|
115
|
+
==module NumRu::NetCDF_Convention_Users_Guide::VArray_Mixin
|
116
|
+
|
117
|
+
The module to be mixed in NumRu::VArrayNetCDF.
|
118
|
+
|
119
|
+
===Instance Methods
|
120
|
+
|
121
|
+
Currently none, meaning is that no modification is made
|
122
|
+
in VArrayNetCDF.
|
123
|
+
|
124
|
+
---------------------------------------------------------------------
|
125
|
+
=module NumRu::NetCDF_Convention_Wind_Profiler
|
126
|
+
|
127
|
+
The Wind Profiler convention
|
128
|
+
(http://www.kurasc.kyoto-u.ac.jp/radar-group/wind_profiler_conventions/).
|
129
|
+
|
130
|
+
Inherits NetCDF_Convention_Users_Guide and makes appropriate redefinitions.
|
131
|
+
See ((<module NumRu::NetCDF_Convention_Users_Guide>)) for the description
|
132
|
+
of constants and module functions.
|
133
|
+
|
134
|
+
=end
|
135
|
+
|
136
|
+
module NumRu
|
137
|
+
|
138
|
+
## /// COMMON -->
|
139
|
+
|
140
|
+
class NetCDFVar
|
141
|
+
alias get get_with_miss_and_scaling
|
142
|
+
alias put put_with_miss_and_scaling
|
143
|
+
end
|
144
|
+
|
145
|
+
# Other implicit convention
|
146
|
+
#
|
147
|
+
# * to use the "units" attribute to indicate the physical units
|
148
|
+
# (which is assumed in VArray, the super class of VArrayNetCDF).
|
149
|
+
|
150
|
+
module NetCDF_Conventions
|
151
|
+
module_function
|
152
|
+
|
153
|
+
@@fixed = nil
|
154
|
+
def fix_to( convention )
|
155
|
+
@@fixed == convention
|
156
|
+
end
|
157
|
+
|
158
|
+
def find( netcdf )
|
159
|
+
# netcdf is assumed to be a NetCDF
|
160
|
+
if @@fixed
|
161
|
+
@@fixed
|
162
|
+
else
|
163
|
+
convention = (att=netcdf.att('Conventions')) && att.get
|
164
|
+
case convention
|
165
|
+
#when /gtool/
|
166
|
+
# raise "Sorry, the gtool convention is yet to be supported"
|
167
|
+
when /^Wind Profiler/
|
168
|
+
NetCDF_Convention_Wind_Profiler
|
169
|
+
else
|
170
|
+
#NetCDF_Convention_Users_Guide
|
171
|
+
NetCDF_Convention_CF
|
172
|
+
end
|
173
|
+
end
|
174
|
+
end
|
175
|
+
|
176
|
+
def add_history(netcdf, str=nil)
|
177
|
+
hstatt = netcdf.att('history')
|
178
|
+
if hstatt
|
179
|
+
history = hstatt.get.chomp + "\n"
|
180
|
+
else
|
181
|
+
history = ''
|
182
|
+
end
|
183
|
+
time = Time.now
|
184
|
+
history += ( time.respond_to?(:strftime) ?
|
185
|
+
time.strftime('%Y-%m-%d %H:%M:%S %Z ') : time.to_s ) +
|
186
|
+
( ENV['USER'] || '' ) + '>'
|
187
|
+
history += (' '+str) if str
|
188
|
+
netcdf.put_att('history', history)
|
189
|
+
end
|
190
|
+
|
191
|
+
end
|
192
|
+
|
193
|
+
## <-- COMMON ///
|
194
|
+
|
195
|
+
######################################################
|
196
|
+
## Indivisual Conventions --- Can be figured out by
|
197
|
+
## NetCDF_Conventions.find( netcdf )
|
198
|
+
######################################################
|
199
|
+
|
200
|
+
|
201
|
+
module NetCDF_Convention_Users_Guide
|
202
|
+
# NetCDF Convention of the NetCDF User's Guide
|
203
|
+
# To be used by (not to be included in) NetCDF_IO.
|
204
|
+
|
205
|
+
module Attribute_Mixin
|
206
|
+
|
207
|
+
def _unpack_missing_specification(attr)
|
208
|
+
# -- private method --
|
209
|
+
# unpack missing data specification
|
210
|
+
# if the missing data type is in the external data type)
|
211
|
+
|
212
|
+
ao = attr['add_offset'] # must be narray or nil
|
213
|
+
sf = attr['scale_factor'] # must be narray or nil
|
214
|
+
if ao || sf
|
215
|
+
raise "add_offset is not a numeric" if ao.is_a?(String)
|
216
|
+
raise "scale_factor is not a numeric" if sf.is_a?(String)
|
217
|
+
satyp = ( ao || sf ).typecode
|
218
|
+
extyp = @nv.typecode
|
219
|
+
sf = 1 if !sf
|
220
|
+
ao = 0 if !ao
|
221
|
+
if (x=attr['valid_range']) && (x.typecode==extyp ||x.typecode!=satyp)
|
222
|
+
attr['valid_range'] = x * sf + ao
|
223
|
+
end
|
224
|
+
if (x=attr['valid_min']) && (x.typecode==extyp || x.typecode!=satyp)
|
225
|
+
attr['valid_min'] = x * sf + ao
|
226
|
+
end
|
227
|
+
if (x=attr['valid_max']) && (x.typecode==extyp || x.typecode!=satyp)
|
228
|
+
attr['valid_max'] = x * sf + ao
|
229
|
+
end
|
230
|
+
if (x=attr['missing_value']) && (x.typecode==extyp || x.typecode!=satyp)
|
231
|
+
attr['missing_value'] = x * sf + ao
|
232
|
+
end
|
233
|
+
attr
|
234
|
+
end
|
235
|
+
end
|
236
|
+
private :_unpack_missing_specification
|
237
|
+
|
238
|
+
def _op_attr_edit( attr )
|
239
|
+
# -- private method --
|
240
|
+
|
241
|
+
attr.delete('C_format')
|
242
|
+
attr.delete('FORTRAN_format')
|
243
|
+
|
244
|
+
_unpack_missing_specification(attr)
|
245
|
+
attr.delete('add_offset')
|
246
|
+
attr.delete('scale_factor')
|
247
|
+
attr.delete('_FillValue')
|
248
|
+
##attr.delete('long_name')
|
249
|
+
|
250
|
+
attr
|
251
|
+
end
|
252
|
+
private :_op_attr_edit
|
253
|
+
|
254
|
+
def copy(to=nil)
|
255
|
+
newattr = super
|
256
|
+
newattr = _op_attr_edit(newattr) if !to
|
257
|
+
newattr
|
258
|
+
end
|
259
|
+
|
260
|
+
end # module Attribute_Mixin
|
261
|
+
|
262
|
+
module VArray_Mixin
|
263
|
+
# currently none
|
264
|
+
end # module VArray_Mixin
|
265
|
+
|
266
|
+
####################
|
267
|
+
module_function
|
268
|
+
|
269
|
+
def to_s
|
270
|
+
"NetCDF User's Guide"
|
271
|
+
end
|
272
|
+
|
273
|
+
def coord_var_names(ncvar)
|
274
|
+
# name of the coordinate variables (to be the "pos" object in Axis)
|
275
|
+
ncvar.dim_names
|
276
|
+
end
|
277
|
+
|
278
|
+
def cell_bounds?(coord_var)
|
279
|
+
# whether the coordinate variale represent grid cell bounds.
|
280
|
+
# coordvar (VArray)
|
281
|
+
# return value:
|
282
|
+
result = false # Always false, because User's guide does not define it
|
283
|
+
cell_center_name = nil
|
284
|
+
[result, cell_center_name]
|
285
|
+
end
|
286
|
+
|
287
|
+
def cell_center?(coord_var)
|
288
|
+
# whether the coordinate variale represent grid cell centers.
|
289
|
+
# coordvar (VArray)
|
290
|
+
# return value:
|
291
|
+
# false if not
|
292
|
+
# true if true and the corresponding cell bounds are not identified.
|
293
|
+
# a VArray if true and the bounds are found (returns it)
|
294
|
+
result = false # Always false, because User's guide does not define it
|
295
|
+
cell_bounds_name = nil
|
296
|
+
[result, cell_bounds_name]
|
297
|
+
end
|
298
|
+
|
299
|
+
def aux_var_names(coord_var)
|
300
|
+
nil # no rule for that
|
301
|
+
end
|
302
|
+
|
303
|
+
def assoc_coord_names(data)
|
304
|
+
nil # no rule for that
|
305
|
+
end
|
306
|
+
|
307
|
+
end
|
308
|
+
|
309
|
+
module NetCDF_Convention_CF
|
310
|
+
# http://cf-pcmdi.llnl.gov/
|
311
|
+
|
312
|
+
# < inherit the Users guide convention >
|
313
|
+
|
314
|
+
module Attribute_Mixin
|
315
|
+
include NetCDF_Convention_Users_Guide::Attribute_Mixin
|
316
|
+
end # module Attribute_Mixin
|
317
|
+
module VArray_Mixin
|
318
|
+
include NetCDF_Convention_Users_Guide::VArray_Mixin
|
319
|
+
end # module VArray_Mixin
|
320
|
+
module_function
|
321
|
+
extend NetCDF_Convention_Users_Guide
|
322
|
+
public_class_method :aux_var_names, :coord_var_names, :cell_bounds?, :cell_center?
|
323
|
+
|
324
|
+
########### original part starts here #################
|
325
|
+
|
326
|
+
def assoc_coord_names(data)
|
327
|
+
if s = data.get_att("coordinates")
|
328
|
+
nms = s.split(/ +/)
|
329
|
+
case data.file
|
330
|
+
when NArray
|
331
|
+
nms.delete_if{|nm| !data.file[0].var(nm)}
|
332
|
+
else
|
333
|
+
nms.delete_if{|nm| !data.file.var(nm)}
|
334
|
+
end
|
335
|
+
nms
|
336
|
+
else
|
337
|
+
nil
|
338
|
+
end
|
339
|
+
end
|
340
|
+
|
341
|
+
end
|
342
|
+
|
343
|
+
|
344
|
+
module NetCDF_Convention_Wind_Profiler
|
345
|
+
# Wind Profiler Convention
|
346
|
+
# http://www.kurasc.kyoto-u.ac.jp/radar-group/wind_profiler_conventions/
|
347
|
+
|
348
|
+
module Attribute_Mixin
|
349
|
+
include NetCDF_Convention_Users_Guide::Attribute_Mixin
|
350
|
+
end # module Attribute_Mixin
|
351
|
+
|
352
|
+
module VArray_Mixin
|
353
|
+
include NetCDF_Convention_Users_Guide::VArray_Mixin
|
354
|
+
end # module VArray_Mixin
|
355
|
+
|
356
|
+
########################
|
357
|
+
module_function
|
358
|
+
extend NetCDF_Convention_Users_Guide
|
359
|
+
public_class_method :cell_bounds?, :cell_center?, :assoc_coord_names
|
360
|
+
|
361
|
+
def to_s
|
362
|
+
"Wind Profiler (http://www.kurasc.kyoto-u.ac.jp/radar-group/wind_profiler_conventions/)"
|
363
|
+
end
|
364
|
+
|
365
|
+
def coord_var_names(ncvar)
|
366
|
+
if (c=ncvar.att('coordinates'))
|
367
|
+
coordinates = c.get.split(/ +/)
|
368
|
+
elsif (ct=ncvar.att('t_coordinates')) || (cz=ncvar.att('z_coordinates'))
|
369
|
+
coordinates = Array.new
|
370
|
+
coordinates.push(ct.get) if ct
|
371
|
+
coordinates.push(cz.get) if cz
|
372
|
+
else
|
373
|
+
coordinates = nil
|
374
|
+
end
|
375
|
+
dimnames = ncvar.dim_names
|
376
|
+
if coordinates
|
377
|
+
cdvnames = []
|
378
|
+
coordinates.each{ |varname|
|
379
|
+
var = ncvar.file.var(varname)
|
380
|
+
raise "#{var.inspect} is not 1D" unless var.rank==1
|
381
|
+
dimnm = var.dim(0).name
|
382
|
+
idx = dimnames.index(dimnm)
|
383
|
+
if idx
|
384
|
+
cdvnames[idx] = varname
|
385
|
+
else
|
386
|
+
raise "#{varname} cannot be a coordinate variable -- "+
|
387
|
+
"#{ncvar.file.path} not comply with the Wind Profiler convention"
|
388
|
+
end
|
389
|
+
}
|
390
|
+
for i in 0...dimnames.length
|
391
|
+
cdvnames[i] = dimnames[i] if !cdvnames[i] #if not found, use dimname
|
392
|
+
end
|
393
|
+
cdvnames
|
394
|
+
else
|
395
|
+
# follow the users guide convention
|
396
|
+
dimnames
|
397
|
+
end
|
398
|
+
end
|
399
|
+
|
400
|
+
def aux_var_names(coord_var)
|
401
|
+
Hash['coordinate', coord_var.dim_names[0] ]
|
402
|
+
end
|
403
|
+
|
404
|
+
end
|
405
|
+
|
406
|
+
end # module NumRu
|