Closed lucas-morin closed 1 year ago
Hi @lucasmorin222 ,
In principle, you can. But the current training scripts are written to be trained on TPUs, You could use the MirroredStrategy instead of the TPU strategy to train on GPU.
Please remove these lines from the training script
tpu = tf.distribute.cluster_resolver.TPUClusterResolver(tpu="node-name")
print("Running on TPU ", tpu.master())
tf.config.experimental_connect_to_cluster(tpu)
tf.tpu.experimental.initialize_tpu_system(tpu)
strategy = tf.distribute.TPUStrategy(tpu)
and replace it with the following:
strategy = tf.distribute.MirroredStrategy(["GPU:0", "GPU:1"])
You can still use TFRecords to train on GPUs so no need to change anything there.
Regards, Kohulan
Thanks, it worked.
I tokenized SMILES using the tokenizer stored in Zenodo:
DECIMER_512_Model_finetuned/assets/tokenizer_SMILES.pkl DECIMER_512_Model_finetuned/assets/max_length.pkl
Thanks for you help! Regards, Lucas
Hello, Is it possible to train DECIMER on a new dataset consisting of pairs of images and SMILES, and without having access to TPUs? Best, Lucas