From a0aa2fe8762dd481a9742802f10fb0b20ac7a40b Mon Sep 17 00:00:00 2001 From: simbilod Date: Sat, 7 Dec 2024 14:04:20 -0800 Subject: [PATCH 1/3] remove in-place list --- meshwell/labeledentity.py | 1 - meshwell/resolution.py | 3 --- 2 files changed, 4 deletions(-) diff --git a/meshwell/labeledentity.py b/meshwell/labeledentity.py index 00e9596..8f790b3 100644 --- a/meshwell/labeledentity.py +++ b/meshwell/labeledentity.py @@ -205,7 +205,6 @@ def add_refinement_fields_to_model( new_field_indices, n = resolutionspec.apply( model=self.model, current_field_index=n, - refinement_field_indices=refinement_field_indices, entities_mass_dict=entities_mass_dict_sharing, ) refinement_field_indices.extend(new_field_indices) diff --git a/meshwell/resolution.py b/meshwell/resolution.py index 28a431c..52d4838 100644 --- a/meshwell/resolution.py +++ b/meshwell/resolution.py @@ -54,7 +54,6 @@ def apply( model: Any, current_field_index: int, entities_mass_dict, - refinement_field_indices, ) -> int: new_field_indices = [] @@ -117,7 +116,6 @@ def apply( model: Any, current_field_index: int, entities_mass_dict, - refinement_field_indices, ) -> int: new_field_indices = [] @@ -175,7 +173,6 @@ def apply( model: Any, current_field_index: int, entities_mass_dict, - refinement_field_indices, ) -> int: new_field_indices = [] From 6ac52bd5094f8c0ac96516a87139c7b4072444e5 Mon Sep 17 00:00:00 2001 From: simbilod Date: Sat, 7 Dec 2024 15:05:24 -0800 Subject: [PATCH 2/3] remove unused default argument --- meshwell/labeledentity.py | 1 - meshwell/model.py | 1 - 2 files changed, 2 deletions(-) diff --git a/meshwell/labeledentity.py b/meshwell/labeledentity.py index 8f790b3..b1a6381 100644 --- a/meshwell/labeledentity.py +++ b/meshwell/labeledentity.py @@ -122,7 +122,6 @@ def add_refinement_fields_to_model( self, refinement_field_indices: List, refinement_max_index: int, - default_resolution: float, all_entities_dict, boundary_delimiter, ): diff --git a/meshwell/model.py b/meshwell/model.py index 4cb67bc..e509dfd 100644 --- a/meshwell/model.py +++ b/meshwell/model.py @@ -486,7 +486,6 @@ def mesh( ) = entity.add_refinement_fields_to_model( refinement_field_indices, refinement_max_index, - default_characteristic_length, final_entity_dict, boundary_delimiter, ) From 165cca6c48c011c642076af3fa4bd56d888ec021 Mon Sep 17 00:00:00 2001 From: simbilod Date: Sat, 7 Dec 2024 15:15:54 -0800 Subject: [PATCH 3/3] fix bug --- meshwell/labeledentity.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/meshwell/labeledentity.py b/meshwell/labeledentity.py index b1a6381..7a9a6f3 100644 --- a/meshwell/labeledentity.py +++ b/meshwell/labeledentity.py @@ -167,7 +167,7 @@ def add_refinement_fields_to_model( resolutionspec.target_dimension ) ) - for tag in self.tags: + for tag in tags: if tag in entities_mass_dict: entities_mass_dict_sharing[tag] = entities_mass_dict[ tag