torchgfn icon indicating copy to clipboard operation
torchgfn copied to clipboard

Add molecules environment

Open saleml opened this issue 2 years ago • 9 comments

Implement the molecules environment following the current API. More functions might be needed !

saleml avatar Sep 02 '22 00:09 saleml

Careful with the versions here, I had some difficulty getting the original example running and here is some correspondence about resolving it from Emmanuel in an email:

Yes indeed, torch-geometric frequently gives us headaches. We had to rely on the internal API to perform certain operations, which changed since we published the code.
Are you using the package versions specified in [requirements.txt](https://github.com/GFNOrg/gflownet/blob/master/requirements.txt)?
Alternatively, I remember updating the code for Trajectory Balance because of that API change, I think if you fix the bits relevant to __slice__ in the model class you should be fine: https://github.com/GFNOrg/gflownet/blob/trajectory_balance/mols/model_block.py```

I haven't had a chance to debug yet, but posting here so we all have access to this information.

danjenson avatar Sep 02 '22 19:09 danjenson

Aha. @danjenson thanks for the heads-up! Did you get it to work?

I'm still looking into this. This env is more involved compared to hypergrid due to a learned proxy, a variable action space, and dependencies on outside packages.

edwardjhu avatar Sep 05 '22 14:09 edwardjhu

Do you have a link @edwardjhu ? Can't the variable action space be handled with forward and backward masks ?

saleml avatar Sep 05 '22 21:09 saleml

It's not the action space per se. Emmanuel's codebase is versatile but not well-documented, and I'm having trouble understanding its structure. Do you have a better grasp of that codebase? If not, I'll sort it out over a call with Emmanuel or Moksh this week.

edwardjhu avatar Sep 05 '22 23:09 edwardjhu

I've never used it !

saleml avatar Sep 06 '22 01:09 saleml

@edwardjhu -- I assume you went with Emmanuel's repo for this project. How hard was it to get going? Any learnings we could import if we wanted to implement a molecule env in this library?

josephdviviano avatar Apr 05 '23 21:04 josephdviviano

Hi Joseph! I was hoping to use this repo to support a paper I was a part of, and what ended up happening was Kolya did the molecule experiment for that paper instead. He might be the best person for your question!

edwardjhu avatar Apr 06 '23 12:04 edwardjhu

Thanks for the info!

josephdviviano avatar Apr 06 '23 12:04 josephdviviano

For reference - the molecule environment they ended up using for this project is here

https://github.com/GFNOrg/GFN_vs_HVI/tree/master/mols

josephdviviano avatar Apr 06 '23 21:04 josephdviviano