From 771fd1e9bbf67a0fc7fefaa2185ee51dfc60d4ab Mon Sep 17 00:00:00 2001 From: "github-actions[bot]" <41898282+github-actions[bot]@users.noreply.github.com> Date: Thu, 11 Jan 2024 05:39:33 +0000 Subject: [PATCH 1/4] chore(master): release 3.0.4 --- CHANGELOG.md | 7 +++++++ map2loop/version.py | 2 +- 2 files changed, 8 insertions(+), 1 deletion(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index b81a9c08..e37fb7df 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,5 +1,12 @@ # Changelog +## [3.0.4](https://github.com/Loop3D/map2loop-3/compare/3.0.3...3.0.4) (2024-01-11) + + +### Bug Fixes + +* Issue with conda build test env not working, skipping ([2fffb69](https://github.com/Loop3D/map2loop-3/commit/2fffb696556f48f0620dfbac356971301fb15e89)) + ## [3.0.3](https://github.com/Loop3D/map2loop-3/compare/3.0.2...3.0.3) (2024-01-11) diff --git a/map2loop/version.py b/map2loop/version.py index 8d1c8625..8e10cb46 100644 --- a/map2loop/version.py +++ b/map2loop/version.py @@ -1 +1 @@ -__version__ = "3.0.3" +__version__ = "3.0.4" From 598d82e1a9649db83c41ec5f7f90d62317b1e8e5 Mon Sep 17 00:00:00 2001 From: Lachlan Grose Date: Thu, 18 Jan 2024 12:12:23 +1100 Subject: [PATCH 2/4] ci: using environment variables to define build matrix --- .github/workflows/CD.yml | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/.github/workflows/CD.yml b/.github/workflows/CD.yml index d884a8d6..dc740787 100644 --- a/.github/workflows/CD.yml +++ b/.github/workflows/CD.yml @@ -10,8 +10,8 @@ jobs: strategy: fail-fast: false matrix: - os: ["ubuntu-latest", "windows-latest"] # , "macos-latest"] - python-version: ["3.8", "3.9", "3.10", "3.11"] + os: ${{ fromJSON(vars.BUILD_OS)}} + python-version: ${{ fromJSON(vars.PYTHON_VERSIONS)}} steps: - uses: actions/checkout@v2 - uses: conda-incubator/setup-miniconda@v2 @@ -59,8 +59,8 @@ jobs: strategy: fail-fast: false matrix: - os: ["ubuntu-latest", "windows-latest"] # , "macos-latest"] - python-version: ["3.8", "3.9", "3.10", "3.11"] + os: ${{ fromJSON(vars.BUILD_OS)}} + python-version: ${{ fromJSON(vars.PYTHON_VERSIONS)}} steps: - uses: conda-incubator/setup-miniconda@v2 with: From 527de6c339e56ead036ab5ed5d94d06d77673ae6 Mon Sep 17 00:00:00 2001 From: RoyThomsonMonash Date: Thu, 25 Jan 2024 10:04:20 +1100 Subject: [PATCH 3/4] fix: Typo in intrusion flag, ignoring intrusions for contact calculations, remove errant sorter from take_best option --- map2loop/mapdata.py | 5 ++++- map2loop/project.py | 2 +- map2loop/sorter.py | 4 +++- 3 files changed, 8 insertions(+), 3 deletions(-) diff --git a/map2loop/mapdata.py b/map2loop/mapdata.py index b90b170f..48d3b0c7 100644 --- a/map2loop/mapdata.py +++ b/map2loop/mapdata.py @@ -719,7 +719,7 @@ def parse_geology_map(self) -> tuple: geology["INTRUSIVE"] = self.raw_data[Datatype.GEOLOGY][config["rocktype_column"]].astype(str).str.contains(config["intrusive_text"]) geology["ROCKTYPE1"] = self.raw_data[Datatype.GEOLOGY][config["rocktype_column"]].astype(str) else: - geology["INSTRUSIVE"] = False + geology["INTRUSIVE"] = False geology["ROCKTYPE1"] = "" if config["alt_rocktype_column"] in self.raw_data[Datatype.GEOLOGY]: @@ -1213,6 +1213,9 @@ def extract_all_contacts(self, save_contacts=True): """ geology = self.get_map_data(Datatype.GEOLOGY).copy() geology = geology.dissolve(by="UNITNAME", as_index=False) + # Remove intrusions + geology = geology[geology["INTRUSIVE"]==False] + geology = geology[geology["SILL"]==False] # Remove faults from contact geomety if self.get_map_data(Datatype.FAULT) is not None: faults = self.get_map_data(Datatype.FAULT).copy() diff --git a/map2loop/project.py b/map2loop/project.py index a3fe4390..0a24dd32 100644 --- a/map2loop/project.py +++ b/map2loop/project.py @@ -348,7 +348,7 @@ def calculate_stratigraphic_order(self, take_best=False): Use unit relationships, unit ages and the sorter to create a stratigraphic column """ if take_best: - sorters = [SorterUseHint(), SorterAgeBased(), SorterAlpha(), SorterUseNetworkX(), SorterMaximiseContacts(), SorterObservationProjections()] + sorters = [SorterUseHint(), SorterAgeBased(), SorterAlpha(), SorterUseNetworkX()] columns = [sorter.sort(self.stratigraphic_column.stratigraphicUnits, self.map2model.get_unit_unit_relationships(), self.map2model.get_sorted_units(), diff --git a/map2loop/sorter.py b/map2loop/sorter.py index 63f72f03..3c30da69 100644 --- a/map2loop/sorter.py +++ b/map2loop/sorter.py @@ -205,7 +205,7 @@ def sort(self, units: pandas.DataFrame, unit_relationships: pandas.DataFrame, st while graph.number_of_nodes() > 0: if cnode is None: df = pandas.DataFrame(columns=["unit", "num_neighbours"]) - df["unit"] = units + df["unit"] = list(graph.nodes) df["num_neighbours"] = df.apply(lambda row: len(list(graph.neighbors(row["unit"]))), axis=1) df.sort_values(by=["num_neighbours"], inplace=True) df.reset_index(inplace=True, drop=True) @@ -320,6 +320,8 @@ def sort(self, units: pandas.DataFrame, unit_relationships: pandas.DataFrame, st return stratigraphic_order_hint geol = map_data.get_map_data(Datatype.GEOLOGY).copy() + geol = geol[geol["INTRUSIVE"]==False] + geol = geol[geol["SILL"]==False] orientations = map_data.get_map_data(Datatype.STRUCTURE).copy() verbose = False From 867607b71182dae0c460b47676fbe0b561e6d1bb Mon Sep 17 00:00:00 2001 From: "github-actions[bot]" <41898282+github-actions[bot]@users.noreply.github.com> Date: Thu, 25 Jan 2024 00:42:45 +0000 Subject: [PATCH 4/4] chore(master): release 3.0.5 --- CHANGELOG.md | 7 +++++++ map2loop/version.py | 2 +- 2 files changed, 8 insertions(+), 1 deletion(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index e37fb7df..2605e894 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,5 +1,12 @@ # Changelog +## [3.0.5](https://github.com/Loop3D/map2loop/compare/3.0.4...3.0.5) (2024-01-25) + + +### Bug Fixes + +* Typo in intrusion flag, ignoring intrusions for contact calculations, remove errant sorter from take_best option ([527de6c](https://github.com/Loop3D/map2loop/commit/527de6c339e56ead036ab5ed5d94d06d77673ae6)) + ## [3.0.4](https://github.com/Loop3D/map2loop-3/compare/3.0.3...3.0.4) (2024-01-11) diff --git a/map2loop/version.py b/map2loop/version.py index 8e10cb46..e94f36fe 100644 --- a/map2loop/version.py +++ b/map2loop/version.py @@ -1 +1 @@ -__version__ = "3.0.4" +__version__ = "3.0.5"