-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #1 from cropsinsilico/add_tests
Add tests & CI
- Loading branch information
Showing
22 changed files
with
712 additions
and
94 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,28 @@ | ||
* text=auto | ||
|
||
*.fig binary | ||
*.mat binary | ||
*.mdl binary diff merge=mlAutoMerge | ||
*.mdlp binary | ||
*.mex* binary | ||
*.mlapp binary | ||
*.mldatx binary | ||
*.mlproj binary | ||
*.mlx binary | ||
*.p binary | ||
*.sfx binary | ||
*.sldd binary | ||
*.slreqx binary merge=mlAutoMerge | ||
*.slmx binary merge=mlAutoMerge | ||
*.sltx binary | ||
*.slxc binary | ||
*.slx binary merge=mlAutoMerge | ||
*.slxp binary | ||
|
||
## Other common binary file types | ||
*.docx binary | ||
*.exe binary | ||
*.jpg binary | ||
*.pdf binary | ||
*.png binary | ||
*.xlsx binary |
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,30 @@ | ||
name: Verify that MATLAB & C++ versions return the same answers | ||
'on': | ||
push: | ||
branches-ignore: | ||
- gh-pages | ||
tags: | ||
- '*' | ||
schedule: | ||
- cron: 0 10 * * 1 | ||
jobs: | ||
build_cxx: | ||
runs-on: ubuntu-latest | ||
steps: | ||
- name: Check out repository code | ||
uses: actions/checkout@v4 | ||
with: | ||
submodules: true | ||
- name: Set up MATLAB | ||
uses: matlab-actions/setup-matlab@v2 | ||
# - name: Run tests command | ||
# uses: matlab-actions/run-command@v2 | ||
# with: | ||
# command: runtests('tests'); exit; | ||
# startup-options: -nodisplay -nosplash -nodesktop -nojvm -logfile matlab_log.txt | ||
# - name: Display MATLAB log | ||
# run: cat matlab_log.txt | ||
- name: Run tests | ||
uses: matlab-actions/run-tests@v2 | ||
with: | ||
select-by-folder: tests |
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,2 @@ | ||
*~ | ||
*.asv |
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
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
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,48 @@ | ||
function InitRatios(ParaNum, Ratio) | ||
if ParaNum <= 0 | ||
return; | ||
end | ||
|
||
global PSRatio; | ||
PSRatio=ones(103,1); | ||
if ParaNum <= 103 | ||
PSRatio(ParaNum)=Ratio; | ||
end | ||
|
||
global SUCRatio; | ||
SUCRatio=ones(66,1); | ||
if ParaNum > 103&&ParaNum<=169 | ||
SUCRatio(ParaNum-103)=Ratio; | ||
end | ||
|
||
global PRRatio; | ||
PRRatio=ones(48,1); | ||
if ParaNum > 169&&ParaNum<=217 | ||
PRRatio(ParaNum-169)=Ratio; | ||
end | ||
|
||
global RacRatio; | ||
RacRatio=ones(16,1); | ||
if ParaNum > 217&&ParaNum<=233 | ||
RacRatio(ParaNum-217)=Ratio; | ||
end | ||
|
||
global FIRatio; | ||
FIRatio=ones(23,1); | ||
if ParaNum > 233&&ParaNum<=256 | ||
FIRatio(ParaNum-233)=Ratio; | ||
end | ||
|
||
global BFRatio; | ||
BFRatio=ones(49,1); | ||
if ParaNum > 256&&ParaNum<=305 | ||
BFRatio(ParaNum-256)=Ratio; | ||
end | ||
|
||
global XanRatio; | ||
XanRatio=ones(4,1); | ||
if ParaNum > 305&&ParaNum<=309 | ||
XanRatio(ParaNum-305)=Ratio; | ||
end | ||
|
||
end |
Oops, something went wrong.