yhr91/GEARS_misc

Missing data file when trying to reproduce results

Closed this issue · 1 comments

Hi Yusuf and Kexin!

Thanks for developing the great tool! I'm trying to reproduce the result in Fig. 2f of the manuscript. According to the instructions, I'm trying to run the paper/fig2_train.py script, but the following error was thrown:

Traceback (most recent call last):
  File "fig2_train.py", line 63, in <module>
    gears_model.model_initialize(hidden_size = 64, no_perturb = no_perturb, go_path = go_path)
  File "<REDACTED>/GEARS_misc/paper/../gears/gears.py", line 147, in model_initialize
    edge_list = get_similarity_network(network_type = 'go', adata = self.adata, threshold = coexpress_threshold, k = num_similar_genes_go_graph, gene_list = self.pert_list, data_path = self.data_path, data_name = self.dataset_name, split = self.split, seed = self.seed, train_gene_set_size = self.train_gene_set_size,
set2conditions = self.set2conditions, gi_go = self.gi_go, dataset = go_path)
  File "<REDACTED>/GEARS_misc/paper/../gears/utils.py", line 169, in get_similarity_network
    df_jaccard = pd.read_csv('/dfs/user/kexinh/gears2/go_essential_all.csv')
  File "<REDACTED>/GEARS_misc/paper/conda/lib/python3.8/site-packages/pandas/io/parsers/readers.py", line 912, in read_csv
    return _read(filepath_or_buffer, kwds)
  File "<REDACTED>/GEARS_misc/paper/conda/lib/python3.8/site-packages/pandas/io/parsers/readers.py", line 577, in _read
    parser = TextFileReader(filepath_or_buffer, **kwds)
  File "<REDACTED>/GEARS_misc/paper/conda/lib/python3.8/site-packages/pandas/io/parsers/readers.py", line 1407, in __init__
    self._engine = self._make_engine(f, self.engine)
  File "<REDACTED>/GEARS_misc/paper/conda/lib/python3.8/site-packages/pandas/io/parsers/readers.py", line 1661, in _make_engine
    self.handles = get_handle(
  File "<REDACTED>/GEARS_misc/paper/conda/lib/python3.8/site-packages/pandas/io/common.py", line 859, in get_handle
    handle = open(
FileNotFoundError: [Errno 2] No such file or directory: '/dfs/user/kexinh/gears2/go_essential_all.csv'

This I believe is the line where the error was raised. It seems that there are some hard-coded file paths that have not been provided in either yhr91/GEARS_misc or snap-stanford/GEARS. Could you help point me to where I can obtain these files so that I might be able to reproduce the result in the paper?

Best!
Zhi-Jie

Sorry for the long delay in getting back. I somehow didn't get notified about this issue.

There were some issues with the new version of GEARS that don't require the inputs that were originally provided in that training script. I've updated that script (fig2_train.py) with the latest version of the code and now it should work.

Let me know if you have any other questions