Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions PANDORA/Database/Database.py
Original file line number Diff line number Diff line change
Expand Up @@ -37,8 +37,8 @@ def set_reverse(self, reverse):
self.__reverse()
self.reverse = reverse

def download_data(self, data_dir = f'{PANDORA.PANDORA_data}/database', download = True):
"""download_data(self, data_dir = f'{PANDORA.PANDORA_data}/database', download = True)
def download_data(self, data_dir = PANDORA.PANDORA_data + '/database', download = True):
"""download_data(self, data_dir = PANDORA.PANDORA_data + '/database', download = True)
Download all MHC structures and get a two lists that contains all MHCI and MHCII IDs respectively"""

if download:
Expand Down
20 changes: 6 additions & 14 deletions PANDORA/PMHC/Model.py
Original file line number Diff line number Diff line change
@@ -1,14 +1,11 @@
from pyexpat import model
from Bio.PDB import PDBParser
from Bio.SeqUtils import seq1
from Bio import pairwise2
import os
from Bio.PDB import PDBIO
import PANDORA
import traceback
from Bio.PDB import *
import sys

from Bio import pairwise2
from Bio.SeqUtils import seq1
from Bio.PDB import PDBParser, PDBIO, Select

import PANDORA

class Model:

Expand Down Expand Up @@ -117,8 +114,6 @@ def calc_LRMSD(self, reference_pdb, atoms = ['C', 'CA', 'N', 'O'], ligand_zone="
self.flanking_lrmsd = sim.compute_lrmsd_pdb2sql(exportpath=None, method='svd', name=atoms)
except:
print('An error occurred while calculating the rmsd for target %s, model %s for %s' %(ref_path, decoy_path, ligand_zone))
#print('An error occurred while calculating the rmsd for target %s, model %s' %(self.target.id, self.model_path))
traceback.print_exc()
raise Exception('Please check your model and ref info for model %s' %self.model_path)

# remove intermediate files
Expand Down Expand Up @@ -519,7 +514,6 @@ def remove_mismatched_atoms_from_pdb(ref, decoy, atoms):
continue
return ref, decoy


class NotDisordered(Select): # Inherit methods from Select class
'''
Keep one Alternative location for the given atom
Expand All @@ -530,6 +524,4 @@ def accept_atom(self, atom):
atom.set_altloc(" ") # Eliminate alt location ID before output.
return True
else: # Alt location was not one to be output.
return False


return False
1 change: 1 addition & 0 deletions PANDORA/PMHC/PMHC.py
Original file line number Diff line number Diff line change
Expand Up @@ -607,6 +607,7 @@ def fill_allele_seq_info(self, use_templ_seq=False):
def make_output_dir(self):
''' Create an output directory and move the template pdb there
Uses self.output_dir (str): Path to output directory. Defaults to os.getcwd().

Args:
None
'''
Expand Down
21 changes: 15 additions & 6 deletions docs/source/conf.py
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
#!/usr/bin/env python3
# -*- coding: utf-8 -*-
#
# DeepRank documentation build configuration file, created by
# PANDORA documentation build configuration file, created by
# sphinx-quickstart on Mon Feb 26 14:44:07 2018.
#
# This file is execfile()d with the current directory set to its
Expand All @@ -23,10 +23,19 @@
#from unittest import mock

class Mock(MagicMock):
# @classmethod
# def __getattr__(cls, name):
# return MagicMock()
@classmethod
def __getattr__(cls, name):
return MagicMock()

if name == "__file__":
return "/dev/null" # Provide a fake file path if needed
elif name == "__path__":
return [] # Return an empty list for __path__ (often needed for packages)
elif name == "__all__":
return [] # Ensure that `import *` works by providing an empty __all__
else:
return MagicMock()

MOCK_MODULES = [
'NumPy',
Expand Down Expand Up @@ -94,16 +103,16 @@ def __getattr__(cls, name):
# built documents.
#
# The short X.Y version.
version = '2.0'
version = '2.0.0'
# The full version, including alpha/beta/rc tags.
release = '2.0'
release = '2.0.0'

# The language for content autogenerated by Sphinx. Refer to documentation
# for a list of supported languages.
#
# This is also used if you do content translation via gettext catalogs.
# Usually you set "language" from the command line for these cases.
language = None
language = 'English'

# List of patterns, relative to source directory, that match files and
# directories to ignore when looking for source files.
Expand Down
Loading