Comments (3)
I have the same question. I think this will cause a huge data leakage problem in your training, because your validation and test set is created independently for gene_adj
and gene_adj.transpose(copy=True)
, and therefore the edges from the validation / test set in gene_adj
is actually included in the training set of gene_adj.transpose(copy=True)
.
Same problem goes for the train / validate set between gene_drug_adj
and drug_gene_adj
. The validation edges from gene_drug_adj
are actually used for training in drug_gene_adj
, and vise versa.
Could you please clarify?
Thanks!
from decagon.
@bbjy I guess the author would like to use adj and adj.transpose to represent undirect graphs for PPI network and drug-drug network. For the interactions between proteins and drugs, the information flow is represented with bipartite graphs.
from decagon.
@hurleyLi I am also confused on the problem you mentioned.
Here are the source codes for spliting training/val/testing edges:
def mask_test_edges(self, edge_type, type_idx):
edges_all, _, _ = preprocessing.sparse_to_tuple(self.adj_mats[edge_type][type_idx])
num_test = max(50, int(np.floor(edges_all.shape[0] * self.val_test_size)))
num_val = max(50, int(np.floor(edges_all.shape[0] * self.val_test_size)))
all_edge_idx = list(range(edges_all.shape[0]))
np.random.shuffle(all_edge_idx)
val_edge_idx = all_edge_idx[:num_val]
val_edges = edges_all[val_edge_idx]
test_edge_idx = all_edge_idx[num_val:(num_val + num_test)]
test_edges = edges_all[test_edge_idx]
train_edges = np.delete(edges_all, np.hstack([test_edge_idx, val_edge_idx]), axis=0)
It seems that the author splits the edges independently for different type_idx, which will cause training and cross validation overlap.
from decagon.
Related Issues (16)
- Trained model release?
- ERROR: Could not find a version that satisfies the requirement futures==3.2.0 HOT 1
- AttributeError: module 'tensorflow' has no attribute 'app' HOT 4
- futures==3.1.1 instead of futures==3.2.0
- has this repo have any supports?
- How to apply the real datasets HOT 1
- Does Decagon regard the relation and its corresponding reverse one as different relations? HOT 2
- Can you supply the instructions about how to use real-world data to train model HOT 18
- Confusion about weights update
- when i am running this code on Collab it is showing me this error message. Can anyone tell me please how to fix it.
- Please provide instructions on how to use the data set with the code. HOT 3
- Could you tell the meaning of variable n_drugdrug_rel_types in main.py? HOT 4
- Unsupported feed type HOT 2
- variables' means
- data leakage problem in your model HOT 1
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 decagon.