Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Atom and bond features #453

Merged
merged 37 commits into from
Nov 28, 2024
Merged

Atom and bond features #453

merged 37 commits into from
Nov 28, 2024

Conversation

sveccham
Copy link
Collaborator

@sveccham sveccham commented Nov 19, 2024


Implements classes for featurizing atoms and bonds.

  • Implemented atom and bond featurization classes
  • Implemented classes can be used for featurizing atoms and bonds in a molecular graph in order to form inputs for graph neural networks
  • Usage example 1: from bionemo.geometric.atom_featurizers import AromaticityFeaturizer, AtomicNumFeaturizer
  • Usage example 2: from bionemo.geometric.bond_featurizers import RingFeaturizer

Usage

How does a user interact with the changed code?

from bionemo.geometric.atom_featurizers import DegreeFeaturizer
df = DegreeFeaturizer()
mol = Chem.MolFromSmiles("CCCC")
feats = df.get_features(mol.GetAtomWithIdx(0))

Testing

Tests for these changes can be run via:

pytest -v tests/bionemo/geometric/test_atom_featurizers.py
pytest -v tests/bionemo/geometric/test_bond_featurizers.py

@sveccham sveccham self-assigned this Nov 19, 2024
@sveccham
Copy link
Collaborator Author

/build-ci

@sveccham sveccham added the enhancement New feature or request label Nov 19, 2024
@sveccham sveccham marked this pull request as ready for review November 20, 2024 06:37
@sveccham sveccham marked this pull request as draft November 20, 2024 19:53
@sveccham
Copy link
Collaborator Author

/build-ci

@sveccham sveccham marked this pull request as ready for review November 20, 2024 23:28
@sveccham sveccham requested a review from scal444 November 20, 2024 23:31
@sveccham
Copy link
Collaborator Author

/build-ci

@sveccham
Copy link
Collaborator Author

/build-ci

@sveccham sveccham enabled auto-merge (squash) November 27, 2024 23:23
@sveccham
Copy link
Collaborator Author

/build-ci

@sveccham sveccham closed this Nov 27, 2024
auto-merge was automatically disabled November 27, 2024 23:24

Pull request was closed

@sveccham sveccham reopened this Nov 27, 2024
@sveccham
Copy link
Collaborator Author

/build-ci

@sveccham sveccham enabled auto-merge (squash) November 27, 2024 23:40
Copy link
Collaborator

@DejunL DejunL left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM. Just a general question, I'm wondering if there is an easy way to support batch featurization where potentially different molecules can be included in the batch

@sveccham
Copy link
Collaborator Author

/build-ci

@sveccham sveccham merged commit 92369d7 into main Nov 28, 2024
4 checks passed
@sveccham sveccham deleted the sveccham/impl_atom_bond_feats branch November 28, 2024 03:45
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants