Due to a shift in policy, from 0900 GMT on Wednesday 14th July 2021, we will be disabling ssh access to the server for external users. External users who wish to continue to access code repositories on the server will need to switch to using https. This can be accomplished in the following way: 1) On the repo on gitlab, use the clone dialogue and select ‘Clone with HTTPS’ to get the address of the repo; 2) From within the checkout of your repo run: $ git remote set-url origin HTTPS_ADDRESS. Here, replace HTTPS_ADDRESS with the address you have just copied from GitLab. Pulls and pushes will now require you to enter a username and password rather than using a ssh key. If you would prefer not to enter a password each time, you might consider caching your login credentials.

Commit 5b5c59fe authored by Pierre Cazenave's avatar Pierre Cazenave

Fix a few problems with accessing the POLCOMS data due to the new way it's...

Fix a few problems with accessing the POLCOMS data due to the new way it's stored in the pc struct. Also change the way the depth values are interpolated (onto the sigma layers rather than sigma levels
parent b175de75
......@@ -95,9 +95,9 @@ netcdf.close(nc)
% Data format:
%
% pc.ETW and pc.x1X are y, x, sigma, time
% pc.ETW.data and pc.x1X.data are y, x, sigma, time
%
[~, ~, nz, nt] = size(pc.ETW);
[~, ~, nz, nt] = size(pc.ETW.data);
% Make rectangular arrays for the nearest point lookup.
[lon, lat] = meshgrid(pc.lon.data, pc.lat.data);
......@@ -108,8 +108,8 @@ fvlat = Mobj.lat(Mobj.obc_nodes(Mobj.obc_nodes ~= 0));
% Number of boundary nodes
nf = sum(Mobj.nObcNodes);
% Number of sigma levels (although we actually need layers...)
fz = size(Mobj.sigmaz, 2);
% Number of sigma layers.
fz = size(Mobj.siglayz, 2);
% itemp = nan(nf, nz, nt); % POLCOMS interpolated temperatures
% isal = nan(nf, nz, nt); % POLCOMS interpolated salinities
......@@ -121,8 +121,8 @@ if ftbverbose
end
for t = 1:nt
% Get the current 3D array of POLCOMS results.
pctemp3 = pc.ETW(:, :, :, t);
pcsal3 = pc.x1X(:, :, :, t);
pctemp3 = pc.ETW.data(:, :, :, t);
pcsal3 = pc.x1X.data(:, :, :, t);
% Preallocate the intermediate results arrays.
itempz = nan(nf, nz);
......@@ -212,7 +212,7 @@ for t = 1:nt
for zi = 1:fz
for pp = 1:nf
% Get the FVCOM depths at this node
tfz = Mobj.sigmaz(oNodes(pp), :);
tfz = Mobj.siglayz(oNodes(pp), :);
% Now get the interpolated POLCOMS depth at this node
tpz = idepthz(pp, :);
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment