Spaces:
Runtime error
Runtime error
Update app.py
Browse files
app.py
CHANGED
|
@@ -64,6 +64,7 @@ def load_model(model_choice):
|
|
| 64 |
model = GraphDiT(
|
| 65 |
model_config_path=model_config_path,
|
| 66 |
data_info_path=data_info_path,
|
|
|
|
| 67 |
model_dtype=torch.float32,
|
| 68 |
)
|
| 69 |
### test
|
|
@@ -238,7 +239,6 @@ with gr.Blocks(title="Polymer Design with GraphDiT") as iface:
|
|
| 238 |
# Main Description
|
| 239 |
gr.Markdown("""
|
| 240 |
## Introduction
|
| 241 |
-
|
| 242 |
Input the desired gas barrier properties for CH₄, CO₂, H₂, N₂, and O₂ to generate novel polymer structures. The results are visualized as molecular graphs and represented by SMILES strings if they are successfully generated. Note: Gas barrier values set to 0 will be treated as `NaN` (unconditionally). If the generation fails, please retry or increase the number of repetition attempts.
|
| 243 |
""")
|
| 244 |
|
|
@@ -254,15 +254,10 @@ with gr.Blocks(title="Polymer Design with GraphDiT") as iface:
|
|
| 254 |
with gr.Accordion("🔍 Model Description", open=False):
|
| 255 |
gr.Markdown("""
|
| 256 |
### GraphDiT: Graph Diffusion Transformer
|
| 257 |
-
|
| 258 |
GraphDiT is a graph diffusion model designed for targeted molecular generation. It employs a conditional diffusion process to iteratively refine molecular structures based on user-specified properties.
|
| 259 |
-
|
| 260 |
We have collected a labeled polymer database for gas permeability from [Membrane Database](https://research.csiro.au/virtualscreening/membrane-database-polymer-gas-separation-membranes/). Additionally, we utilize unlabeled polymer structures from [PolyInfo](https://polymer.nims.go.jp/).
|
| 261 |
-
|
| 262 |
The gas permeability ranges from 0 to over ten thousand, with only hundreds of labeled data points, making this task particularly challenging.
|
| 263 |
-
|
| 264 |
We are actively working on improving the model. We welcome any feedback regarding model usage or suggestions for improvement.
|
| 265 |
-
|
| 266 |
#### Currently, we have two variants of Graph DiT:
|
| 267 |
- **Graph DiT (trained on labeled + unlabeled)**: This model uses both labeled and unlabeled data for training, potentially leading to more diverse/novel polymer generation.
|
| 268 |
- **Graph DiT (trained on labeled)**: This model is trained exclusively on labeled data, which may result in higher validity but potentially less diverse/novel outputs.
|
|
|
|
| 64 |
model = GraphDiT(
|
| 65 |
model_config_path=model_config_path,
|
| 66 |
data_info_path=data_info_path,
|
| 67 |
+
# model_dtype=torch.float16,
|
| 68 |
model_dtype=torch.float32,
|
| 69 |
)
|
| 70 |
### test
|
|
|
|
| 239 |
# Main Description
|
| 240 |
gr.Markdown("""
|
| 241 |
## Introduction
|
|
|
|
| 242 |
Input the desired gas barrier properties for CH₄, CO₂, H₂, N₂, and O₂ to generate novel polymer structures. The results are visualized as molecular graphs and represented by SMILES strings if they are successfully generated. Note: Gas barrier values set to 0 will be treated as `NaN` (unconditionally). If the generation fails, please retry or increase the number of repetition attempts.
|
| 243 |
""")
|
| 244 |
|
|
|
|
| 254 |
with gr.Accordion("🔍 Model Description", open=False):
|
| 255 |
gr.Markdown("""
|
| 256 |
### GraphDiT: Graph Diffusion Transformer
|
|
|
|
| 257 |
GraphDiT is a graph diffusion model designed for targeted molecular generation. It employs a conditional diffusion process to iteratively refine molecular structures based on user-specified properties.
|
|
|
|
| 258 |
We have collected a labeled polymer database for gas permeability from [Membrane Database](https://research.csiro.au/virtualscreening/membrane-database-polymer-gas-separation-membranes/). Additionally, we utilize unlabeled polymer structures from [PolyInfo](https://polymer.nims.go.jp/).
|
|
|
|
| 259 |
The gas permeability ranges from 0 to over ten thousand, with only hundreds of labeled data points, making this task particularly challenging.
|
|
|
|
| 260 |
We are actively working on improving the model. We welcome any feedback regarding model usage or suggestions for improvement.
|
|
|
|
| 261 |
#### Currently, we have two variants of Graph DiT:
|
| 262 |
- **Graph DiT (trained on labeled + unlabeled)**: This model uses both labeled and unlabeled data for training, potentially leading to more diverse/novel polymer generation.
|
| 263 |
- **Graph DiT (trained on labeled)**: This model is trained exclusively on labeled data, which may result in higher validity but potentially less diverse/novel outputs.
|