torchdrug icon indicating copy to clipboard operation
torchdrug copied to clipboard

Reading own dataset??

Open amarye opened this issue 2 years ago • 1 comments

I am a new user of AI, and I have followed a molecule generation tutorial in Colab. However, I encountered an error when I tried to use my dataset. Unfortunately, I don't know how to solve this error. Could you please assist me?

Screenshot from 2023-09-14 15-37-04

Screenshot from 2023-09-14 15-36-24

amarye avatar Sep 14 '23 07:09 amarye

The dataset you need is not tthe pandas dataset, but an instance of the Dataset object in torchdrug. Try doing something like:

import pandas as pd
from torchdrug.dataset import MoleculeDataset

molecule_dataset = MoleculeDataset.from_smiles(csv_file = "out.csv")

This should do the trick.

Arkhymadhe avatar Feb 24 '24 04:02 Arkhymadhe