-
Notifications
You must be signed in to change notification settings - Fork 3
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
Subclass sync: Comments & minor refactor #736
base: develop
Are you sure you want to change the base?
Conversation
- Update: _convert_edge_namespace(): (i) removed unused optional param, (ii) improved documentation. - Update: Improved some comments explaining some confusingly named variables. - Update: Removed 'verbose' param from _get_direct_scr_rels(). This function ran fast, and there was no need to print out the time taken. - Update: Misc codestyle refactors - Update: Case 5 code: Was redundant with some other code. Made DRY.
rels_mondo_mondo_all = set( # filter non-source parents | ||
[x for x in rels_mondo_raw_all if any([x[2].startswith(y) for y in MONDO_PREFIX_MAP.keys()])]) | ||
df5 = pd.DataFrame([{'subject_id': x[0], 'object_id': x[2]} for x in rels_mondo_mondo_all]) | ||
df5 = pd.DataFrame([{'subject_id': x[0], 'object_id': x[2]} for x in rels_direct_mondo_mondo]) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@joeflack4 what change in the subclass data files does this make?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Ah, that is what is mentioned in the OP, and I mentioned in passing at meeting possibly before the holidays:
One refactor here removes a redundant variable
rels_mondo_mondo_all
and replaces it withrels_direct_mondo_mondo
. I tested and confirmed these variables were equivalent.
So there are no changes in outputs.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Comment inline
@matentzn Your review on this as well whenever. Not time sensitive. Removes a duplicate variable. Outputs did not change at all, which can be seen in the mini build. |
Overview
At first I was going to add some helpful comments, but I realized some refactoring could be done.
Pre-merge checklist
Documentation
Was the documentation added/updated under
docs/
?QC
Was the full pipeline run before submitting this PR using
sh run.sh make build-mondo-ingest
on this branch (afterdocker pull obolibrary/odkfull:dev
), and no errors occurred?Build:
New Packages
Were any new Python packages added?
Were any other non-Python packages added?
PR Review and Conversations Resolved
Has the PR been sufficiently reviewed by at least 1 team member of the Mondo Technical team and all threads resolved?
Additional info
One refactor here removes a redundant variable
rels_mondo_mondo_all
and replaces it withrels_direct_mondo_mondo
. I tested and confirmed these variables were equivalent.