-
Notifications
You must be signed in to change notification settings - Fork 33
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge branch 'master' into dependabot/pip/numpy-gte-1.22.2-and-lt-2.2.0
- Loading branch information
Showing
21 changed files
with
1,331 additions
and
193 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -10,7 +10,7 @@ jobs: | |
fetch-depth: 0 # otherwise, you will fail to push refs to dest repo | ||
- uses: actions/setup-python@v5 | ||
with: | ||
python-version: '3.9' | ||
python-version: '3.10' | ||
cache: 'pip' | ||
- name: Build and Commit | ||
uses: waltsims/[email protected] | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,44 @@ | ||
# Define the Python interpreter and MATLAB command | ||
PYTHON = python | ||
MATLAB = matlab | ||
|
||
# Define the directories and files | ||
EXAMPLES_DIR = examples | ||
TESTS_DIR = tests | ||
MATLAB_SCRIPT = tests/matlab_test_data_collectors/run_all_collectors.m | ||
KWAVE_MATLAB_PATH = $(abspath ../k-wave) # Get absolute path of k-wave directory | ||
|
||
# Define the artifact directory | ||
COLLECTED_VALUES_DIR = $(abspath tests/matlab_test_data_collectors/python_testers/collectedValues) | ||
|
||
# Default target | ||
all: run-examples test | ||
|
||
# Target to run all examples | ||
run-examples: | ||
@echo "Running all examples..." | ||
@MPLBACKEND=Agg $(PYTHON) run_examples.py | ||
|
||
# Target to run pytest, which depends on running the MATLAB script first | ||
test: $(COLLECTED_VALUES_DIR) | ||
@echo "Running pytest..." | ||
@pytest $(TESTS_DIR) | ||
|
||
# Target to run the MATLAB script and create the artifact directory | ||
$(COLLECTED_VALUES_DIR): | ||
@echo "Running MATLAB script to collect values..."; \ | ||
$(MATLAB) -batch "run('$(MATLAB_SCRIPT)');"; \ | ||
# Clean target (optional) - cleans Python caches and collected values | ||
clean: clean-python clean-collected_values | ||
|
||
clean-python: | ||
@echo "Cleaning Python cache files..." | ||
@find . -name '*.pyc' -delete | ||
@find . -name '__pycache__' -delete | ||
|
||
# Clean collected values directory | ||
clean-collected_values: | ||
@echo "Cleaning collected values directory..." | ||
@rm -rf $(COLLECTED_VALUES_DIR) | ||
|
||
.PHONY: all run-examples run-tests clean-python clean-collected_values clean |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,7 @@ | ||
# Modelling Sensor Directivity In 2D Example | ||
|
||
[![Open In Colab](https://colab.research.google.com/assets/colab-badge.svg)](https://colab.research.google.com/github/waltsims/k-wave-python/blob/master/examples/sd_directivity_modelling_2D/sd_directivity_modelling_2D.ipynb) | ||
|
||
This example demonstrates how the sensitivity of a large single element detector varies with the angular position of a point-like source. | ||
|
||
To read more, visit the [original example page](http://www.k-wave.org/documentation/example_sd_directivity_modelling_2D.php). |
Oops, something went wrong.