AlloViz.Wrappers.Base.Base¶
- class AlloViz.Wrappers.Base.Base(protein, d)[source]¶
Bases:
object
Base class for network calculation
This class uses the ‘__new__’ special method to establish the object’s attributes, which can be extended and/or modified in the child classes’ ‘__new__’. The ‘__init__’ special method is then used to launch calculations, and it can also be extended or overriden by child classes.
It also defines the private methods
_calculate()
to launch calculations, which exploits the child classes’ custom ‘_computation’ private method so that the different packages can be run with them using the standardized information stored in the objects attributes; and_save_pq()
to save the results of the calculations in parquet format. Both can also be extended or overriden by child classes.filter()
allows to filter the calculated raw edges for posterior analysis.- Parameters:
- protein
Protein
object Protein object from which to extract the information for calculation.
- ddict
Dictionary containing all the elements of the protein’s __dict__ and also any keyword arguments passed for calculation. This is needed for successful parallelization, as pickling objects of Base’s child classes means pickling the Protein object and the attributes that are added to it during its __init__ are lost.
- protein
Methods
filter
([filterings])Filter network edges