Skip to content

Conversation

KarimElHouari
Copy link
Contributor

No description provided.

@KarimElHouari KarimElHouari requested a review from a team as a code owner April 30, 2025 14:14
@github-actions github-actions bot added enhancement General improvements to existing features tests Related with improvements of the test suite labels Apr 30, 2025
try:
right_atrium_epi = model.mesh.get_surface(model.right_atrium.epicardium.id)
except AttributeError:
LOGGER.error("Cannot find left atrium to create Bachmann bundle")
Copy link
Member

Choose a reason for hiding this comment

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

Suggested change
LOGGER.error("Cannot find left atrium to create Bachmann bundle")
LOGGER.error("Cannot find left atrium to create Bachmann bundle.")

Should have concluding punctuation in messages.

try:
left_atrium_epi = model.mesh.get_surface(model.left_atrium.epicardium.id)
except AttributeError:
LOGGER.error("Cannot find left atrium to create Bachmann bundle")
Copy link
Member

Choose a reason for hiding this comment

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

Suggested change
LOGGER.error("Cannot find left atrium to create Bachmann bundle")
LOGGER.error("Cannot find left atrium to create Bachmann bundle.")

bachmann_start = HeartModelUtils.define_bachman_bundle_start_node(model=model)
bachmann_end = HeartModelUtils.define_bachman_bundle_end_node(model=model)

# compute bachmann bundle without including it in model due to LS-DYNA bug in R16
Copy link
Member

Choose a reason for hiding this comment

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

Suggested change
# compute bachmann bundle without including it in model due to LS-DYNA bug in R16
# compute Bachmann bundle without including it in model due to LS-DYNA bug in R16

assert np.allclose(ba_end.xyz, np.array([-48.38608303, 109.46168253, 424.58923502]))
assert ba_end.node_id == 108609



def test_create_conductionbeams_on_surface():
"""Test conductionbeams can be initialized correctly on a surface."""
Copy link
Member

Choose a reason for hiding this comment

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

Suggested change
"""Test conductionbeams can be initialized correctly on a surface."""
"""Test conduction beams can be initialized correctly on a surface."""

Brief descriptions should generally not have code entities. Was "conductionbeams" the name of the test? Maybe reword to "Initialize test of conduction beams on a surface." Is the "correctly" necessary? Would anything ever be initialized incorrectly on a surface?

Copy link
Member

@PipKat PipKat left a comment

Choose a reason for hiding this comment

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

Minor changes and questions noted in PR. Doc approval isn't the same as technical approval. Ensure that a technical reviewer approves.

@@ -177,7 +178,7 @@ def define_his_bundle_bifurcation_node(
if target_coord is None:
av_coord = LandMarks.AV_NODE.xyz
if av_coord is None:
LOGGER.error("AV node need to be defined before.")
LOGGER.error("AV node needs to be defined before.")
Copy link
Member

Choose a reason for hiding this comment

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

Suggested change
LOGGER.error("AV node needs to be defined before.")
LOGGER.error("AV node must be defined before.")

Must be defined before what?

@@ -243,7 +244,7 @@ def define_his_bundle_end_node(
# find n-th closest point to bifurcation
bifurcation_coord = LandMarks.HIS_BIF_NODE.xyz
if bifurcation_coord is None:
LOGGER.error("AV node need to be defined before.")
LOGGER.error("AV node needs to be defined before.")
Copy link
Member

Choose a reason for hiding this comment

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

Suggested change
LOGGER.error("AV node needs to be defined before.")
LOGGER.error("AV node must be defined before.")

Must be defind before what?

if target_coord is None:
sa_coord = LandMarks.SA_NODE.xyz
if sa_coord is None:
LOGGER.error("SA node needs to be defined before.")
Copy link
Member

Choose a reason for hiding this comment

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

Suggested change
LOGGER.error("SA node needs to be defined before.")
LOGGER.error("SA node must be defined before.")

Must be defind before what?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement General improvements to existing features tests Related with improvements of the test suite
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants