SunPower / PVMismatch

An explicit Python PV system IV & PV curve trace calculator which can also calculate mismatch.
http://sunpower.github.io/PVMismatch/
BSD 3-Clause "New" or "Revised" License
79 stars 30 forks source link

ENH: PERF: calculate multiple calls simultaneously instead of looping #86

Open mikofski opened 6 years ago

mikofski commented 6 years ago

Problem: currently cells are calculated one at a time, lazily as needed. This works fine if only a few cells, but if a large array has a very large number of different cells then it is inefficient and slow

Proposal: turn off cell calculations by setting __calc_now__=False and wait until all the cell parameters are entered, then use numpy array broadcasting to calculate all the cells at the same time. If necessary, also try either numexpr, Cython, Numba, or Pythran to leverage SIMD and CPU cache.