Spaces:
Sleeping
Sleeping
Commit
·
b7f2233
1
Parent(s):
ff7c96d
Update code/alphafold_featureVector.py
Browse files- code/alphafold_featureVector.py +24 -22
code/alphafold_featureVector.py
CHANGED
@@ -718,28 +718,30 @@ def alphafold(input_set, mode, impute):
|
|
718 |
if sasa_pos != np.NaN:
|
719 |
sasa = 'nan'
|
720 |
for filename in list(Path(path_to_output_files / 'freesasa_files').glob("*")):
|
721 |
-
|
722 |
-
|
723 |
-
|
724 |
-
|
725 |
-
|
726 |
-
|
727 |
-
|
728 |
-
|
729 |
-
|
730 |
-
|
731 |
-
|
732 |
-
|
733 |
-
|
734 |
-
|
735 |
-
|
736 |
-
if
|
737 |
-
|
738 |
-
|
739 |
-
|
740 |
-
|
741 |
-
|
742 |
-
|
|
|
|
|
743 |
else:
|
744 |
sasa = 'nan'
|
745 |
#sasa_val = sasa('alphafold', 'nan', uniprotID, sasa_pos, uniprot_matched.at[i, 'wt'], mode,
|
|
|
718 |
if sasa_pos != np.NaN:
|
719 |
sasa = 'nan'
|
720 |
for filename in list(Path(path_to_output_files / 'freesasa_files').glob("*")):
|
721 |
+
|
722 |
+
if 'readme' not in filename:
|
723 |
+
st.write('xdfkjlxdjf', filename)
|
724 |
+
st.write('string filename')
|
725 |
+
st.write(str(filename))
|
726 |
+
st.write('string filename split')
|
727 |
+
st.write(str(filename).split('.'))
|
728 |
+
st.write(list(filter(None, str(filename).split('.')))[0].split('/')[-1].split('-')[1].upper())
|
729 |
+
fname = list(filter(None, str(filename).split('.')))[0].split('/')[-1].split('-')[1].upper()
|
730 |
+
st.write('fname', fname)
|
731 |
+
|
732 |
+
if uniprotID == fname:
|
733 |
+
files = open(filename, 'r')
|
734 |
+
file = files.readlines()
|
735 |
+
for k in file:
|
736 |
+
if str(k.strip()[10:13]) == str(sasa_pos):
|
737 |
+
residue = str(k[4:7].strip())
|
738 |
+
if wt == threeToOne(residue):
|
739 |
+
sasa = str(k[22:28]).strip('\n')
|
740 |
+
elif wt != threeToOne(residue):
|
741 |
+
sasa = str(k[22:28]).strip('\n') + '*'
|
742 |
+
else:
|
743 |
+
sasa = 'nan'
|
744 |
+
|
745 |
else:
|
746 |
sasa = 'nan'
|
747 |
#sasa_val = sasa('alphafold', 'nan', uniprotID, sasa_pos, uniprot_matched.at[i, 'wt'], mode,
|