Skip to content
Advertisement

Output is an empty file

My code does not throw an error, it simply creates the files, but of which are empty. I tried it from the command line, and it works using the wildcard training_set_pssm/*.pssm path, but I must do it from the IDE because it is not printing the correct output anyway.
The input file is a set of checkpoint files that look like this: Checkpointfile-.pssm

From this file, which is a text file, saved as .pssm, essentially, I am extracting only the PROFILE side, which is on the right and NORMALIZING it at the same time… my code does not seem to do it correctly, and from the IDE it does not do it at all, so I am not sure what I need to modify in the script to do so at this point.

Here is the code:

JavaScript

Advertisement

Answer

First and foremost lets fix your paths, you imported from pathlib import Path but never used it.

lets declare infile = Path('/Users/name/Desktop/PDB/training_set_pssm/idlist/'), we now have some helpfull functions we can use for finding problems.

try out some of these to make sure you are searching in the right place.

JavaScript

let’s start at the beginning I’ll try and explain what is happening in your code line by line.

JavaScript

solution:

JavaScript
User contributions licensed under: CC BY-SA
8 People found this is helpful
Advertisement