def isPDBFile(pathFileName): #This method check if the file is a PDB file or not. if the file contains ATOM, REMARK and SEQRES, this file is a PDB. Otherwise, # this file is not a PDB file. path,name = os.path.split(pathFileName) fcfrpFile = FcfrpFile(path,name) #if fcfrpFile.find("ATOM") == -1 and fcfrpFile.find("REMARK") == -1 and fcfrpFile.find("SEQRES") and -1: if fcfrpFile.find("ATOM") == -1 and fcfrpFile.find("SEQRES") == -1: mensage = "The %s file is not a PDB File. Please, check it." % pathFileName raise Exception(mensage)