inonoob / pirowflo

All-in-one data interface for your Waterrower S4 Monitor or Smartrow
GNU General Public License v3.0
141 stars 32 forks source link

Remove Numpy dependency #59

Open tpulatha opened 2 years ago

tpulatha commented 2 years ago

Is your feature request related to a problem? Please describe. Generally, I thought about this as I get a Segmentation fault error when trying to start waterrower.py. Looking into this it happens around

overrides.py(7): from numpy.core._multiarray_umath import (
 --- modulename: _bootstrap, funcname: _find_and_load

Describe the solution you'd like When I looked at Numpy usage I saw that it's only used once in src/adapters/s4/wrtobleant.py line 189 (self.AvgInstaPower = int(numpy.average(self._InstaPowerStroke))), to calculate an average. Is it really required to use such a heavy library to calculate an average once?

Describe alternatives you've considered Keeping numpy in and having lot of dependencies ;)

tpulatha commented 2 years ago

Opened a pull request for the required changes https://github.com/inonoob/pirowflo/pull/60