my netcdf.open can not open the url I want ;help!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
1 visualizzazione (ultimi 30 giorni)
Mostra commenti meno recenti
error:
...
READDAP_New: did not work at 98 try: lets try again.
READDAP_New: did not work at 99 try: lets try again.
READDAP_New: did not work at 100 try: lets try again.
READDAP_New: did not work at 101 try: lets try again.
错误使用 readdap (line 45)
READDAP_New: repeated failures after 100 queries
出错 get_ECCO_subgrid (line 45)
lon=readdap(path,'LONGITUDE_T',[]);
出错 download_ECCO (line 65)
get_ECCO_subgrid(fname,lonmin,lonmax,latmin,latmax);
出错 make_OGCM (line 122)
eval(['download_',OGCM,'(Ymin,Ymax,Mmin,Mmax,lonmin,lonmax,latmin,latmax,',...
readdap (line 45):
if nargin <2
disp(['not engough input argments']);
elseif nargin <3 || isempty(query)
disp(['READDAP_New: Extract : ', varname])
while isempty(data)
if ntry>nmax
error(['READDAP_New: repeated failures after ',num2str(nmax),' queries'])
end
ntry=ntry+1;
try
ncid = netcdf.open ( url,'NOWRITE' );
varid = netcdf.inqVarID(ncid,varname);
data = netcdf.getVar(ncid,varid,'double');
netcdf.close (ncid);
catch
data=[];
disp(['READDAP_New: did not work at ',num2str(ntry),' try: lets try again.'])
end
end
else
.......
the problem:
2 Commenti
Risposte (1)
R
il 17 Mag 2024
The error occurred because the URL provided is not a valid OPenDAP URL. When the NETCDF-C library encounters a path resembling a URL and lacks additional information, it interprets it as an OPenDAP request.
To address this, you will need to determine the correct OPenDAP URL. The best way to do this is to find the thredds catalog entry for the file and see if the proper OPenDAP URL is listed on that page. You can access the desired dataset via the link below and select the OPENDAP URL to resolve the error:
I tried a few examples from the list and it worked:
ncid = netcdf.open('http://apdrc.soest.hawaii.edu//thredds/dodsC/las/ecco2_cube92/data_apdrc.soest.hawaii.edu_dods_public_data_ECCO_ECCO2_cube92_monthly_mxldepth.jnl','NOWRITE')
Vedere anche
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!