Comments (2)
Hi, I'm sorry for reporting several situations at the same time. I met the same problem using the add_aromatic_interactions
from graphein.protein.edges.distance import (add_peptide_bonds,
add_hydrogen_bond_interactions,
add_disulfide_interactions,
add_ionic_interactions,
add_aromatic_interactions,
add_aromatic_sulphur_interactions,
add_cation_pi_interactions
)
new_edge_funcs = {"edge_construction_functions": [add_peptide_bonds,
add_hydrogen_bond_interactions,
add_disulfide_interactions,
add_ionic_interactions,
add_aromatic_interactions,
add_aromatic_sulphur_interactions,
add_cation_pi_interactions
]
}
config = ProteinGraphConfig(**new_edge_funcs)
g = construct_graph(config=config, pdb_code="3ED8")
p = plot_protein_structure_graph(G=g, angle=0, colour_edges_by="kind", colour_nodes_by="seq_position", label_node_ids=False)
plt.suptitle("Protein graph with: peptide backbone, H-Bonds, \n Disulphide, ionic, aromatic, aromatic-sulphur and cation-pi interactions. \n Nodes coloured by sequence position, edges by type")
returned
DEBUG:graphein.protein.graphs:Deprotonating protein. This removes H atoms from the pdb_df dataframe
DEBUG:graphein.protein.graphs:Detected 1134 total nodes
INFO:graphein.protein.edges.distance:Found 372 hbond interactions.
INFO:graphein.protein.edges.distance:Found 25 hbond interactions.
INFO:graphein.protein.edges.distance:Found 10 disulfide interactions.
INFO:graphein.protein.edges.distance:Found 983 ionic interactions.
---------------------------------------------------------------------------
AttributeError Traceback (most recent call last)
[<ipython-input-8-183722266f5a>](https://localhost:8080/#) in <module>()
19
20 config = ProteinGraphConfig(**new_edge_funcs)
---> 21 g = construct_graph(config=config, pdb_code="3ED8")
22 p = plot_protein_structure_graph(G=g, angle=0, colour_edges_by="kind", colour_nodes_by="seq_position", label_node_ids=False)
23 plt.suptitle("Protein graph with: peptide backbone, H-Bonds, \n Disulphide, ionic, aromatic, aromatic-sulphur and cation-pi interactions. \n Nodes coloured by sequence position, edges by type")
4 frames
[/usr/local/lib/python3.7/dist-packages/graphein/protein/utils.py](https://localhost:8080/#) in filter_dataframe(dataframe, by_column, list_of_values, boolean)
81 :rtype: pd.DataFrame
82 """
---> 83 df = dataframe.copy()
84 df = df[df[by_column].isin(list_of_values) == boolean]
85 df.reset_index(inplace=True, drop=True)
AttributeError: 'NoneType' object has no attribute 'copy'
And I checked my pandas version:
import pandas as pd
print(pd.__version__)
1.3.5
May I know is it the problem with pandas
version?
from graphein.
Hey @johnnytam100 this should be fixed in graphein 1.1.0 (pip install graphein==1.1.0
)
Looks like I'd made the fix & not updated the package 🙄 Sorry!
Closing this now, do let me know if it's still not working!
from graphein.
Related Issues (20)
- esm_residue_embedding not working HOT 3
- KeyError: 'kind' for split edge index by edge kind when converting nx to pyg HOT 4
- LMDB Support for FoldComp databases.
- Format convertor for molecules HOT 6
- Support for torch 2.0 docker images
- NameError for missing `os` import in `graphein.protein.graphs` HOT 2
- issue in protein graph HOT 3
- On `rgroup_df=compute_rgroup_dataframe(remove_insertions(raw_pdb_df))` HOT 2
- A small bug in the `creating_datasets_from_the_pdb.ipynb` HOT 1
- PDB structure culstering HOT 4
- FoldCompDataset calls graphein.protein.tensor.Protein with incorrect __init__ arguments HOT 2
- Error during `Getting requirements to build wheel` HOT 3
- Running colab exmaple got an error ModuleNotFoundError: No module named 'torch_geometric' HOT 2
- `graphein.protein.edges.distance.add_distance_threshold` should allow computing distance by "any to any" atomistic even with "residue" granularity set
- can't read pdb ends with .pdb1.gz HOT 3
- [Docs] API Reference for `graphein.ml` is broken
- `ProteinGraphDataset` fails if a single graph construction fails.
- dssp version argument HOT 2
- add insertion code to node_id when insertoins are set to True HOT 2
- Sidechain torsion angle computation fails on examples containing Pyrolysin
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from graphein.