ww2283 / AF-guided-MR

A Python tool that automates molecular replacement using protein sequences and x-ray diffraction data, designed especially to handle difficult cases.
0 stars 0 forks source link

csv file not read #1

Open KevinBattaile opened 17 hours ago

KevinBattaile commented 17 hours ago

When I try to run with this command:

python main.py --mtz_path staraniso_alldata-unique.mtz --csv_path sequence.csv

I get the following error:

2024-10-22 20:22:06 - ERROR - Error in read_sequences_from_csv: CSV header should start with 'id,sequence' Traceback (most recent call last): File "/nsls2/software/mx/nyx/AF-MR/AF-guided-MR/main.py", line 1115, in main() File "/nsls2/software/mx/nyx/AF-MR/AF-guided-MR/main.py", line 90, in main print(f"Processing {len(sequences)} sequences...") TypeError: object of type 'NoneType' has no len()

The format of my sequence file is:

trva,PROTEINSEQ

so I think that is correct and am not sure why it isn't being read in. I did the software install as per the instructions, so I think I have everything installed (but maybe not...).

ww2283 commented 5 hours ago

Thank you for reaching out. Please add a header line 'id,sequence' as the first line. So your csv would go like this:

id,sequence
trva,PROTEINSEQ

This is to comply with the tradition of ColabFold. I will add a check-and-skip for absence of the header line. I will also push some updates soon which may help with a few certain cases in the benchmark set, but current version should be ok for the vast majority of situations.

KevinBattaile commented 5 hours ago

Thanks, that fixed it. I also noticed that there can't be any blank lines at the end of the file.