diff --git a/readme.md b/readme.md index d9790a82be5b1ad5f52892c13a1c2fb3743848d9..73d3cc913d672c5ee9ac0ebe4913748527f00867 100644 --- a/readme.md +++ b/readme.md @@ -54,7 +54,7 @@ To create a new synethetic dataset: - phantomVelocity_mu: the different mean velocity values per class i.e., the number of means determines the number of classes. - phantomVelocity_sigma: the standard deviation for velocity per class. - numOutput: how many phantom images to generate per class. -2. Run phantomVelocitySS\goFigure.m, specifying the saved .mat file as the input. +2. Run phantomVelocitySSF\goFigure.m, specifying the saved .mat file as the input. ## Notes 1. The NCD code uses the [FLIF](https://flif.info/) compression library. The thunker file for the FLIF library was generated on Ubuntu 22.04 and **may not work** on other Unix platforms. diff --git a/src/MATLAB/phantomKymograph/createPhantom.m b/src/MATLAB/phantomKymograph/createPhantom.m index b30bde588774dd2c7c4772a6bf135f194319b999..7cae33e540e0677fc48d929bfa96df72c58c65fa 100644 --- a/src/MATLAB/phantomKymograph/createPhantom.m +++ b/src/MATLAB/phantomKymograph/createPhantom.m @@ -1,4 +1,4 @@ -function phantomKymo = createPhantom(phSize,phTracks,phVel_mu,phVel_sigma) +function phantomVelcocityOutput = createPhantom(phSize,phTracks,phVel_mu,phVel_sigma) tmp = zeros(phSize,'uint8'); @@ -39,6 +39,6 @@ for i = 1:length(trackSrcPts) end -phantomKymo = tmp; +phantomVelcocityOutput = tmp; end \ No newline at end of file diff --git a/src/MATLAB/phantomKymograph/createSyntheticDataset.m b/src/MATLAB/phantomKymograph/createSyntheticDataset.m index 9799c51ede65671ad98292abacd4965e6ef84729..c046c8047846244a1b33be638ca191216a7ac900 100644 --- a/src/MATLAB/phantomKymograph/createSyntheticDataset.m +++ b/src/MATLAB/phantomKymograph/createSyntheticDataset.m @@ -10,7 +10,7 @@ for i = 1:length(datasetParameters.phantomVelocity_mu) phVel_mu = datasetParameters.phantomVelocity_mu(i); phVel_sigma = datasetParameters.phantomVelocity_sigma(i); - for j = 1:datasetParameters.numKymos + for j = 1:datasetParameters.numOutput tmp = []; tmp.phantomName = strcat(num2str(i),'_',num2str(j)); @@ -19,7 +19,7 @@ for i = 1:length(datasetParameters.phantomVelocity_mu) tmp.phantomSize = phSize; tmp.numTracks = phTracks; tmp.phantomVelocity = [phVel_mu;phVel_sigma]; - tmp.phantomKymo = createPhantom(phSize,phTracks,phVel_mu,phVel_sigma); + tmp.phantomVelocityOutput = createPhantom(phSize,phTracks,phVel_mu,phVel_sigma); syntheticDataset = [syntheticDataset;tmp]; diff --git a/src/MATLAB/phantomKymograph/getPhantomClipLimits.m b/src/MATLAB/phantomKymograph/getPhantomClipLimits.m index c8bbfc8731d9286aa8dbc8877bee7f3c8a491c7e..e25d3c2293c0add2acffb4f4d5a615ec535b9685 100644 --- a/src/MATLAB/phantomKymograph/getPhantomClipLimits.m +++ b/src/MATLAB/phantomKymograph/getPhantomClipLimits.m @@ -1,7 +1,7 @@ function clipLimits = getPhantomClipLimits(syntheticDataset,targetChannel) for ff = 1:length(syntheticDataset) - im_ff = syntheticDataset(ff).phantomKymo(:,:,:,targetChannel); + im_ff = syntheticDataset(ff).phantomVelocityOutput(:,:,:,targetChannel); kp = im_ff(find(im_ff)); diff --git a/src/MATLAB/phantomKymograph/goFigure.m b/src/MATLAB/phantomKymograph/goFigure.m index b7d3fbd879275f2071949cd00bcce9383e76dec2..7d7c97217fd10564ce6306f4590aea17d642a99c 100644 --- a/src/MATLAB/phantomKymograph/goFigure.m +++ b/src/MATLAB/phantomKymograph/goFigure.m @@ -2,9 +2,9 @@ load('sampleDataset_01.mat'); K = 3; -tmp_xy(:,:,1) = squeeze(max(syntheticDataset(1).phantomKymo(:,:,:,1),[],2)); -tmp_xy(:,:,2) = squeeze(max(syntheticDataset(11).phantomKymo(:,:,:,1),[],2)); -tmp_xy(:,:,3) = squeeze(max(syntheticDataset(21).phantomKymo(:,:,:,1),[],2)); +tmp_xy(:,:,1) = squeeze(max(syntheticDataset(1).phantomVelocityOutput(:,:,:,1),[],2)); +tmp_xy(:,:,2) = squeeze(max(syntheticDataset(11).phantomVelocityOutput(:,:,:,1),[],2)); +tmp_xy(:,:,3) = squeeze(max(syntheticDataset(21).phantomVelocityOutput(:,:,:,1),[],2)); figure('Position',[300,200,900,300]); layout1 = tiledlayout(1,3,'TileSpacing','compact','Padding','tight'); diff --git a/src/MATLAB/phantomKymograph/goSyntheticDataset.m b/src/MATLAB/phantomKymograph/goSyntheticDataset.m index 7a241c12f28d77c823336feaf47dbf2f21dca33e..c70cae0e41ca63f3b39806f00bcc9cdd86fe7e07 100644 --- a/src/MATLAB/phantomKymograph/goSyntheticDataset.m +++ b/src/MATLAB/phantomKymograph/goSyntheticDataset.m @@ -6,7 +6,7 @@ synthDatasetParameters.phantomSize = [200,200,25]; synthDatasetParameters.phantomTracks = 10; synthDatasetParameters.phantomVelocity_mu = [1,3,5]; synthDatasetParameters.phantomVelocity_sigma = [.5,.5,.5]; -synthDatasetParameters.numKymos = 50; +synthDatasetParameters.numOutput = 50; syntheticDataset = createSyntheticDataset(synthDatasetParameters); diff --git a/src/MATLAB/phantomKymograph/goSyntheticSSF.m b/src/MATLAB/phantomKymograph/goSyntheticSSF.m index 7278619bf3ae57c61aa600d37e063ab2ab26d0c1..44e11320f35b9ba6edf7da9441026a2a90a599dc 100644 --- a/src/MATLAB/phantomKymograph/goSyntheticSSF.m +++ b/src/MATLAB/phantomKymograph/goSyntheticSSF.m @@ -21,14 +21,14 @@ parfor i=1:H continue end - im_ff = syntheticDataset(ff).phantomKymo(:,:,:,targetChannel); + im_ff = syntheticDataset(ff).phantomVelocityOutput(:,:,:,targetChannel); if ff == gg d1 = SSF.ncd_ssf_volume(im_ff,im_ff); dxx(i,j) = d1; else - im_ff = syntheticDataset(ff).phantomKymo(:,:,:,targetChannel); - im_gg = syntheticDataset(gg).phantomKymo(:,:,:,targetChannel); + im_ff = syntheticDataset(ff).phantomVelocityOutput(:,:,:,targetChannel); + im_gg = syntheticDataset(gg).phantomVelocityOutput(:,:,:,targetChannel); d1 = SSF.ncd_ssf_volume(im_ff,im_gg); d2 = SSF.ncd_ssf_volume(im_gg,im_ff);