diff --git a/piker/fsp/__init__.py b/piker/fsp/__init__.py index c798bf28..67f92350 100644 --- a/piker/fsp/__init__.py +++ b/piker/fsp/__init__.py @@ -1,5 +1,5 @@ # piker: trading gear for hackers -# Copyright (C) 2018-present Tyler Goodlet (in stewardship of piker0) +# Copyright (C) Tyler Goodlet (in stewardship for piker0) # This program is free software: you can redistribute it and/or modify # it under the terms of the GNU Affero General Public License as published by diff --git a/piker/fsp/_momo.py b/piker/fsp/_momo.py index f8811afa..b2dabe87 100644 --- a/piker/fsp/_momo.py +++ b/piker/fsp/_momo.py @@ -20,7 +20,7 @@ Momentum bby. from typing import AsyncIterator, Optional import numpy as np -from numba import jit, float64, optional, int64 +from numba import njit, float64, optional, int64 from ..data._normalize import iterticks @@ -29,13 +29,12 @@ from ..data._normalize import iterticks # - how to handle non-plottable values # - composition of fsps / implicit chaining -@jit( +@njit( float64[:]( float64[:], optional(float64), optional(float64) ), - nopython=True, nogil=True ) def ema( @@ -94,7 +93,7 @@ def ema( return s -# @jit( +# @njit( # float64[:]( # float64[:], # int64, diff --git a/piker/fsp/_volume.py b/piker/fsp/_volume.py index 30397920..a14acbe6 100644 --- a/piker/fsp/_volume.py +++ b/piker/fsp/_volume.py @@ -1,5 +1,5 @@ # piker: trading gear for hackers -# Copyright (C) 2018-present Tyler Goodlet (in stewardship of piker0) +# Copyright (C) Tyler Goodlet (in stewardship for piker0) # This program is free software: you can redistribute it and/or modify # it under the terms of the GNU Affero General Public License as published by diff --git a/piker/ui/_graphics/_ohlc.py b/piker/ui/_graphics/_ohlc.py index 0be7853f..d75e40fe 100644 --- a/piker/ui/_graphics/_ohlc.py +++ b/piker/ui/_graphics/_ohlc.py @@ -21,7 +21,7 @@ from typing import List, Optional, Tuple import numpy as np import pyqtgraph as pg -from numba import jit, float64, int64 # , optional +from numba import njit, float64, int64 # , optional from PyQt5 import QtCore, QtGui, QtWidgets from PyQt5.QtCore import QLineF, QPointF # from numba import types as ntypes @@ -70,7 +70,7 @@ def lines_from_ohlc(row: np.ndarray, w: float) -> Tuple[QLineF]: return [hl, o, c] -@jit( +@njit( # TODO: for now need to construct this manually for readonly arrays, see # https://github.com/numba/numba/issues/4511 # ntypes.Tuple((float64[:], float64[:], float64[:]))( @@ -78,7 +78,6 @@ def lines_from_ohlc(row: np.ndarray, w: float) -> Tuple[QLineF]: # int64, # optional(float64), # ), - nopython=True, nogil=True ) def path_arrays_from_ohlc(