<div dir="ltr">Hi Alfredo,<div><br></div><div>Actually, the function that computes the md5hash is in <a href="https://github.com/SPINEProject/Loris-MRI/blob/62ae20930af73935a3a03071307b2575abf165f1/uploadNeuroDB/NeuroDB/MRI.pm#L1135">https://github.com/SPINEProject/Loris-MRI/blob/62ae20930af73935a3a03071307b2575abf165f1/uploadNeuroDB/NeuroDB/MRI.pm#L1135</a>. </div><div><br></div><div>My guess is that the list of headers used to determine the uniqueness of the file is not enough to differentiate between the two segmentation files you mention even though they are from two completely different images. Maybe you need to add another header in that function to make sure that each segmentation file you insert is unique? I don't know what those files look like but I would investigate in that direction if I were you.</div><div><br></div><div>Hope this helps,</div><div><br></div><div>Cécile</div><div><br></div></div><br><div class="gmail_quote"><div dir="ltr" class="gmail_attr">On Mon, Aug 22, 2022 at 4:32 PM Morales Pinzon, Alfredo <<a href="mailto:AMORALESPINZON@bwh.harvard.edu">AMORALESPINZON@bwh.harvard.edu</a>> wrote:<br></div><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex">
<div style="overflow-wrap: break-word;">
Dear LorisDev team,
<div><br>
</div>
<div>I just came across an issue for about 100 segmentations that I’m attaching to some images using the script “<a href="http://register_processed_data.pl" target="_blank">register_processed_data.pl</a>”. I found that the hash for two different files is exactly the same, and thus one of the files cannot be uploaded.
The segmentations are different and are linked to two different images.</div>
<div><br>
</div>
<div>Here is the code that is finding the “duplicate” hash in the database:</div>
<div><a href="https://github.com/SPINEProject/Loris-MRI/blob/62ae20930af73935a3a03071307b2575abf165f1/uploadNeuroDB/NeuroDB/MRI.pm#L1188-L1206" target="_blank">https://github.com/SPINEProject/Loris-MRI/blob/62ae20930af73935a3a03071307b2575abf165f1/uploadNeuroDB/NeuroDB/MRI.pm#L1188-L1206</a></div>
<div><br>
</div>
<div>What do you think I can do in this case? I’m happy to share the anonymized segmentation files if needed.</div>
<div><br>
</div>
<div><span style="color:rgb(0,0,0)">I am running Loris-MRI v23.0-release.</span></div>
<div><br>
</div>
<div>On a side note, when the script “ <span style="color:rgb(0,0,0)"><a href="http://register_processed_data.pl" target="_blank">register_processed_data.pl</a></span>” exits there is no error message send to the terminal. <font color="#000000"><span>Can
we add an error printer when this happens? This is where the script is exiting in my case:</span></font></div>
<div><a href="https://github.com/SPINEProject/Loris-MRI/blob/62ae20930af73935a3a03071307b2575abf165f1/uploadNeuroDB/register_processed_data.pl#L329" target="_blank">https://github.com/SPINEProject/Loris-MRI/blob/62ae20930af73935a3a03071307b2575abf165f1/uploadNeuroDB/register_processed_data.pl#L329</a></div>
<div><br>
</div>
<div>Best regards,</div>
<div>Alfredo.</div>
<p class="MsoNormal">The information in this e-mail is intended only for the person to whom it is addressed. If you believe this e-mail was sent to you in error and the e-mail contains patient information, please contact the Mass General Brigham Compliance HelpLine at <a href="https://www.massgeneralbrigham.org/complianceline" target="_blank">https://www.massgeneralbrigham.org/complianceline</a> .</p><br>
<p class="MsoNormal">Please note that this e-mail is not secure
(encrypted). If you do not wish to continue communication over
unencrypted e-mail, please notify the sender of this message immediately. Continuing to send or respond to e-mail after receiving this message means you
understand and accept this risk and wish to continue to communicate over
unencrypted e-mail. </p></div>
_______________________________________________<br>
Loris-dev mailing list<br>
<a href="mailto:Loris-dev@bic.mni.mcgill.ca" target="_blank">Loris-dev@bic.mni.mcgill.ca</a><br>
<a href="https://mailman.bic.mni.mcgill.ca/mailman/listinfo/loris-dev" rel="noreferrer" target="_blank">https://mailman.bic.mni.mcgill.ca/mailman/listinfo/loris-dev</a><br>
</blockquote></div>