Skip to content

Commit

Permalink
Merge branch 'fathon-dev'
Browse files Browse the repository at this point in the history
  • Loading branch information
stfbnc committed Jan 10, 2021
2 parents f0408fc + d85db8f commit 99fb113
Show file tree
Hide file tree
Showing 60 changed files with 675 additions and 581 deletions.
56 changes: 56 additions & 0 deletions .appveyor.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,56 @@
branches:
only:
- master

environment:
global:
PYTHON: "C:\\Python37-x64"
PYTHON_VERSION: "3.7.x"
PYTHON_ARCH: "64"
CIBW_BUILD_VERBOSITY: 1
CIBW_TEST_REQUIRES: pytest
CIBW_TEST_COMMAND: "pytest %APPVEYOR_BUILD_FOLDER%\\tests"
CIBW_BEFORE_BUILD: "python -m pip install -r requirements.txt"

matrix:
- CIBW_BUILD: "cp35-win_amd64"
- CIBW_BUILD: "cp36-win_amd64"
- CIBW_BUILD: "cp37-win_amd64"
- CIBW_BUILD: "cp38-win_amd64"
- CIBW_BUILD: "cp39-win_amd64"

stack: python 3.7

init:
- cmd: PATH=%PYTHON%;%PYTHON%\Scripts;%PATH%

install:
### GSL ###
- cd C:\Tools\vcpkg
- git pull
- .\bootstrap-vcpkg.bat
- .\vcpkg integrate install
- .\vcpkg.exe install gsl:x64-windows-static
- md %APPVEYOR_BUILD_FOLDER%\fathon\3rd_party\gsl\include
- xcopy C:\Tools\vcpkg\packages\gsl_x64-windows-static\include %APPVEYOR_BUILD_FOLDER%\fathon\3rd_party\gsl\include /f /s /e
- md %APPVEYOR_BUILD_FOLDER%\fathon\3rd_party\gsl\lib
- xcopy C:\Tools\vcpkg\packages\gsl_x64-windows-static\lib %APPVEYOR_BUILD_FOLDER%\fathon\3rd_party\gsl\lib /f /s /e
### PYTHON ###
- "python -m pip install --upgrade pip"
- "python -m pip install --upgrade cibuildwheel"
- "python -m pip install --upgrade twine"

build_script:
- cd %APPVEYOR_BUILD_FOLDER%
- "python --version"
- "python -c \"import struct; print(struct.calcsize('P') * 8)\""
- "python -m pip --version"
- "python -m twine --version"
- "python -m cibuildwheel --output-dir wheelhouse"
- dir wheelhouse
- ps: >-
if ($env:PYPI_UPLOAD -eq "test") {
python -m twine upload --skip-existing wheelhouse\* --repository-url https://test.pypi.org/legacy/ -u $env:TEST_PYPI_USR -p $env:TEST_PYPI_PWD
} elseif ($env:PYPI_UPLOAD -eq "release") {
python -m twine upload --skip-existing wheelhouse\* -u $env:PYPI_USR -p $env:PYPI_PWD
}
205 changes: 170 additions & 35 deletions .travis.yml
Original file line number Diff line number Diff line change
Expand Up @@ -11,20 +11,70 @@ env:

matrix:
include:
# ===== Linux ======
#- name: "Python 3.7 on Linux"
# env:
# - CIBW_BUILD="cp35-manylinux* cp36-manylinux* cp37-manylinux* cp38-manylinux*"
# - CIBW_SKIP: "*-manylinux_i686"
# language: python
# dist: xenial
# sudo: required
# python: "3.7"
# services:
# - docker
# ===== Linux ======
- name: "Python 3.7 on Linux"
##### Linux #####
##### ARM #####
### 3.5 ###
- name: "Python 3.5 on Linux arm64"
arch:
- arm64
env:
- CIBW_MANYLINUX_AARCH64_IMAGE: manylinux2014
- CIBW_BUILD="cp35-manylinux*"
- CIBW_SKIP: "*-manylinux_i686"
language: python
dist: xenial
sudo: required
python: "3.7"
services:
- docker
### 3.6 ###
- name: "Python 3.6 on Linux arm64"
arch:
- arm64
env:
- CIBW_MANYLINUX_AARCH64_IMAGE: manylinux2014
- CIBW_BUILD="cp36-manylinux*"
- CIBW_SKIP: "*-manylinux_i686"
language: python
dist: xenial
sudo: required
python: "3.7"
services:
- docker
### 3.7 ###
- name: "Python 3.7 on Linux arm64"
arch:
- arm64
env:
- CIBW_MANYLINUX_AARCH64_IMAGE: manylinux2014
- CIBW_BUILD="cp37-manylinux*"
- CIBW_SKIP: "*-manylinux_i686"
language: python
dist: xenial
sudo: required
python: "3.7"
services:
- docker
### 3.8 ###
- name: "Python 3.8 on Linux arm64"
arch:
- arm64
env:
- CIBW_MANYLINUX_AARCH64_IMAGE: manylinux2014
- CIBW_BUILD="cp38-manylinux*"
- CIBW_SKIP: "*-manylinux_i686"
language: python
dist: xenial
sudo: required
python: "3.7"
services:
- docker
### 3.9 ###
- name: "Python 3.9 on Linux arm64"
arch:
- arm64
env:
- CIBW_MANYLINUX_AARCH64_IMAGE: manylinux2014
- CIBW_BUILD="cp39-manylinux*"
- CIBW_SKIP: "*-manylinux_i686"
language: python
Expand All @@ -33,27 +83,108 @@ matrix:
python: "3.7"
services:
- docker
# ======= macOS ========
#- name: "Python 3.7 on macOS 10.14 (1)"
# env:
# - CIBW_BUILD="cp35-macosx* cp36-macosx*"
# os: osx
# osx_image: xcode10.2
# language: shell
# ======= macOS ========
#- name: "Python 3.7 on macOS 10.14 (2)"
# env:
# - CIBW_BUILD="cp37-macosx* cp38-macosx*"
# os: osx
# osx_image: xcode10.2
# language: shell
# ======= macOS ========
#- name: "Python 3.7 on macOS 10.14 (3)"
# env:
# - CIBW_BUILD="cp39-macosx*"
# os: osx
# osx_image: xcode10.2
# language: shell
##### x86_64 #####
### 3.5 ###
- name: "Python 3.5 on Linux amd64"
arch:
- amd64
env:
- CIBW_BUILD="cp35-manylinux*"
- CIBW_SKIP: "*-manylinux_i686"
language: python
dist: xenial
sudo: required
python: "3.7"
services:
- docker
### 3.6 ###
- name: "Python 3.6 on Linux amd64"
arch:
- amd64
env:
- CIBW_BUILD="cp36-manylinux*"
- CIBW_SKIP: "*-manylinux_i686"
language: python
dist: xenial
sudo: required
python: "3.7"
services:
- docker
### 3.7 ###
- name: "Python 3.7 on Linux amd64"
arch:
- amd64
env:
- CIBW_BUILD="cp37-manylinux*"
- CIBW_SKIP: "*-manylinux_i686"
language: python
dist: xenial
sudo: required
python: "3.7"
services:
- docker
### 3.8 ###
- name: "Python 3.8 on Linux amd64"
arch:
- amd64
env:
- CIBW_BUILD="cp38-manylinux*"
- CIBW_SKIP: "*-manylinux_i686"
language: python
dist: xenial
sudo: required
python: "3.7"
services:
- docker
### 3.9 ###
- name: "Python 3.9 on Linux amd64"
arch:
- amd64
env:
- CIBW_BUILD="cp39-manylinux*"
- CIBW_SKIP: "*-manylinux_i686"
language: python
dist: xenial
sudo: required
python: "3.7"
services:
- docker
##### macOS #####
### 3.5 ###
- name: "Python 3.5 on macOS 10.14"
env:
- CIBW_BUILD="cp35-macosx*"
os: osx
osx_image: xcode10.2
language: shell
### 3.6 ###
- name: "Python 3.6 on macOS 10.14"
env:
- CIBW_BUILD="cp36-macosx*"
os: osx
osx_image: xcode10.2
language: shell
### 3.7 ###
- name: "Python 3.7 on macOS 10.14"
env:
- CIBW_BUILD="cp37-macosx*"
os: osx
osx_image: xcode10.2
language: shell
### 3.8 ###
- name: "Python 3.8 on macOS 10.14"
env:
- CIBW_BUILD="cp38-macosx*"
os: osx
osx_image: xcode10.2
language: shell
### 3.9 ###
- name: "Python 3.9 on macOS 10.14"
env:
- CIBW_BUILD="cp39-macosx*"
os: osx
osx_image: xcode10.2
language: shell

before_install:
- python3 --version
Expand All @@ -70,4 +201,8 @@ script:
elif [ "$TRAVIS_OS_NAME" = "osx" ]; then
pip install twine;
fi
- twine upload --skip-existing wheelhouse/* -u ${PYPI_USR} -p ${PYPI_PWD}
- if [ "$PYPI_UPLOAD" = "test" ]; then
twine upload --skip-existing wheelhouse/* --repository-url https://test.pypi.org/legacy/ -u ${TEST_PYPI_USR} -p ${TEST_PYPI_PWD};
elif [ "$PYPI_UPLOAD" = "release" ]; then
twine upload --skip-existing wheelhouse/* -u ${PYPI_USR} -p ${PYPI_PWD};
fi
17 changes: 12 additions & 5 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,13 +1,11 @@
# fathon [![Build Status](https://travis-ci.org/stfbnc/fathon.svg?branch=master)](https://travis-ci.org/stfbnc/fathon)
# fathon [![Build Status](https://travis-ci.org/stfbnc/fathon.svg?branch=master)](https://travis-ci.org/stfbnc/fathon)[![Build status](https://ci.appveyor.com/api/projects/status/tl2a8c84bbvxu37p?svg=true)](https://ci.appveyor.com/project/stfbnc/fathon)

[![Issues](https://img.shields.io/github/issues-raw/stfbnc/fathon.svg?maxAge=25000)](https://github.com/stfbnc/fathon/issues) [![GitHub stars](https://img.shields.io/github/stars/stfbnc/fathon.svg?style=social&label=Stars&style=plastic)]() [![GitHub forks](https://img.shields.io/github/forks/stfbnc/fathon.svg?style=social&label=Fork&style=plastic)]() [![Python 3.5+](https://img.shields.io/badge/python-3.5+-blue.svg)](https://www.python.org/)

[![DOI](https://zenodo.org/badge/214290119.svg)](https://zenodo.org/badge/latestdoi/214290119) [![DOI](https://joss.theoj.org/papers/10.21105/joss.01828/status.svg)](https://doi.org/10.21105/joss.01828)



:warning::warning: At the moment, `fathon` is only available for Linux (64 bit) and macOS :warning::warning:

`fathon` is a python package for DFA (*Detrended Fluctuation Analysis*) and related algorithms.

It is mostly written in Cython and C in order to speed up computations.
Expand All @@ -27,8 +25,13 @@ It is mostly written in Cython and C in order to speed up computations.

### Prerequisites

- Python 3.5 or higher
| Linux i686 | Linux x86_64 | Linux ARM64 | macOS x86_64 | Windows 32bit | Windows 64bit |
| :--------: | :----------------: | :----------------: | :----------------: | :-----------: | :-----------------: |
| :x: | :white_check_mark: | :white_check_mark: | :white_check_mark: | :x: | :white_check_mark:* |

<sub>*It is possible that OpenMP was not activated during compilation, so `fathon` could run slower on Windows compared to macOS and Linux</sub>

- Python 3.5 or higher
- numpy (version >= 1.15)
- Cython

Expand Down Expand Up @@ -60,10 +63,14 @@ Bianchi, S., (2020). fathon: A Python package for a fast computation of detrend

## Version [![PyPI version](https://badge.fury.io/py/fathon.svg)](https://badge.fury.io/py/fathon)

fathon v1.1
fathon v1.2

## Changelog

#### v1.2

- few adjustments to C extensions for Windows' C compiler compatibility

#### v1.1

- save object state to binary file and reload it later
Expand Down
2 changes: 1 addition & 1 deletion docs/Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
# You can set these variables from the command line, and also
# from the environment for the first two.
SPHINXOPTS ?=
SPHINXBUILD ?= "$(HOME)/.local/bin/sphinx-build"
SPHINXBUILD ?= "/anaconda3/bin/sphinx-build"
SOURCEDIR = .
BUILDDIR = _build

Expand Down
Binary file modified docs/_build/doctrees/environment.pickle
Binary file not shown.
Binary file modified docs/_build/doctrees/fun_class/fathon.DCCA.doctree
Binary file not shown.
Binary file modified docs/_build/doctrees/fun_class/fathon.DFA.doctree
Binary file not shown.
Binary file modified docs/_build/doctrees/fun_class/fathon.HT.doctree
Binary file not shown.
Binary file modified docs/_build/doctrees/fun_class/fathon.MFDFA.doctree
Binary file not shown.
Binary file modified docs/_build/doctrees/fun_class/fathon.fathonUtils.doctree
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file modified docs/_build/doctrees/index.doctree
Binary file not shown.
2 changes: 1 addition & 1 deletion docs/_build/html/.buildinfo
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
# Sphinx build info version 1
# This file hashes the configuration used when building these files. When it is not found, a full rebuild will be done.
config: bf8bc797bceb48fe5abc3d1b252c1993
config: 3f3a3a407d4e9d370d01da6a59f49d6a
tags: 645f666f9bcd5a90fca523b33c5a78b7
2 changes: 1 addition & 1 deletion docs/_build/html/_sources/fun_class/fathon.DCCA.rst.txt
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,7 @@ Usage examples
#initialize non-empty dcca object
pydcca = fathon.DCCA(a, b)
#compute fluctuation function and Hurst exponent
wins = fu.linRangeByStep(20, 100, step=50)
wins = fu.linRangeByStep(20, 1000, step=50)
n, F = pydcca.computeFlucVec(wins, polOrd=1)
H, H_intercept = pydcca.fitFlucVec()
Expand Down
4 changes: 2 additions & 2 deletions docs/_build/html/_sources/index.rst.txt
Original file line number Diff line number Diff line change
Expand Up @@ -3,10 +3,10 @@
You can adapt this file completely to your liking, but it should at least
contain the root `toctree` directive.
fathon (v1.1)
fathon (v1.2)
***************

Current version is available for Linux (64 bit) and macOS only.
Current version is available for Linux (x86_64 and ARM64), macOS, and Windows (64bit).

Python package for detrended fluctuation analysis (DFA) and related algorithms.
`fathon` provides four main algorithms, namely
Expand Down
Loading

0 comments on commit 99fb113

Please sign in to comment.