geney 1.3.68__py2.py3-none-any.whl → 1.3.70__py2.py3-none-any.whl
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Potentially problematic release.
This version of geney might be problematic. Click here for more details.
- geney/Gene.py +3 -1
- geney/splicing_utils.py +29 -29
- {geney-1.3.68.dist-info → geney-1.3.70.dist-info}/METADATA +1 -1
- {geney-1.3.68.dist-info → geney-1.3.70.dist-info}/RECORD +6 -6
- {geney-1.3.68.dist-info → geney-1.3.70.dist-info}/WHEEL +0 -0
- {geney-1.3.68.dist-info → geney-1.3.70.dist-info}/top_level.txt +0 -0
geney/Gene.py
CHANGED
|
@@ -1,4 +1,5 @@
|
|
|
1
1
|
import copy
|
|
2
|
+
import random
|
|
2
3
|
from typing import Any, Dict, List, Tuple, Optional, Iterator, Union, TYPE_CHECKING
|
|
3
4
|
from collections import Counter
|
|
4
5
|
from . import unload_pickle, config
|
|
@@ -143,7 +144,8 @@ class Gene:
|
|
|
143
144
|
tid = self.primary_transcript
|
|
144
145
|
|
|
145
146
|
if tid is None:
|
|
146
|
-
|
|
147
|
+
tid = random.choice(list(self.transcripts.keys()))
|
|
148
|
+
return None #Transcript()
|
|
147
149
|
|
|
148
150
|
if tid not in self.transcripts:
|
|
149
151
|
raise AttributeError(f"Transcript '{tid}' not found in gene '{self.gene_name}'.")
|
geney/splicing_utils.py
CHANGED
|
@@ -631,34 +631,34 @@ def process_pairwise_epistasis_explicit(mid, engine='spliceai'):
|
|
|
631
631
|
acceptors_df.loc['site_type', :] = 1
|
|
632
632
|
|
|
633
633
|
df = pd.concat([acceptors_df, donors_df], axis=1)
|
|
634
|
-
|
|
635
|
-
if df.shape[1] == 0:
|
|
636
|
-
|
|
637
|
-
|
|
638
|
-
mask = df.apply(
|
|
639
|
-
|
|
640
|
-
|
|
641
|
-
|
|
642
|
-
|
|
643
|
-
|
|
644
|
-
)
|
|
645
|
-
|
|
646
|
-
df.loc['synergistic'] = 0
|
|
647
|
-
df.loc['synergistic', mask] = 1
|
|
648
|
-
|
|
649
|
-
mask = df.apply(
|
|
650
|
-
|
|
651
|
-
|
|
652
|
-
|
|
653
|
-
|
|
654
|
-
|
|
655
|
-
)
|
|
656
|
-
|
|
657
|
-
df.loc['antagonistic'] = 0
|
|
658
|
-
df.loc['antagonistic', mask] = 1
|
|
659
|
-
df.loc['mut_id'] = mid
|
|
660
|
-
df.loc['engine'] = engine
|
|
661
|
-
df.loc['site'] = df.columns
|
|
634
|
+
#
|
|
635
|
+
# if df.shape[1] == 0:
|
|
636
|
+
# return df
|
|
637
|
+
#
|
|
638
|
+
# mask = df.apply(
|
|
639
|
+
# lambda col: (
|
|
640
|
+
# (abs(col['residual']) > 0.1) and
|
|
641
|
+
# (abs(col['deviation1'] + col['deviation2']) < 0.1)
|
|
642
|
+
# ),
|
|
643
|
+
# axis=0
|
|
644
|
+
# )
|
|
645
|
+
#
|
|
646
|
+
# df.loc['synergistic'] = 0
|
|
647
|
+
# df.loc['synergistic', mask] = 1
|
|
648
|
+
#
|
|
649
|
+
# mask = df.apply(
|
|
650
|
+
# lambda col: (
|
|
651
|
+
# (abs(col['residual']) > 0.1) and
|
|
652
|
+
# (abs(col['total_deviation']) <= 0.25)
|
|
653
|
+
# ),
|
|
654
|
+
# axis=0
|
|
655
|
+
# )
|
|
656
|
+
#
|
|
657
|
+
# df.loc['antagonistic'] = 0
|
|
658
|
+
# df.loc['antagonistic', mask] = 1
|
|
659
|
+
# df.loc['mut_id'] = mid
|
|
660
|
+
# df.loc['engine'] = engine
|
|
661
|
+
# df.loc['site'] = df.columns
|
|
662
662
|
df = df.rename({mid: 'epistasis', mid.split('|')[0]: 'cv1', mid.split('|')[1]: 'cv2'})
|
|
663
663
|
df = df.T
|
|
664
664
|
return df
|
|
@@ -800,7 +800,7 @@ class Missplicing:
|
|
|
800
800
|
def benchmark_splicing(gene, organism='hg38', engine='spliceai'):
|
|
801
801
|
gene = Gene(gene, organism=organism)
|
|
802
802
|
transcript = gene.transcript()
|
|
803
|
-
if len(transcript.introns) == 0:
|
|
803
|
+
if transcript is None or len(transcript.introns) == 0:
|
|
804
804
|
return None, None
|
|
805
805
|
|
|
806
806
|
transcript.generate_pre_mrna()
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
geney/Fasta_segment.py,sha256=99HxNGNh_MfdVW6hhtlb1vOn7eSmT7oFoEfHDFMxG8w,11275
|
|
2
|
-
geney/Gene.py,sha256=
|
|
2
|
+
geney/Gene.py,sha256=oAdwuguD1qWMTrS158ApW4s3MRcb1ZJlinzVeCZcYwE,6966
|
|
3
3
|
geney/SeqMats.py,sha256=9-eJnfU2w3LGc0XvVvFEO_QrBneTkC6xkZKDfTcEw5o,19282
|
|
4
4
|
geney/Transcript.py,sha256=CpfxYkuCwFILozrtLuiWnlr1mRnMKn4o84HVJislgYs,14499
|
|
5
5
|
geney/__init__.py,sha256=eBdDl42N6UhcYeZDjOnv199Z88fI5_8Y6xW8447OKXM,755
|
|
@@ -16,7 +16,7 @@ geney/pangolin_utils.py,sha256=9jdBXlOcRaUdfi-UpUxHA0AkTMZkUF-Lt7HVZ1nEm3s,2973
|
|
|
16
16
|
geney/power_utils.py,sha256=MehZFUdkJ2EFUot709yPEDxSkXmH5XevMebX2HD768A,7330
|
|
17
17
|
geney/seqmat_utils.py,sha256=wzb3PX5it5bpIFQvcxyzlxfhoJTbHHbsjg0rzh05iVs,19753
|
|
18
18
|
geney/spliceai_utils.py,sha256=tVY0T6F6l3fNoaktpn7Kq0oH5ZM0ThFYt9nPi_lfakw,3077
|
|
19
|
-
geney/splicing_utils.py,sha256=
|
|
19
|
+
geney/splicing_utils.py,sha256=JKQvm-4uJesSIe6_i6UAwhZfojJFGhXv5ZxvrwWy_54,47792
|
|
20
20
|
geney/survival_utils.py,sha256=KnAzEviMuXh6SnVXId9PgsFLSbgkduTvYoIthxN7FPA,6886
|
|
21
21
|
geney/tcga_utils.py,sha256=D_BNHm-D_K408dlcJm3hzH2c6QNFjQsKvUcOPiQRk7g,17612
|
|
22
22
|
geney/tis_utils.py,sha256=la0CZroaKe5RgAyFd4Bf_DqQncklWgAY2823xVst98o,7813
|
|
@@ -25,7 +25,7 @@ geney/translation_initiation/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NM
|
|
|
25
25
|
geney/translation_initiation/tis_utils.py,sha256=AF3siFjuQH-Rs44EV-80zHdbxRMvN4woLFSHroWIETc,4448
|
|
26
26
|
geney/translation_initiation/resources/kozak_pssm.json,sha256=pcd0Olziutq-6H3mFWDCD9cujQ_AlZO-iiOvBl82hqE,1165
|
|
27
27
|
geney/translation_initiation/resources/tis_regressor_model.joblib,sha256=IXb4DUDhJ5rBDKcqMk9zE3ECTZZcdj7Jixz3KpoZ7OA,2592025
|
|
28
|
-
geney-1.3.
|
|
29
|
-
geney-1.3.
|
|
30
|
-
geney-1.3.
|
|
31
|
-
geney-1.3.
|
|
28
|
+
geney-1.3.70.dist-info/METADATA,sha256=4n6FWqVc4DONBOKNmhWZ5RMCik7GMPz8F4l8O5nbcjo,990
|
|
29
|
+
geney-1.3.70.dist-info/WHEEL,sha256=AHX6tWk3qWuce7vKLrj7lnulVHEdWoltgauo8bgCXgU,109
|
|
30
|
+
geney-1.3.70.dist-info/top_level.txt,sha256=O-FuNUMb5fn9dhZ-dYCgF0aZtfi1EslMstnzhc5IIVo,6
|
|
31
|
+
geney-1.3.70.dist-info/RECORD,,
|
|
File without changes
|
|
File without changes
|