MPI-Dortmund / tomotwin-cryoet

cryo-ET particle picking by representation and metric learning
Mozilla Public License 2.0
31 stars 6 forks source link

IndexError: Boolean index has wrong length #109

Open pankajumich opened 1 month ago

pankajumich commented 1 month ago

Hi all, I am getting the following error when i am trying to save selected particles.

File ~/.local/lib/python3.10/site-packages/pandas/core/indexers/utils.py:539, in check_array_indexer(array=Index([3313, 3314, 3315, 3316, 3317, 3318, 3319,...5, 4866, 4867], dtype='int64', length=1555), indexer=<class 'numpy.ndarray'> (4868,) bool) 537 # GH26658 538 if len(indexer) != len(array): --> 539 raise IndexError( 540 f"Boolean index has wrong length: " 541 f"{len(indexer)} instead of {len(array)}" 542 ) 543 elif is_integer_dtype(dtype): 544 try:

IndexError: Boolean index has wrong length: 4868 instead of 1555 ################################################## How can i change the length, which seems causing the problem while the saving the coordinates.

Thank you, Pankaj.

thorstenwagner commented 1 month ago

Hi Pankaj,

can you describe in more detail what you did because I cant reproduce it? I assumed you opened a tloc file after picking and applied some threshold and now want to save the results. This seems to work for me. Maybe I misunderstood you?

Best Thorsten

pankajumich commented 1 month ago

Hi Thorsten, Thanks for responding. You got me right, I am trying to save the particles after changing the metric range, but I get the error mentioned in the previously.

Best, Pankaj.

Screenshot 2024-10-01 at 1 34 10 PM
thorstenwagner commented 1 month ago

Can you send me the tloc file?

pankajumich commented 1 month ago

Hi Thorsten, Please excuse my late response. Please find attached the tloc file.

Thank you, Pankaj.

On Mon, Oct 7, 2024 at 3:48 AM Thorsten Wagner @.***> wrote:

Can you send me the tloc file?

— Reply to this email directly, view it on GitHub https://github.com/MPI-Dortmund/tomotwin-cryoet/issues/109#issuecomment-2396171731, or unsubscribe https://github.com/notifications/unsubscribe-auth/BJGUFYHXPM3QCVDMJBXADBTZ2I4FTAVCNFSM6AAAAABO5MIQBKVHI2DSMVQWIX3LMV43OSLTON2WKQ3PNVWWK3TUHMZDGOJWGE3TCNZTGE . You are receiving this because you authored the thread.Message ID: @.***>

thorstenwagner commented 1 month ago

It seems that the attachment via mail has failed

pankajumich commented 4 weeks ago

I am not able to attach the tloc file here.