Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
26 commits
Select commit Hold shift + click to select a range
c2e4d6a
Added numba code
nipunarora8 Mar 24, 2025
bbf74c8
Added changes
nipunarora8 Mar 24, 2025
8a0754b
Optimized code
nipunarora8 Mar 24, 2025
ffb4ce5
Napari Visualization Added
nipunarora8 Mar 28, 2025
904f6df
Updated notebook
nipunarora8 Apr 7, 2025
507d344
Enabling Transonic. Using pyproject.toml with setup.py
jtle00 Apr 19, 2025
8d03389
Added code with waypoints
nipunarora8 Apr 22, 2025
8c4f2ec
Updated waypointastar code
nipunarora8 Apr 22, 2025
eafca48
Changes before test PyPI
jtle00 Aug 14, 2025
9015edc
Removing extra unnecessary files from merge
jtle00 Aug 14, 2025
95715d7
Create publish_test_pypi
jtle00 Aug 14, 2025
e24812a
Rename publish_test_pypi to publish_test_pypi.yml
jtle00 Aug 14, 2025
a9d4f86
Update publish_test_pypi.yml
jtle00 Aug 14, 2025
d16a7db
Update publish_test_pypi.yml
jtle00 Aug 14, 2025
4d6133c
Update publish_test_pypi.yml
jtle00 Aug 14, 2025
e07a43e
Update pyproject.toml
jtle00 Aug 15, 2025
0337193
Cleaning up code before merge
jtle00 Aug 19, 2025
0379ad9
Disable test pypi workflow
jtle00 Aug 19, 2025
7a43123
Fixed jupyter notebook typo
jtle00 Aug 19, 2025
0d4afbe
Update and rename publish_test_pypi.yml to publish_test_pypi.yml.old
jtle00 Aug 19, 2025
9d062f6
Merge branch 'j-dev' of https://github.com/jtle00/brightest-path-lib …
jtle00 Aug 19, 2025
c6b10a2
Delete setup_transonic.py
jtle00 Aug 19, 2025
f7facae
Disabling transonic
jtle00 Aug 20, 2025
3b3144e
Disabling transonic part 2
jtle00 Aug 20, 2025
effcf9d
Add support for installation and usage without Numba
jtle00 Sep 11, 2025
6544174
Cleanup: remove leftover print statements
jtle00 Sep 12, 2025
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
34 changes: 34 additions & 0 deletions .github/workflows/publish_test_pypi.yml.old
Original file line number Diff line number Diff line change
@@ -0,0 +1,34 @@
name: Publish brightest to test PyPi (johnson)

on:
release:
types: [published] # Runs when a new GitHub release is published

jobs:
deploy:
runs-on: ubuntu-latest
steps:
- name: Checkout source (johnson)
uses: actions/checkout@v3
with:
fetch-depth: 0 # needed so setuptools_scm can get tags

- name: Set up Python (johnson)
uses: actions/setup-python@v4
with:
python-version: "3.x"

- name: Install dependencies (johnson)
run: |
python -m pip install --upgrade pip
pip install -U setuptools wheel twine build
pip install -U .

- name: Build and publish (johnson)
env:
TWINE_USERNAME: __token__
TWINE_PASSWORD: ${{ secrets.TEST_PYPI_TOKEN }}
run: |
git tag
python -m build .
twine upload --repository testpypi dist/*
9 changes: 8 additions & 1 deletion brightest_path_lib/algorithm/__init__.py
Original file line number Diff line number Diff line change
@@ -1,2 +1,9 @@
from .astar import AStarSearch
from .nbastar import NBAStarSearch

# Try to import the numba-optimized version first, fall back to non-numba version
try:
import numba
from .numba_nbastar import NBAStarSearch as NBAStarSearch
except (ModuleNotFoundError, ImportError):
# numba not available, use the non-numba version
from .nbastar import NBAStarSearch as NBAStarSearch
8 changes: 4 additions & 4 deletions brightest_path_lib/algorithm/astar.py
Original file line number Diff line number Diff line change
Expand Up @@ -31,8 +31,8 @@
import numpy as np
from queue import PriorityQueue, Queue
from typing import List, Tuple
from brightest_path_lib.cost import ReciprocalTransonic
from brightest_path_lib.heuristic import EuclideanTransonic
from brightest_path_lib.cost import Reciprocal
from brightest_path_lib.heuristic import Euclidean
from brightest_path_lib.image import ImageStats
from brightest_path_lib.input import CostFunction, HeuristicFunction
from brightest_path_lib.node import Node
Expand Down Expand Up @@ -124,12 +124,12 @@ def __init__(
self.open_nodes = open_nodes

if cost_function == CostFunction.RECIPROCAL:
self.cost_function = ReciprocalTransonic(
self.cost_function = Reciprocal(
min_intensity=self.image_stats.min_intensity,
max_intensity=self.image_stats.max_intensity)

if heuristic_function == HeuristicFunction.EUCLIDEAN:
self.heuristic_function = EuclideanTransonic(scale=self.scale)
self.heuristic_function = Euclidean(scale=self.scale)

self.is_canceled = False
self.found_path = False
Expand Down
5 changes: 3 additions & 2 deletions brightest_path_lib/algorithm/nbastar.py
Original file line number Diff line number Diff line change
@@ -1,6 +1,8 @@
# algorithm/nbastar.py

"""The New Bidirectional A* Search Algorithm is an improvement over the
"""

The New Bidirectional A* Search Algorithm is an improvement over the
original Bidirectional A* Search algorithm, which is a variation of the
A* Search algorithm that searches from both the start and goal nodes
simultaneously in order to find the shortest path more efficiently.
Expand Down Expand Up @@ -49,7 +51,6 @@
from brightest_path_lib.input import CostFunction, HeuristicFunction
from brightest_path_lib.node import Node, BidirectionalNode


class NBAStarSearch:
"""NBA* Implementation

Expand Down
Loading