Skip to content
Snippets Groups Projects
Commit 1db16259 authored by ac's avatar ac
Browse files

onh_rnfl_thickness

parent c6d61f5b
Branches
No related tags found
No related merge requests found
......@@ -6,10 +6,10 @@ function imf = getImf(pData,radii)
% radii = {[0.5,8,8]}; % plate
%
% NGPU = HIP.Cuda.DeviceCount;
NGPU = HIP.Cuda.DeviceCount;
% p = ljsStartParallel(8*NGPU);
N_CUDA_PROCS = 48;
N_CUDA_PROCS = 16 * NGPU;
startTarget = 1;
imf = {};
im1 = Composite();
......
tic
ROOT = '/g/leverjs/Schuman_OCT/OCT/qualified';
ROOT = '/g/leverjs/Schuman_OCT/OCT/qualifiedYes';
PID = 'P10010';
% PID = 'P10125'
flist = dir(fullfile(ROOT,['/' PID '*.LEVER']));
mx = regexp({flist.name},'P(?<PID>\d+)_(?<scanType>.+)_(?<date>\d+-\d+-\d+)_(?<time>\d+-\d+-\d+)_(?<eye>\w\w)_(?<scanID>.+?)_.*.LEVER','names');
tblMeta = struct2table(vertcat(mx{:}));
......@@ -15,10 +16,10 @@ tblMeta = tblMeta(contains(tblMeta.scanType,'Optic'),:);
p = ljsStartParallel(96);
% radii = {[0.5,8,8],[5,5,5],[0,0,0]}; % plate,blob
radii = {[0.5,8,8],[5,5,5],[0,0,0]}; % plate,blob
% radii = {[0.5,8,8]}; % plate
radii = {[3]} % dark tubes
% radii = {[3]} % dark tubes
imf = RSF.getImf(tblMeta,radii);
d = [];
parfor i = 1:length(imf)
......
Hi Andy,
Sorry for the messy spreads. But yes, those would be the files which contain the MD used in classification (column R).
And yes the Project IDs should be associated with the image files.
This data probably needed some tidying up before being shared but if you would still like to work on it its important to make sure that we use tests with
• threshold of Visual Field 24-2 Test Pattern (column I)
• have a qualification_status of yes (column CE)
• have < 33% average false_positive_p, false_negative_p, fixation_loss_c_p (columns F,G,H)
In regards to multiple MDs on the same visit, besides the rows that are outright duplicates, please select the tests which have the lower total reliability errors (columns F,G,H).
I hope that clarifies some of the issues, in the meantime I will work on resending a cleaner dataset!
Best,
Ronald
SAVE_FOLDER = './results';
if ~exist("SAVE_FOLDER",'dir')
mkdir('SAVE_FOLDER');
end
datetime
kernelCorrStart = tic();
eye = 'OD';
ROOT = '/g/leverjs/Schuman_OCT/OCT/qualified';
ROOT = '/g/leverjs/Schuman_OCT/OCT/qualifiedYes';
% scanType = 'Macular Cube 200x200';
scanType = 'Optic Disc Cube 200x200';
......@@ -12,11 +16,15 @@ tblMeta = getMetaOCT(ROOT,eye,scanType);
load('../qualify/onh_rnfl_thickness.mat');
radii = {[0.5,8,8],[5,5,5],[4]}; % plate,blob
% radii = {[0.5,8,8]}; % plate
% radii = {[0.5,8,8],[5,5,5],[8]}; % plate,blob
% radii = {[0.5,8,8],[5,5,5],[0]}; % plate,blob
radii = {[0.5,8,8]}; % plate
[rho2,tblVelo, pData, dxx] = kernelCorr(radii,tblVFMD,tblMeta,tblRNFL);
[rmse1,~] = regnetCorr(tblVelo);median(rmse1)
saveFile = fullfile(SAVE_FOLDER,['qualYes_ncdVSvfmd_' jsonencode(radii) '.mat']);
save(saveFile)
......@@ -7,7 +7,7 @@ function [err,mdlX] = regnetCorr(tblVelo)
% X = [tblVelo.ncd,tblVelo.md];
t2 = tblVelo(tblVelo.dmd~=0,:);
X1 = [t2.ncd];
X1 = [t2.ncd,t2.deltaRNFL];
X2 = [t2.ncd,t2.md];
T = t2.dmd;
% T = t2.deltaRNFL;
......@@ -27,8 +27,11 @@ for i = 1:length(xTarget)
mdlX{i} = mdl;
pred = mdl.predict(xTarget(i,:));
err(i) = abs(T(i) - pred);
[i,median(err)]
fprintf(1,'%d,%0.2f, ',i,median(err));
drawnow;
if mod(i,10) == 0,fprintf(1,'\n');end
end
fprintf(1,'\n');
% mean(err)
4;
ROOT = '/g/leverjs/Schuman_OCT/OCT/combined';
target = '/g/leverjs/Schuman_OCT/OCT/qualified';
target = '/g/leverjs/Schuman_OCT/OCT/qualifiedYes';
if ~exist(target,'dir')
mkdir(target);
end
% flist = dir(fullfile(ROOT,'**/*.LEVER'));
% qONH = readtable('nyu onh matched.xlsx');
% qMacula = readtable('nyu mac matched.xlsx');
% [~,fONH,~] = fileparts(qONH.file_name);
% [~,fMacula,~] = fileparts(qMacula.file_name);
flist = dir(fullfile(ROOT,'**/*.LEVER'));
qONH = readtable('nyu onh matched.xlsx');
qMacula = readtable('nyu mac matched.xlsx');
[~,fONH,~] = fileparts(qONH.file_name);
[~,fMacula,~] = fileparts(qMacula.file_name);
qlist = [];
for i = 1 : length(flist)
......@@ -23,11 +23,10 @@ for i = 1 : length(flist)
continue
end
qs = lower(tidx.qualification_status);
if any(strcmp(qs,'no'))
continue
end
if any(strcmp(qs,'yes'))
qlist = [qlist,flist(i)];
src = fullfile(flist(i).folder,fname);
cmd = ['cp "' src '".* ' target];
system(cmd);
end
end
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment