Giter VIP home page Giter VIP logo

Comments (8)

sc8668 avatar sc8668 commented on July 23, 2024 1

I know, you should set use_chirality=True and explicit_H=False.

from rtmscore.

sc8668 avatar sc8668 commented on July 23, 2024

you can use the script RTMScore/RTMScore/feats/mol2graph_rdmda_res.py to generate the graph from pdb files.

from rtmscore.

pmorerio avatar pmorerio commented on July 23, 2024

Hi, I have been trying to use the script as well, however it looks like data are prepared in a different way.
Below you find two examples of data extracted by the .bin files you provided on zenodo (https://zenodo.org/record/6859325#.Y1ayTtJBxH5) and the ones generated by the script. Looks like the graphs have different features dimensions. The first graphs (provided) works for training the model. In fact, the second example give a runtime mismatch error in cuda.

Thank you for your time an help.

('3d0e', Graph(num_nodes=31, num_edges=68,
      ndata_schemes={'atom': Scheme(shape=(41,), dtype=torch.float64), 'pos': Scheme(shape=(3,), dtype=torch.float64)}
      edata_schemes={'bond': Scheme(shape=(10,), dtype=torch.int64)}), Graph(num_nodes=99, num_edges=2812,
      ndata_schemes={'feats': Scheme(shape=(41,), dtype=torch.float64), 'ca_pos': Scheme(shape=(3,), dtype=torch.float32), 'center_pos': Scheme(shape=(3,), dtype=torch.float64), 'pos': Scheme(shape=(24, 3), dtype=torch.float64)}
      edata_schemes={'feats': Scheme(shape=(5,), dtype=torch.float64)}))
('03168_2FWZ', Graph(num_nodes=28, num_edges=62,
      ndata_schemes={'pos': Scheme(shape=(3,), dtype=torch.float64), 'atom': Scheme(shape=(38,), dtype=torch.int64)}
      edata_schemes={'bond': Scheme(shape=(6,), dtype=torch.int64)}), Graph(num_nodes=158, num_edges=5072,
      ndata_schemes={'pos': Scheme(shape=(24, 3), dtype=torch.float64), 'feats': Scheme(shape=(41,), dtype=torch.float64)}
      edata_schemes={'feats': Scheme(shape=(5,), dtype=torch.float64)}))

Error in CUDNN

** On entry to SGEMM  parameter number 10 had an illegal value
Traceback (most recent call last):
  File "train_model.py", line 116, in <module>
    total_loss_train, mdn_loss_train, atom_loss_train, bond_loss_train = run_a_train_epoch(epoch, model, train_loader, optimizer, aux_weight=args["aux_weight"], device=args["device"])
  File "/home/pmorerio/code/RTMScore/scripts/../RTMScore/model/utils.py", line 522, in run_a_train_epoch
    pi, sigma, mu, dist, atom_types, bond_types, batch = model(bgp, bgl)
  File "/home/pmorerio/anaconda3/envs/rtmscore/lib/python3.8/site-packages/torch/nn/modules/module.py", line 1051, in _call_impl
    return forward_call(*input, **kwargs)
  File "/home/pmorerio/code/RTMScore/scripts/../RTMScore/model/model2.py", line 499, in forward
    h_l = self.lig_model(bgl, bgl.ndata['atom'].float(), bgl.edata['bond'].float())
  File "/home/pmorerio/anaconda3/envs/rtmscore/lib/python3.8/site-packages/torch/nn/modules/module.py", line 1051, in _call_impl
    return forward_call(*input, **kwargs)
  File "/home/pmorerio/code/RTMScore/scripts/../RTMScore/model/model2.py", line 444, in forward
    node_feats = self.node_encoder(node_feats)
  File "/home/pmorerio/anaconda3/envs/rtmscore/lib/python3.8/site-packages/torch/nn/modules/module.py", line 1051, in _call_impl
    return forward_call(*input, **kwargs)
  File "/home/pmorerio/anaconda3/envs/rtmscore/lib/python3.8/site-packages/torch/nn/modules/linear.py", line 96, in forward
    return F.linear(input, self.weight, self.bias)
  File "/home/pmorerio/anaconda3/envs/rtmscore/lib/python3.8/site-packages/torch/nn/functional.py", line 1847, in linear
    return torch._C._nn.linear(input, weight, bias)
RuntimeError: CUDA error: CUBLAS_STATUS_INVALID_VALUE when calling `cublasSgemm( handle, opa, opb, m, n, k, &alpha, a, lda, b, ldb, &beta, c, ldc)`

from rtmscore.

sc8668 avatar sc8668 commented on July 23, 2024

Are you exactly use the script RTMScore/RTMScore/feats/mol2graph_rdmda_res.py to generate the graphs? I think the same results can be obtained if you directly use this script. Some changes may have been made for my script.

Hi, I have been trying to use the script as well, however it looks like data are prepared in a different way. Below you find two examples of data extracted by the .bin files you provided on zenodo an(https://zenodo.org/record/6859325#.Y1ayTtJBxH5) and the ones generated by the script. Looks like the graphs have different features dimensions. The first graphs (provided) works for training the model. In fact, the second example give a runtime mismatch error in cuda.

Thank you for your time an help.

('3d0e', Graph(num_nodes=31, num_edges=68,
      ndata_schemes={'atom': Scheme(shape=(41,), dtype=torch.float64), 'pos': Scheme(shape=(3,), dtype=torch.float64)}
      edata_schemes={'bond': Scheme(shape=(10,), dtype=torch.int64)}), Graph(num_nodes=99, num_edges=2812,
      ndata_schemes={'feats': Scheme(shape=(41,), dtype=torch.float64), 'ca_pos': Scheme(shape=(3,), dtype=torch.float32), 'center_pos': Scheme(shape=(3,), dtype=torch.float64), 'pos': Scheme(shape=(24, 3), dtype=torch.float64)}
      edata_schemes={'feats': Scheme(shape=(5,), dtype=torch.float64)}))
('03168_2FWZ', Graph(num_nodes=28, num_edges=62,
      ndata_schemes={'pos': Scheme(shape=(3,), dtype=torch.float64), 'atom': Scheme(shape=(38,), dtype=torch.int64)}
      edata_schemes={'bond': Scheme(shape=(6,), dtype=torch.int64)}), Graph(num_nodes=158, num_edges=5072,
      ndata_schemes={'pos': Scheme(shape=(24, 3), dtype=torch.float64), 'feats': Scheme(shape=(41,), dtype=torch.float64)}
      edata_schemes={'feats': Scheme(shape=(5,), dtype=torch.float64)}))

Error in CUDNN

** On entry to SGEMM  parameter number 10 had an illegal value
Traceback (most recent call last):
  File "train_model.py", line 116, in <module>
    total_loss_train, mdn_loss_train, atom_loss_train, bond_loss_train = run_a_train_epoch(epoch, model, train_loader, optimizer, aux_weight=args["aux_weight"], device=args["device"])
  File "/home/pmorerio/code/RTMScore/scripts/../RTMScore/model/utils.py", line 522, in run_a_train_epoch
    pi, sigma, mu, dist, atom_types, bond_types, batch = model(bgp, bgl)
  File "/home/pmorerio/anaconda3/envs/rtmscore/lib/python3.8/site-packages/torch/nn/modules/module.py", line 1051, in _call_impl
    return forward_call(*input, **kwargs)
  File "/home/pmorerio/code/RTMScore/scripts/../RTMScore/model/model2.py", line 499, in forward
    h_l = self.lig_model(bgl, bgl.ndata['atom'].float(), bgl.edata['bond'].float())
  File "/home/pmorerio/anaconda3/envs/rtmscore/lib/python3.8/site-packages/torch/nn/modules/module.py", line 1051, in _call_impl
    return forward_call(*input, **kwargs)
  File "/home/pmorerio/code/RTMScore/scripts/../RTMScore/model/model2.py", line 444, in forward
    node_feats = self.node_encoder(node_feats)
  File "/home/pmorerio/anaconda3/envs/rtmscore/lib/python3.8/site-packages/torch/nn/modules/module.py", line 1051, in _call_impl
    return forward_call(*input, **kwargs)
  File "/home/pmorerio/anaconda3/envs/rtmscore/lib/python3.8/site-packages/torch/nn/modules/linear.py", line 96, in forward
    return F.linear(input, self.weight, self.bias)
  File "/home/pmorerio/anaconda3/envs/rtmscore/lib/python3.8/site-packages/torch/nn/functional.py", line 1847, in linear
    return torch._C._nn.linear(input, weight, bias)
RuntimeError: CUDA error: CUBLAS_STATUS_INVALID_VALUE when calling `cublasSgemm( handle, opa, opb, m, n, k, &alpha, a, lda, b, ldb, &beta, c, ldc)`

from rtmscore.

pmorerio avatar pmorerio commented on July 23, 2024

Yes, I have used the script RTMScore/RTMScore/feats/mol2graph_rdmda_res.py to generate the second graph (03168_2FWZ), while the firs graph (3d0e) was stored inside v2020_train_l.bin provided on zenodo at https://zenodo.org/record/6859325#.Y1ayTtJBxH5. With the graphs provided on zenodo I am able to retrain the model, while I get errors with the graphs generated by your script. Maybe you have used a different script to generate v2020_train_l.bin?

from rtmscore.

pmorerio avatar pmorerio commented on July 23, 2024

Ok, thank you very much, I will try that!

from rtmscore.

pmorerio avatar pmorerio commented on July 23, 2024

Definitely works, thank you.

from rtmscore.

Related Issues (19)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.