-
Notifications
You must be signed in to change notification settings - Fork 1
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 #52 from CovertLab/name_change
Rename arrow module to stochastic_arrow
- Loading branch information
Showing
28 changed files
with
192 additions
and
58 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,83 @@ | ||
# Modified from GitHub Actions template | ||
|
||
name: Pytest | ||
|
||
on: | ||
push: | ||
branches: [master] | ||
pull_request: | ||
branches: [master] | ||
|
||
jobs: | ||
test-on-ubuntu: | ||
runs-on: ubuntu-latest | ||
strategy: | ||
matrix: | ||
python-version: ['3.9', '3.10', '3.11'] | ||
steps: | ||
- uses: actions/checkout@v3 | ||
- name: Setup Python ${{ matrix.python-version }} | ||
uses: actions/setup-python@v4 | ||
with: | ||
python-version: ${{ matrix.python-version }} | ||
cache: 'pip' | ||
- name: Install dependencies | ||
run: | | ||
python -m pip install --upgrade pip | ||
pip install pytest | ||
pip install numpy | ||
pip install -r requirements.txt | ||
- name: Compile Cython | ||
run: | | ||
make clean compile | ||
- name: Test with pytest | ||
run: | | ||
pytest | ||
test-on-windows: | ||
runs-on: windows-latest | ||
strategy: | ||
matrix: | ||
python-version: ['3.9', '3.10', '3.11'] | ||
steps: | ||
- uses: actions/checkout@v3 | ||
- name: Setup Python ${{ matrix.python-version }} | ||
uses: actions/setup-python@v4 | ||
with: | ||
python-version: ${{ matrix.python-version }} | ||
cache: 'pip' | ||
- name: Install dependencies | ||
run: | | ||
python -m pip install --upgrade pip | ||
pip install pytest | ||
pip install numpy | ||
pip install -r requirements.txt | ||
- name: Compile Cython | ||
run: | | ||
make clean compile | ||
- name: Test with pytest | ||
run: | | ||
pytest | ||
test-on-mac: | ||
runs-on: macos-latest | ||
strategy: | ||
matrix: | ||
python-version: ['3.9', '3.10', '3.11'] | ||
steps: | ||
- uses: actions/checkout@v3 | ||
- name: Setup Python ${{ matrix.python-version }} | ||
uses: actions/setup-python@v4 | ||
with: | ||
python-version: ${{ matrix.python-version }} | ||
cache: 'pip' | ||
- name: Install dependencies | ||
run: | | ||
python -m pip install --upgrade pip | ||
pip install pytest | ||
pip install numpy | ||
pip install -r requirements.txt | ||
- name: Compile Cython | ||
run: | | ||
make clean compile | ||
- name: Test with pytest | ||
run: | | ||
pytest |
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 |
---|---|---|
@@ -1,2 +1,2 @@ | ||
include arrow/obsidian.h | ||
include arrow/mersenne.h | ||
include stochastic_arrow/obsidian.h | ||
include stochastic_arrow/mersenne.h |
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 |
---|---|---|
|
@@ -13,11 +13,11 @@ | |
_ = setuptools | ||
|
||
|
||
with open("README.md", 'r') as readme: | ||
with open("README.md", 'r', encoding="utf-8") as readme: | ||
long_description = readme.read() | ||
|
||
current_dir = os.getcwd() | ||
arrow_dir = os.path.join(current_dir, 'arrow') | ||
arrow_dir = os.path.join(current_dir, 'stochastic_arrow') | ||
|
||
# Compile the Cython code to C for development builds: | ||
# USE_CYTHON=1 python setup.py build_ext --inplace | ||
|
@@ -30,25 +30,28 @@ | |
ext = '.pyx' if USE_CYTHON else '.c' | ||
|
||
cython_extensions = [ | ||
Extension('arrow.arrowhead', | ||
sources=['arrow/mersenne.c', 'arrow/obsidian.c', 'arrow/arrowhead'+ext,], | ||
include_dirs=['arrow', np.get_include()], | ||
Extension('stochastic_arrow.arrowhead', | ||
sources=[ | ||
'stochastic_arrow/mersenne.c', | ||
'stochastic_arrow/obsidian.c', | ||
'stochastic_arrow/arrowhead'+ext,], | ||
include_dirs=['stochastic_arrow', np.get_include()], | ||
define_macros=[('NPY_NO_DEPRECATED_API', 'NPY_1_7_API_VERSION')], | ||
)] | ||
|
||
if USE_CYTHON: | ||
from Cython.Build import cythonize | ||
cython_extensions = cythonize( | ||
cython_extensions, | ||
include_path=['arrow'], | ||
include_path=['stochastic_arrow'], | ||
annotate=True, # to get an HTML code listing | ||
) | ||
|
||
setup( | ||
name='stochastic-arrow', | ||
version='0.5.2', | ||
packages=['arrow'], | ||
author='Ryan Spangler, John Mason, Jerry Morrison, Chris Skalnik, Travis Ahn-Horst', | ||
version='1.0.0', | ||
packages=['stochastic_arrow'], | ||
author='Ryan Spangler, John Mason, Jerry Morrison, Chris Skalnik, Travis Ahn-Horst, Sean Cheah', | ||
author_email='[email protected]', | ||
url='https://github.com/CovertLab/arrow', | ||
license='MIT', | ||
|
File renamed without changes.
File renamed without changes.
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
File renamed without changes.
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 |
---|---|---|
@@ -1,4 +1,4 @@ | ||
# cython: language_level=3str | ||
|
||
# This file works around a Cython 3.0.0a1+ error on arrowhead.pyx: | ||
# arrow/arrowhead.pyx:14:0: 'arrow.pxd' not found | ||
# stochastic_arrow/arrowhead.pyx:14:0: 'arrow.pxd' not found |
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
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
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
File renamed without changes.
File renamed without changes.
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
File renamed without changes.
File renamed without changes.
2 changes: 1 addition & 1 deletion
2
arrow/test/negative_counts.py → stochastic_arrow/test/negative_counts.py
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 |
---|---|---|
@@ -1,6 +1,6 @@ | ||
import json | ||
|
||
from arrow import StochasticSystem | ||
from stochastic_arrow import StochasticSystem | ||
import numpy as np | ||
|
||
|
||
|
File renamed without changes.
File renamed without changes.
Oops, something went wrong.