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

Implement MatchMaker model #67

Merged
merged 8 commits into from
Feb 1, 2022

Conversation

andrejlamov
Copy link
Collaborator

@andrejlamov andrejlamov commented Feb 1, 2022

Summary

Closes #23

  • Unit tests provided for these changes
  • Documentation and docstrings added for these changes

Changes

Implement the MatchMaker model.

"""

# The left drug
hidden_left = torch.cat([context_features, drug_features_left], dim=1)
Copy link
Collaborator

@cthoyt cthoyt Feb 1, 2022

Choose a reason for hiding this comment

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

since the code is exactly duplicated between the left and right drug (besides the input), consider splitting this into a helper function

@cthoyt
Copy link
Collaborator

cthoyt commented Feb 1, 2022

Please run tox -re lint locally to make sure that you use the newest version of black for code reformatting

@codecov-commenter
Copy link

codecov-commenter commented Feb 1, 2022

Codecov Report

Merging #67 (5133f74) into main (a2fb02f) will increase coverage by 0.22%.
The diff coverage is 98.00%.

Impacted file tree graph

@@            Coverage Diff             @@
##             main      #67      +/-   ##
==========================================
+ Coverage   93.75%   93.97%   +0.22%     
==========================================
  Files          29       29              
  Lines         800      846      +46     
==========================================
+ Hits          750      795      +45     
- Misses         50       51       +1     
Impacted Files Coverage Δ
chemicalx/models/matchmaker.py 97.50% <97.43%> (-2.50%) ⬇️
tests/unit/test_models.py 100.00% <100.00%> (ø)

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update a2fb02f...5133f74. Read the comment docs.

:param out_channels: The number of output channels.
:param dropout_rate: The rate of dropout before the scoring head is used.
"""

Copy link
Collaborator

Choose a reason for hiding this comment

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

remove blank line (please read CI results carefully or run tox -e flake8 locally)

@cthoyt cthoyt added the model label Feb 1, 2022
andrejlamov and others added 3 commits February 1, 2022 21:21
Co-authored-by: Charles Tapley Hoyt <cthoyt@gmail.com>
@benedekrozemberczki benedekrozemberczki marked this pull request as ready for review February 1, 2022 20:32
@cthoyt
Copy link
Collaborator

cthoyt commented Feb 1, 2022

I'd like to push a few simplifications to this model before merge - like using some nn.Sequentials

@benedekrozemberczki benedekrozemberczki merged commit e025146 into AstraZeneca:main Feb 1, 2022
benedekrozemberczki added a commit that referenced this pull request Feb 1, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Add the MatchMaker model
4 participants