Skip to content

add 3d viz to ligandatommapping#646

Merged
atravitz merged 15 commits intomainfrom
add/3d_mapping_viz
Oct 20, 2025
Merged

add 3d viz to ligandatommapping#646
atravitz merged 15 commits intomainfrom
add/3d_mapping_viz

Conversation

@atravitz
Copy link
Contributor

@atravitz atravitz commented Oct 15, 2025

resolves OpenFreeEnergy/openfe#1498

copied over from openfe and named LigandAtomMapping.view_3d()

the plan is to deprecate openfe.utils.visualization_3d.view_mapping_3d

Tips

  • Comment "pre-commit.ci autofix" to have pre-commit.ci atomically format your PR.
    Since this will create a commit, it is best to make this comment when you are finished with your work.

Checklist

  • Added a news entry

Developers certificate of origin

@atravitz atravitz changed the title first pass at adding 3d viz to ligandatommapping add 3d viz to ligandatommapping Oct 15, 2025
@atravitz atravitz added this to the Release 1.7 milestone Oct 15, 2025
@codecov
Copy link

codecov bot commented Oct 16, 2025

Codecov Report

❌ Patch coverage is 90.24390% with 8 lines in your changes missing coverage. Please review.
✅ Project coverage is 98.76%. Comparing base (ce63dc3) to head (c0052af).
⚠️ Report is 18 commits behind head on main.

Files with missing lines Patch % Lines
gufe/utils.py 75.00% 4 Missing ⚠️
gufe/mapping/ligandatommapping.py 89.28% 3 Missing ⚠️
gufe/visualization/mapping_visualization.py 97.36% 1 Missing ⚠️
Additional details and impacted files
@@            Coverage Diff             @@
##             main     #646      +/-   ##
==========================================
- Coverage   99.05%   98.76%   -0.29%     
==========================================
  Files          40       40              
  Lines        2430     2510      +80     
==========================================
+ Hits         2407     2479      +72     
- Misses         23       31       +8     

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.

@atravitz atravitz marked this pull request as ready for review October 17, 2025 01:23
@atravitz atravitz requested a review from mikemhenry October 17, 2025 14:52
@atravitz
Copy link
Contributor Author

opinions on view_3d vs view_3D?

Copy link
Member

@IAlibay IAlibay left a comment

Choose a reason for hiding this comment

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

I like the spirit / implementation of this approach.

The only thing I would bikeshed on is the name of the method, but purely on a "we might need to unify with draw at some point into a single keyword" - although as I say, not a hill I am that invested in.

@IAlibay
Copy link
Member

IAlibay commented Oct 17, 2025

opinions on view_3d vs view_3D?

I prefer D but only very mildly - I'd go with what you prefer, as long as we're consistent.

)
)

@requires_package("py3Dmol")
Copy link
Contributor

Choose a reason for hiding this comment

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

I think that using this decorator will actually only raise an issue with py3Dmol missing when you actually use the function.

@atravitz atravitz requested a review from mikemhenry October 20, 2025 21:26
tests:
runs-on: ${{ matrix.OS }}
name: "💻-${{matrix.os }} 🐍-${{ matrix.python-version }} 🗃️${{ matrix.pydantic-version }}"
name: "💻-${{matrix.os }} 🐍-${{ matrix.python-version }} 🎨-${{ matrix.py3Dmol }}"
Copy link
Contributor

Choose a reason for hiding this comment

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

good idea! we will need to update the branch rules after we merge this PR in. I am happy with it for now, but it might be better to call it something like "min deps" so we can keep adding things to the install step. We can wait until the next optional dep we add to do this.

@atravitz atravitz merged commit f7f59e3 into main Oct 20, 2025
11 of 13 checks passed
@atravitz atravitz deleted the add/3d_mapping_viz branch October 20, 2025 22:02
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

make visualization apis more consistent

3 participants