diff --git a/datasets/raise/split_and_compare_prnus_of_subgroups.py b/datasets/raise/split_and_compare_prnus_of_subgroups.py index 68ef827..567fb36 100755 --- a/datasets/raise/split_and_compare_prnus_of_subgroups.py +++ b/datasets/raise/split_and_compare_prnus_of_subgroups.py @@ -18,6 +18,8 @@ NUMBER_OF_SUBGROUPS = 2 DENOISER = 'wavelet' IMAGES_FOLDER = 'flat-field/TIF' +setting = IMAGES_FOLDER.replace('/', '_') + f'_{DENOISER}' + imagesFileNames = os.listdir(IMAGES_FOLDER) # To not have a bias (chronological for instance) when split to make subgroups. shuffle(imagesFileNames) @@ -46,10 +48,11 @@ minimum = np.min(mostImagesSubgroupPrnuEstimatesNpArray) maximum = np.max(mostImagesSubgroupPrnuEstimatesNpArray) for subgroupIndex in range(NUMBER_OF_SUBGROUPS): - plt.imsave(f'prnu_subgroup_{subgroupIndex}.png', (subgroupsIterativeMean[subgroupIndex].mean - minimum) / (maximum - minimum)) + plt.imsave(f'{setting}_estimated_prnu_subgroup_{subgroupIndex}.png', (subgroupsIterativeMean[subgroupIndex].mean - minimum) / (maximum - minimum)) plt.title(f'RMS between both subgroups estimated PRNUs with {DENOISER} denoiser for a given number of images among them') plt.xlabel('Number of images of each subgroup') plt.ylabel('RMS between both subgroups estimated PRNUs') plt.plot(rmss) -plt.show() \ No newline at end of file +plt.savefig(f'{setting}_rms_between_estimated_prnu_of_2_subgroups.svg') +#plt.show()