Skip to content
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

CI TEST - DO NOT MERGE #510

Open
wants to merge 99 commits into
base: develop
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
99 commits
Select commit Hold shift + click to select a range
3a3488f
Removed `reached_first` from A*
Jake-Moss Jan 9, 2024
c32e91a
Add preliminary route choice
Jake-Moss Jan 9, 2024
7bf8b4e
Return noexcepts
Jake-Moss Jan 9, 2024
b80b6ea
Working RouteChoice generation
Jake-Moss Jan 11, 2024
3e37811
Removed unused variables and junk
Jake-Moss Jan 11, 2024
1a864c5
Notes
Jake-Moss Jan 11, 2024
291bdc0
fixup! Removed unused variables and junk
Jake-Moss Jan 11, 2024
93526c0
fixup! fixup! Removed unused variables and junk
Jake-Moss Jan 11, 2024
1c449df
Rename files
Jake-Moss Jan 11, 2024
08de182
Minor fixes
Jake-Moss Jan 12, 2024
a8b0c54
Use comrpessed graph
Jake-Moss Jan 12, 2024
a08ecc0
Avoid unnessacary work when we may fill the route set this iteration
Jake-Moss Jan 12, 2024
4f46026
Fix pointer issues, move custom imports
Jake-Moss Jan 15, 2024
c74179b
Spelling
Jake-Moss Jan 16, 2024
62b058d
Prevent memory leak when destination is unreachable
Jake-Moss Jan 16, 2024
5ddf8f4
Remove print out
Jake-Moss Jan 16, 2024
5e9aa21
Prevent infinite loop when depth is unlimited
Jake-Moss Jan 16, 2024
8d5cdc6
Prevent oob access and incredible memory consumption (2gb/s) from A*
Jake-Moss Jan 16, 2024
614b77b
Scratch testing on Arkansas
Jake-Moss Jan 16, 2024
e14809c
Remove working_set, PO1 makes this redundant, reduce memory usage
Jake-Moss Jan 17, 2024
129360c
Remove prints
Jake-Moss Jan 17, 2024
dc95778
Add parallelised batched method for running a list of od pairs
Jake-Moss Jan 17, 2024
82204ba
Remove dead code and fix A* test now that skimming is disabled
Jake-Moss Jan 18, 2024
1313f3c
Move `RouteChoice.run` to be wrapper around `RouteChoice.batched`
Jake-Moss Jan 18, 2024
bacc76c
Fix infinite loop in the case that all possible paths are exhausted
Jake-Moss Jan 18, 2024
4d6536f
Add comprehensive testing
Jake-Moss Jan 18, 2024
e55a433
Warning clean up
Jake-Moss Jan 18, 2024
e7647b9
Update commentary and fix memory leak
Jake-Moss Jan 18, 2024
80bd7f7
Typos
Jake-Moss Jan 18, 2024
b45fc9f
Rename and remove imports
Jake-Moss Jan 18, 2024
4e442f1
Disable initialisation and bounds checking
Jake-Moss Jan 18, 2024
4b65f66
Add docs and support blocking centroid flow with tests
Jake-Moss Jan 18, 2024
f0b5cbd
Merge branch 'develop' into route_choice
Jake-Moss Jan 31, 2024
9552907
Remove debug method and fix small typos
Jake-Moss Feb 1, 2024
5253500
Merge branch 'develop' of github.com:AequilibraE/aequilibrae into rou…
Feb 2, 2024
9089fea
typo
Feb 2, 2024
92edd72
Allow switching path finding method
Jake-Moss Feb 2, 2024
007e934
Add debug method for display in tests
Jake-Moss Feb 2, 2024
488006f
Linting
Jake-Moss Feb 2, 2024
0e668a9
Scratch parquet work
Jake-Moss Feb 6, 2024
85fdb12
Better structuring for the table
Jake-Moss Feb 7, 2024
eecaaa3
Add optional immediately disk saving
Jake-Moss Feb 12, 2024
945e8a9
Test fixes
Jake-Moss Feb 12, 2024
e3ea0c6
Update CI workflows
Jake-Moss Feb 12, 2024
4c39a8b
Move pyarrow to a hard dependency for now
Jake-Moss Feb 12, 2024
f18d13c
Linting
Jake-Moss Feb 12, 2024
9ad188b
CI again
Jake-Moss Feb 12, 2024
6c79a17
Warn about duplicate OD pairs, fix memory corruption, disable A*
Jake-Moss Feb 13, 2024
d3677b6
Fix path order
Jake-Moss Feb 14, 2024
b5ed6a4
Add link penalisation
Jake-Moss Feb 14, 2024
738a657
Linting
Jake-Moss Feb 14, 2024
7d15ef0
Add parallelised sparse frequency implementation and test
Jake-Moss Feb 15, 2024
1543549
Remove debug test
Jake-Moss Feb 16, 2024
31aaaad
Add route cost computation and test
Jake-Moss Feb 16, 2024
71257eb
Add psl gamma computation, not sure what to test against
Jake-Moss Feb 16, 2024
7688d75
Add scratch probability implementation
Jake-Moss Feb 16, 2024
b0627e4
Fix probability calculations
Jake-Moss Feb 19, 2024
8c46115
The great refactor, batch probability computations to dump to disk
Jake-Moss Feb 20, 2024
1f195b8
Revert "Update CI workflows"
Jake-Moss Feb 20, 2024
b44721e
Move the pyarrow symlink creation to setup.py
Jake-Moss Feb 20, 2024
0ebce09
tests cibuildwheels
Feb 20, 2024
06b6a44
tests cibuildwheels
Feb 20, 2024
293457a
tests cibuildwheels
Feb 20, 2024
bae7d0d
tests cibuildwheels
Feb 20, 2024
f112262
Add ARM architectures for Linux and mac
Feb 20, 2024
e9e660b
adds emulation
Feb 20, 2024
2458f9a
adds emulation
Feb 20, 2024
b2d5d3d
adds emulation
Feb 20, 2024
c9f2aaa
adds emulation
Feb 20, 2024
ab37eaf
CI
pedrocamargo Feb 20, 2024
0df7565
.
pedrocamargo Feb 20, 2024
ccb9cfa
.
pedrocamargo Feb 20, 2024
9448e76
adds emulation
Feb 20, 2024
3df73da
.
Feb 20, 2024
daf48a5
.
Feb 20, 2024
9f4413e
Merge branch 'develop' of github.com:AequilibraE/aequilibrae into ped…
Feb 20, 2024
ebe3a19
.
Feb 20, 2024
3dafd88
.
Feb 20, 2024
0f954e4
.
Feb 20, 2024
f7ae37e
.
Feb 20, 2024
dd6723f
.
Feb 20, 2024
d58e7cc
Update pyproject.toml
pedrocamargo Feb 20, 2024
315cbce
Update pyproject.toml
pedrocamargo Feb 20, 2024
ba0d882
.
Feb 21, 2024
9f2ca20
.
Feb 21, 2024
f934c34
.
Feb 21, 2024
66ffcc3
.
Feb 21, 2024
24de8f7
Hopefully fix CI
Jake-Moss Feb 21, 2024
cad0579
Maybe MacOS fix
Jake-Moss Feb 21, 2024
a10c791
Maybe fix MacOS again
Jake-Moss Feb 21, 2024
0548be6
Macos test
Jake-Moss Feb 26, 2024
a6b2a8e
Merge branch 'develop' into pedro/ci_test
Jake-Moss Feb 26, 2024
d0def11
.
Jake-Moss Feb 26, 2024
eedb859
.
Jake-Moss Feb 26, 2024
e0c32f2
.
Jake-Moss Feb 26, 2024
b4b945c
.
Jake-Moss Feb 26, 2024
9dc3650
.
Jake-Moss Feb 26, 2024
c77d5e6
.
Jake-Moss Feb 27, 2024
3f2c01b
I give up
Jake-Moss Feb 27, 2024
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
2 changes: 1 addition & 1 deletion .flake8
Original file line number Diff line number Diff line change
Expand Up @@ -3,4 +3,4 @@ max-line-length = 120
ignore = E203, E266, E501, W503, F403, F401, C901, W605
max-complexity = 20
select = B,C,E,F,W,T4,B9
exclude = .idea,.git,__pycache__,sphinx,.venv*,.venv,venv,docs/*,benchmarks/*
exclude = .idea,.git,__pycache__,sphinx,.venv*,.venv,venv,docs/*,benchmarks/*,*.pyx,*pxd,*.pxi
76 changes: 0 additions & 76 deletions .github/workflows/build_linux.yml

This file was deleted.

57 changes: 0 additions & 57 deletions .github/workflows/build_mac.yml

This file was deleted.

58 changes: 58 additions & 0 deletions .github/workflows/build_wheels.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,58 @@
name: Build

on: [pull_request]

jobs:
build_wheels:
name: Build wheels on ${{ matrix.os }}
runs-on: ${{ matrix.os }}
strategy:
matrix:
os: [ubuntu-latest, windows-latest, macos-latest]

steps:
- uses: actions/checkout@v4

- name: Set up QEMU
if: runner.os == 'Linux'
uses: docker/setup-qemu-action@v3
with:
platforms: all

- name: Build wheels
uses: pypa/cibuildwheel@v2.16.5

- uses: actions/upload-artifact@v4
with:
name: cibw-wheels-${{ matrix.os }}-${{ strategy.job-index }}
path: ./wheelhouse/*.whl

make_sdist:
name: Make SDist
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4

- name: Build SDist
run: pipx run build --sdist

- uses: actions/upload-artifact@v4
with:
name: cibw-sdist
path: dist/*.tar.gz

upload_all:
needs: [build_wheels, make_sdist]
environment: pypi
permissions:
id-token: write
runs-on: ubuntu-latest
if: github.event_name == 'release' && github.event.action == 'published'
steps:
- uses: actions/download-artifact@v4
with:
pattern: cibw-*
path: dist
merge-multiple: true

- uses: pypa/gh-action-pypi-publish@release/v1
46 changes: 0 additions & 46 deletions .github/workflows/build_windows.yml

This file was deleted.

2 changes: 1 addition & 1 deletion .github/workflows/debug_tests.yml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
name: Run tests for debugging sigabrt

on: [pull_request]
#on: [pull_request]

jobs:

Expand Down
12 changes: 6 additions & 6 deletions .github/workflows/documentation.yml
Original file line number Diff line number Diff line change
@@ -1,11 +1,11 @@
name: Documentation

on:
push:
branches:
- develop
pull_request:
release:
#on:
# push:
# branches:
# - develop
# pull_request:
# release:

jobs:
build:
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/test_linux_with_coverage.yml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
name: Code coverage

on: [pull_request]
#on: [pull_request]

jobs:
testing:
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/unit_tests.yml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
name: Tests on all platforms with linting

on: [pull_request]
#on: [pull_request]

jobs:
linting:
Expand Down
29 changes: 15 additions & 14 deletions aequilibrae/paths/AoN.pyx
Original file line number Diff line number Diff line change
Expand Up @@ -241,19 +241,20 @@ def path_computation(origin, destination, graph, results):
original_b_nodes_view)

if a_star_bint:
w = path_finding_a_star(origin_index,
dest_index,
g_view,
b_nodes_view,
graph_fs_view,
nodes_to_indices_view,
lat_view,
lon_view,
predecessors_view,
ids_graph_view,
conn_view,
reached_first_view,
heuristic)
path_finding_a_star(
origin_index,
dest_index,
g_view,
b_nodes_view,
graph_fs_view,
nodes_to_indices_view,
lat_view,
lon_view,
predecessors_view,
ids_graph_view,
conn_view,
heuristic
)
else:
w = path_finding(origin_index,
dest_index if early_exit_bint else -1,
Expand All @@ -266,7 +267,7 @@ def path_computation(origin, destination, graph, results):
reached_first_view)


if skims > 0:
if skims > 0 and not a_star_bint:
skim_single_path(origin_index,
nodes,
skims,
Expand Down
10 changes: 2 additions & 8 deletions aequilibrae/paths/basic_path_finding.pyx
Original file line number Diff line number Diff line change
Expand Up @@ -224,7 +224,7 @@ cdef void skim_single_path(long origin,

# Zeroes the intrazonal cost
for j in range(skims):
node_skims[origin, j] = 0
node_skims[origin, j] = 0

# Cascade skimming
for i in range(1, found + 1):
Expand Down Expand Up @@ -420,7 +420,7 @@ cdef inline double equirectangular_heuristic(double lat1, double lon1, double la
@cython.wraparound(False)
@cython.embedsignature(True)
@cython.boundscheck(False)
cpdef int path_finding_a_star(long origin,
cpdef void path_finding_a_star(long origin,
long destination,
double[:] graph_costs,
long long [:] csr_indices,
Expand All @@ -431,7 +431,6 @@ cpdef int path_finding_a_star(long origin,
long long [:] pred,
long long [:] ids,
long long [:] connectors,
long long [:] reached_first,
Heuristic heuristic) noexcept nogil:
"""
Based on the pseudocode presented at https://en.wikipedia.org/wiki/A*_search_algorithm#Pseudocode
Expand All @@ -451,7 +450,6 @@ cpdef int path_finding_a_star(long origin,
ElementState vert_state # vertex state
size_t origin_vert = <size_t>origin
size_t destination_vert = <size_t>destination if destination != -1 else 0
ITYPE_t found = 0
double *gScore = <double *>malloc(M * sizeof(double))

cdef:
Expand All @@ -473,7 +471,6 @@ cpdef int path_finding_a_star(long origin,
for i in range(M):
pred[i] = -1
connectors[i] = -1
reached_first[i] = -1
gScore[i] = INFINITY

# initialization of the heap elements
Expand All @@ -488,8 +485,6 @@ cpdef int path_finding_a_star(long origin,
# main loop
while pqueue.size > 0:
current = extract_min(&pqueue)
reached_first[found] = current
found += 1

if current == destination_vert:
break
Expand All @@ -515,4 +510,3 @@ cpdef int path_finding_a_star(long origin,

free_heap(&pqueue)
free(gScore)
return found - 1
Loading