ANNarchy 5.0.2__tar.gz → 5.0.3__tar.gz
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- {annarchy-5.0.2 → annarchy-5.0.3}/ANNarchy/__init__.py +2 -1
- {annarchy-5.0.2 → annarchy-5.0.3}/ANNarchy/core/Attributes.py +3 -5
- annarchy-5.0.3/ANNarchy/core/CTypes.py +74 -0
- {annarchy-5.0.2 → annarchy-5.0.3}/ANNarchy/core/ConnectorMethods.py +6 -1
- {annarchy-5.0.2 → annarchy-5.0.3}/ANNarchy/core/Monitor.py +4 -4
- {annarchy-5.0.2 → annarchy-5.0.3}/ANNarchy/core/Network.py +10 -1
- {annarchy-5.0.2 → annarchy-5.0.3}/ANNarchy/core/Population.py +13 -22
- {annarchy-5.0.2 → annarchy-5.0.3}/ANNarchy/core/Projection.py +2 -2
- {annarchy-5.0.2 → annarchy-5.0.3}/ANNarchy/extensions/bold/AccProjection.py +2 -2
- {annarchy-5.0.2 → annarchy-5.0.3}/ANNarchy/extensions/convolution/ConvolveTemplate.py +7 -7
- {annarchy-5.0.2 → annarchy-5.0.3}/ANNarchy/extensions/convolution/PoolingTemplate.py +2 -2
- {annarchy-5.0.2 → annarchy-5.0.3}/ANNarchy/extensions/image/ImagePopulation.py +2 -6
- {annarchy-5.0.2 → annarchy-5.0.3}/ANNarchy/generator/CmdLineArgParser.py +3 -0
- annarchy-5.0.3/ANNarchy/generator/CodeGenerator.py +291 -0
- {annarchy-5.0.2 → annarchy-5.0.3}/ANNarchy/generator/Compiler.py +129 -180
- {annarchy-5.0.2 → annarchy-5.0.3}/ANNarchy/generator/Monitor/CUDATemplates.py +11 -11
- {annarchy-5.0.2 → annarchy-5.0.3}/ANNarchy/generator/Monitor/OpenMPTemplates.py +3 -3
- {annarchy-5.0.2 → annarchy-5.0.3}/ANNarchy/generator/NanoBind/BaseTemplate.py +2 -2
- {annarchy-5.0.2 → annarchy-5.0.3}/ANNarchy/generator/NanoBind/Generator.py +16 -5
- {annarchy-5.0.2 → annarchy-5.0.3}/ANNarchy/generator/NanoBind/Population.py +29 -0
- {annarchy-5.0.2 → annarchy-5.0.3}/ANNarchy/generator/Population/CUDAGenerator.py +22 -16
- {annarchy-5.0.2 → annarchy-5.0.3}/ANNarchy/generator/Population/CUDATemplates.py +27 -27
- {annarchy-5.0.2 → annarchy-5.0.3}/ANNarchy/generator/Population/OpenMPGenerator.py +19 -13
- {annarchy-5.0.2 → annarchy-5.0.3}/ANNarchy/generator/Population/OpenMPTemplates.py +7 -7
- {annarchy-5.0.2 → annarchy-5.0.3}/ANNarchy/generator/Population/PopulationGenerator.py +25 -15
- {annarchy-5.0.2 → annarchy-5.0.3}/ANNarchy/generator/Population/SingleThreadGenerator.py +16 -10
- {annarchy-5.0.2 → annarchy-5.0.3}/ANNarchy/generator/Population/SingleThreadTemplates.py +4 -4
- {annarchy-5.0.2 → annarchy-5.0.3}/ANNarchy/generator/Profile/ProfileTemplate.py +2 -2
- {annarchy-5.0.2 → annarchy-5.0.3}/ANNarchy/generator/Projection/CUDA/BSR.py +16 -16
- {annarchy-5.0.2 → annarchy-5.0.3}/ANNarchy/generator/Projection/CUDA/BaseTemplates.py +8 -8
- {annarchy-5.0.2 → annarchy-5.0.3}/ANNarchy/generator/Projection/CUDA/COO.py +15 -15
- {annarchy-5.0.2 → annarchy-5.0.3}/ANNarchy/generator/Projection/CUDA/CSR.py +22 -22
- {annarchy-5.0.2 → annarchy-5.0.3}/ANNarchy/generator/Projection/CUDA/CSR_Scalar.py +15 -15
- {annarchy-5.0.2 → annarchy-5.0.3}/ANNarchy/generator/Projection/CUDA/CSR_T.py +18 -18
- {annarchy-5.0.2 → annarchy-5.0.3}/ANNarchy/generator/Projection/CUDA/CSR_Vector.py +15 -15
- {annarchy-5.0.2 → annarchy-5.0.3}/ANNarchy/generator/Projection/CUDA/Dense.py +22 -22
- {annarchy-5.0.2 → annarchy-5.0.3}/ANNarchy/generator/Projection/CUDA/Dense_T.py +18 -18
- {annarchy-5.0.2 → annarchy-5.0.3}/ANNarchy/generator/Projection/CUDA/ELL.py +15 -15
- {annarchy-5.0.2 → annarchy-5.0.3}/ANNarchy/generator/Projection/CUDA/ELLR.py +15 -15
- {annarchy-5.0.2 → annarchy-5.0.3}/ANNarchy/generator/Projection/CUDA/HYB.py +6 -6
- {annarchy-5.0.2 → annarchy-5.0.3}/ANNarchy/generator/Projection/CUDA/SELL.py +10 -10
- {annarchy-5.0.2 → annarchy-5.0.3}/ANNarchy/generator/Projection/CUDAGenerator.py +1 -0
- {annarchy-5.0.2 → annarchy-5.0.3}/ANNarchy/generator/Projection/OpenMP/BaseTemplates.py +7 -7
- {annarchy-5.0.2 → annarchy-5.0.3}/ANNarchy/generator/Projection/OpenMP/LIL_P.py +1 -1
- {annarchy-5.0.2 → annarchy-5.0.3}/ANNarchy/generator/Projection/OpenMPGenerator.py +4 -3
- {annarchy-5.0.2 → annarchy-5.0.3}/ANNarchy/generator/Projection/ProjectionGenerator.py +1 -1
- {annarchy-5.0.2 → annarchy-5.0.3}/ANNarchy/generator/Projection/SingleThread/BaseTemplates.py +7 -7
- {annarchy-5.0.2 → annarchy-5.0.3}/ANNarchy/generator/Projection/SingleThreadGenerator.py +1 -0
- annarchy-5.0.3/ANNarchy/generator/SimCore/CUDAGenerator.py +738 -0
- annarchy-5.0.3/ANNarchy/generator/SimCore/OpenMPGenerator.py +375 -0
- annarchy-5.0.3/ANNarchy/generator/SimCore/SimCoreGenerator.py +196 -0
- annarchy-5.0.3/ANNarchy/generator/SimCore/SingleThreadGenerator.py +378 -0
- annarchy-5.0.3/ANNarchy/generator/SimCore/__init__.py +3 -0
- annarchy-5.0.3/ANNarchy/generator/Template/CMakeTemplate.py +462 -0
- {annarchy-5.0.2 → annarchy-5.0.3}/ANNarchy/generator/Template/CUDABaseTemplate.py +11 -11
- {annarchy-5.0.2 → annarchy-5.0.3}/ANNarchy/generator/Template/GlobalOperationTemplate.py +1 -1
- {annarchy-5.0.2 → annarchy-5.0.3}/ANNarchy/generator/Template/OpenMPBaseTemplate.py +12 -12
- {annarchy-5.0.2 → annarchy-5.0.3}/ANNarchy/generator/Template/SingleThreadBaseTemplate.py +10 -10
- {annarchy-5.0.2 → annarchy-5.0.3}/ANNarchy/generator/Utils.py +64 -6
- {annarchy-5.0.2 → annarchy-5.0.3}/ANNarchy/include/BSRInvMatrix.hpp +6 -6
- {annarchy-5.0.2 → annarchy-5.0.3}/ANNarchy/include/BSRInvMatrixBitmask.hpp +6 -6
- {annarchy-5.0.2 → annarchy-5.0.3}/ANNarchy/include/BSRMatrix.hpp +13 -13
- {annarchy-5.0.2 → annarchy-5.0.3}/ANNarchy/include/BSRMatrixBitmask.hpp +12 -12
- {annarchy-5.0.2 → annarchy-5.0.3}/ANNarchy/include/BSRMatrixCUDA.hpp +5 -5
- {annarchy-5.0.2 → annarchy-5.0.3}/ANNarchy/include/COOMatrix.hpp +9 -9
- {annarchy-5.0.2 → annarchy-5.0.3}/ANNarchy/include/COOMatrixCUDA.hpp +6 -6
- {annarchy-5.0.2 → annarchy-5.0.3}/ANNarchy/include/CSRCMatrix.hpp +8 -8
- {annarchy-5.0.2 → annarchy-5.0.3}/ANNarchy/include/CSRCMatrixCUDA.hpp +6 -6
- {annarchy-5.0.2 → annarchy-5.0.3}/ANNarchy/include/CSRCMatrixCUDAT.hpp +6 -6
- {annarchy-5.0.2 → annarchy-5.0.3}/ANNarchy/include/CSRCMatrixT.hpp +5 -5
- {annarchy-5.0.2 → annarchy-5.0.3}/ANNarchy/include/CSRMatrix.hpp +11 -11
- {annarchy-5.0.2 → annarchy-5.0.3}/ANNarchy/include/CSRMatrixCUDA.hpp +10 -10
- {annarchy-5.0.2 → annarchy-5.0.3}/ANNarchy/include/DenseMatrix.hpp +17 -17
- {annarchy-5.0.2 → annarchy-5.0.3}/ANNarchy/include/DenseMatrixBitmask.hpp +7 -7
- {annarchy-5.0.2 → annarchy-5.0.3}/ANNarchy/include/DenseMatrixCUDA.hpp +9 -9
- {annarchy-5.0.2 → annarchy-5.0.3}/ANNarchy/include/DenseMatrixOffsets.hpp +3 -3
- {annarchy-5.0.2 → annarchy-5.0.3}/ANNarchy/include/DiaMatrix.hpp +8 -8
- {annarchy-5.0.2 → annarchy-5.0.3}/ANNarchy/include/ELLMatrix.hpp +10 -10
- {annarchy-5.0.2 → annarchy-5.0.3}/ANNarchy/include/ELLMatrixCUDA.hpp +10 -10
- {annarchy-5.0.2 → annarchy-5.0.3}/ANNarchy/include/ELLRMatrix.hpp +11 -11
- {annarchy-5.0.2 → annarchy-5.0.3}/ANNarchy/include/ELLRMatrixCUDA.hpp +9 -9
- {annarchy-5.0.2 → annarchy-5.0.3}/ANNarchy/include/HYBMatrix.hpp +15 -15
- {annarchy-5.0.2 → annarchy-5.0.3}/ANNarchy/include/HYBMatrixCUDA.hpp +4 -4
- {annarchy-5.0.2 → annarchy-5.0.3}/ANNarchy/include/LILInvMatrix.hpp +4 -4
- {annarchy-5.0.2 → annarchy-5.0.3}/ANNarchy/include/LILMatrix.hpp +7 -7
- {annarchy-5.0.2 → annarchy-5.0.3}/ANNarchy/include/PartitionedMatrix.hpp +6 -6
- {annarchy-5.0.2 → annarchy-5.0.3}/ANNarchy/include/SELLMatrix.hpp +6 -6
- {annarchy-5.0.2 → annarchy-5.0.3}/ANNarchy/include/SELLMatrixCUDA.hpp +10 -10
- {annarchy-5.0.2 → annarchy-5.0.3}/ANNarchy/include/VecTransformation.hpp +6 -6
- {annarchy-5.0.2 → annarchy-5.0.3}/ANNarchy/include/helper_functions.cuh +1 -1
- {annarchy-5.0.2 → annarchy-5.0.3}/ANNarchy/include/helper_functions.hpp +1 -1
- {annarchy-5.0.2 → annarchy-5.0.3}/ANNarchy/include/logging.hpp +8 -2
- {annarchy-5.0.2 → annarchy-5.0.3}/ANNarchy/inputs/SpikeTrains.py +21 -6
- {annarchy-5.0.2 → annarchy-5.0.3}/ANNarchy/inputs/TimedArray.py +60 -20
- {annarchy-5.0.2 → annarchy-5.0.3}/ANNarchy/inputs/TimedPoissonPopulation.py +12 -5
- {annarchy-5.0.2 → annarchy-5.0.3}/ANNarchy/intern/ConfigManagement.py +14 -12
- {annarchy-5.0.2 → annarchy-5.0.3}/ANNarchy/intern/NetworkManager.py +4 -4
- {annarchy-5.0.2 → annarchy-5.0.3}/ANNarchy.egg-info/PKG-INFO +2 -2
- {annarchy-5.0.2 → annarchy-5.0.3}/ANNarchy.egg-info/SOURCES.txt +6 -1
- {annarchy-5.0.2 → annarchy-5.0.3}/PKG-INFO +2 -2
- {annarchy-5.0.2 → annarchy-5.0.3}/README.md +1 -1
- {annarchy-5.0.2 → annarchy-5.0.3}/pyproject.toml +1 -1
- {annarchy-5.0.2 → annarchy-5.0.3}/setup.py +6 -5
- annarchy-5.0.2/ANNarchy/generator/CodeGenerator.py +0 -1263
- annarchy-5.0.2/ANNarchy/generator/Template/BaseTemplate.py +0 -1574
- annarchy-5.0.2/ANNarchy/generator/Template/CMakeTemplate.py +0 -278
- {annarchy-5.0.2 → annarchy-5.0.3}/ANNarchy/core/Constant.py +0 -0
- {annarchy-5.0.2 → annarchy-5.0.3}/ANNarchy/core/Dendrite.py +0 -0
- {annarchy-5.0.2 → annarchy-5.0.3}/ANNarchy/core/Global.py +0 -0
- {annarchy-5.0.2 → annarchy-5.0.3}/ANNarchy/core/IO.py +0 -0
- {annarchy-5.0.2 → annarchy-5.0.3}/ANNarchy/core/Neuron.py +0 -0
- {annarchy-5.0.2 → annarchy-5.0.3}/ANNarchy/core/PopulationView.py +0 -0
- {annarchy-5.0.2 → annarchy-5.0.3}/ANNarchy/core/Random.py +0 -0
- {annarchy-5.0.2 → annarchy-5.0.3}/ANNarchy/core/Simulate.py +0 -0
- {annarchy-5.0.2 → annarchy-5.0.3}/ANNarchy/core/Synapse.py +0 -0
- {annarchy-5.0.2 → annarchy-5.0.3}/ANNarchy/core/Utils.py +0 -0
- {annarchy-5.0.2 → annarchy-5.0.3}/ANNarchy/core/__init__.py +0 -0
- {annarchy-5.0.2 → annarchy-5.0.3}/ANNarchy/cython_ext/Connector.pxd +0 -0
- {annarchy-5.0.2 → annarchy-5.0.3}/ANNarchy/cython_ext/Connector.pyx +0 -0
- {annarchy-5.0.2 → annarchy-5.0.3}/ANNarchy/cython_ext/Coordinates.pxd +0 -0
- {annarchy-5.0.2 → annarchy-5.0.3}/ANNarchy/cython_ext/Coordinates.pyx +0 -0
- {annarchy-5.0.2 → annarchy-5.0.3}/ANNarchy/cython_ext/Transformations.pyx +0 -0
- {annarchy-5.0.2 → annarchy-5.0.3}/ANNarchy/cython_ext/__init__.pxd +0 -0
- {annarchy-5.0.2 → annarchy-5.0.3}/ANNarchy/cython_ext/__init__.py +0 -0
- {annarchy-5.0.2 → annarchy-5.0.3}/ANNarchy/extensions/__init__.py +0 -0
- {annarchy-5.0.2 → annarchy-5.0.3}/ANNarchy/extensions/ann_to_snn_conversion/ANNtoSNNConverter.py +0 -0
- {annarchy-5.0.2 → annarchy-5.0.3}/ANNarchy/extensions/ann_to_snn_conversion/InputEncoding.py +0 -0
- {annarchy-5.0.2 → annarchy-5.0.3}/ANNarchy/extensions/ann_to_snn_conversion/ReadOut.py +0 -0
- {annarchy-5.0.2 → annarchy-5.0.3}/ANNarchy/extensions/ann_to_snn_conversion/__init__.py +0 -0
- {annarchy-5.0.2 → annarchy-5.0.3}/ANNarchy/extensions/bold/BoldModel.py +0 -0
- {annarchy-5.0.2 → annarchy-5.0.3}/ANNarchy/extensions/bold/BoldMonitor.py +0 -0
- {annarchy-5.0.2 → annarchy-5.0.3}/ANNarchy/extensions/bold/NormProjection.py +0 -0
- {annarchy-5.0.2 → annarchy-5.0.3}/ANNarchy/extensions/bold/PredefinedModels.py +0 -0
- {annarchy-5.0.2 → annarchy-5.0.3}/ANNarchy/extensions/bold/__init__.py +0 -0
- {annarchy-5.0.2 → annarchy-5.0.3}/ANNarchy/extensions/convolution/Convolve.py +0 -0
- {annarchy-5.0.2 → annarchy-5.0.3}/ANNarchy/extensions/convolution/Copy.py +0 -0
- {annarchy-5.0.2 → annarchy-5.0.3}/ANNarchy/extensions/convolution/CopyTemplate.py +0 -0
- {annarchy-5.0.2 → annarchy-5.0.3}/ANNarchy/extensions/convolution/Pooling.py +0 -0
- {annarchy-5.0.2 → annarchy-5.0.3}/ANNarchy/extensions/convolution/Transpose.py +0 -0
- {annarchy-5.0.2 → annarchy-5.0.3}/ANNarchy/extensions/convolution/Utils.py +0 -0
- {annarchy-5.0.2 → annarchy-5.0.3}/ANNarchy/extensions/convolution/__init__.py +0 -0
- {annarchy-5.0.2 → annarchy-5.0.3}/ANNarchy/extensions/diagonal/DiagonalProjection.py +0 -0
- {annarchy-5.0.2 → annarchy-5.0.3}/ANNarchy/extensions/diagonal/__init__.py +0 -0
- {annarchy-5.0.2 → annarchy-5.0.3}/ANNarchy/extensions/hybrid/HybridPopulation.py +0 -0
- {annarchy-5.0.2 → annarchy-5.0.3}/ANNarchy/extensions/hybrid/__init__.py +0 -0
- {annarchy-5.0.2 → annarchy-5.0.3}/ANNarchy/extensions/image/__init__.py +0 -0
- {annarchy-5.0.2 → annarchy-5.0.3}/ANNarchy/extensions/tensorboard/Logger.py +0 -0
- {annarchy-5.0.2 → annarchy-5.0.3}/ANNarchy/extensions/tensorboard/__init__.py +0 -0
- {annarchy-5.0.2 → annarchy-5.0.3}/ANNarchy/generator/Monitor/BaseTemplates.py +0 -0
- {annarchy-5.0.2 → annarchy-5.0.3}/ANNarchy/generator/Monitor/MonitorGenerator.py +0 -0
- {annarchy-5.0.2 → annarchy-5.0.3}/ANNarchy/generator/NanoBind/Profiler.py +0 -0
- {annarchy-5.0.2 → annarchy-5.0.3}/ANNarchy/generator/NanoBind/Projection.py +0 -0
- {annarchy-5.0.2 → annarchy-5.0.3}/ANNarchy/generator/NanoBind/__init__.py +0 -0
- {annarchy-5.0.2 → annarchy-5.0.3}/ANNarchy/generator/Population/__init__.py +0 -0
- {annarchy-5.0.2 → annarchy-5.0.3}/ANNarchy/generator/Profile/CPP11Profile.py +0 -0
- {annarchy-5.0.2 → annarchy-5.0.3}/ANNarchy/generator/Profile/CUDAProfile.py +0 -0
- {annarchy-5.0.2 → annarchy-5.0.3}/ANNarchy/generator/Profile/ProfileGenerator.py +0 -0
- {annarchy-5.0.2 → annarchy-5.0.3}/ANNarchy/generator/Profile/__init__.py +0 -0
- {annarchy-5.0.2 → annarchy-5.0.3}/ANNarchy/generator/Projection/CUDA/__init__.py +0 -0
- {annarchy-5.0.2 → annarchy-5.0.3}/ANNarchy/generator/Projection/OpenMP/BSR.py +0 -0
- {annarchy-5.0.2 → annarchy-5.0.3}/ANNarchy/generator/Projection/OpenMP/COO.py +0 -0
- {annarchy-5.0.2 → annarchy-5.0.3}/ANNarchy/generator/Projection/OpenMP/CSR.py +0 -0
- {annarchy-5.0.2 → annarchy-5.0.3}/ANNarchy/generator/Projection/OpenMP/CSR_P.py +0 -0
- {annarchy-5.0.2 → annarchy-5.0.3}/ANNarchy/generator/Projection/OpenMP/CSR_T.py +0 -0
- {annarchy-5.0.2 → annarchy-5.0.3}/ANNarchy/generator/Projection/OpenMP/CSR_T_P.py +0 -0
- {annarchy-5.0.2 → annarchy-5.0.3}/ANNarchy/generator/Projection/OpenMP/DIA.py +0 -0
- {annarchy-5.0.2 → annarchy-5.0.3}/ANNarchy/generator/Projection/OpenMP/Dense.py +0 -0
- {annarchy-5.0.2 → annarchy-5.0.3}/ANNarchy/generator/Projection/OpenMP/Dense_T.py +0 -0
- {annarchy-5.0.2 → annarchy-5.0.3}/ANNarchy/generator/Projection/OpenMP/ELL.py +0 -0
- {annarchy-5.0.2 → annarchy-5.0.3}/ANNarchy/generator/Projection/OpenMP/ELLR.py +0 -0
- {annarchy-5.0.2 → annarchy-5.0.3}/ANNarchy/generator/Projection/OpenMP/LIL.py +0 -0
- {annarchy-5.0.2 → annarchy-5.0.3}/ANNarchy/generator/Projection/OpenMP/SELL.py +0 -0
- {annarchy-5.0.2 → annarchy-5.0.3}/ANNarchy/generator/Projection/OpenMP/__init__.py +0 -0
- {annarchy-5.0.2 → annarchy-5.0.3}/ANNarchy/generator/Projection/SingleThread/BSR.py +0 -0
- {annarchy-5.0.2 → annarchy-5.0.3}/ANNarchy/generator/Projection/SingleThread/COO.py +0 -0
- {annarchy-5.0.2 → annarchy-5.0.3}/ANNarchy/generator/Projection/SingleThread/CSR.py +0 -0
- {annarchy-5.0.2 → annarchy-5.0.3}/ANNarchy/generator/Projection/SingleThread/CSR_T.py +0 -0
- {annarchy-5.0.2 → annarchy-5.0.3}/ANNarchy/generator/Projection/SingleThread/DIA.py +0 -0
- {annarchy-5.0.2 → annarchy-5.0.3}/ANNarchy/generator/Projection/SingleThread/Dense.py +0 -0
- {annarchy-5.0.2 → annarchy-5.0.3}/ANNarchy/generator/Projection/SingleThread/Dense_PV.py +0 -0
- {annarchy-5.0.2 → annarchy-5.0.3}/ANNarchy/generator/Projection/SingleThread/Dense_PV_T.py +0 -0
- {annarchy-5.0.2 → annarchy-5.0.3}/ANNarchy/generator/Projection/SingleThread/Dense_T.py +0 -0
- {annarchy-5.0.2 → annarchy-5.0.3}/ANNarchy/generator/Projection/SingleThread/ELL.py +0 -0
- {annarchy-5.0.2 → annarchy-5.0.3}/ANNarchy/generator/Projection/SingleThread/ELLR.py +0 -0
- {annarchy-5.0.2 → annarchy-5.0.3}/ANNarchy/generator/Projection/SingleThread/HYB.py +0 -0
- {annarchy-5.0.2 → annarchy-5.0.3}/ANNarchy/generator/Projection/SingleThread/LIL.py +0 -0
- {annarchy-5.0.2 → annarchy-5.0.3}/ANNarchy/generator/Projection/SingleThread/SELL.py +0 -0
- {annarchy-5.0.2 → annarchy-5.0.3}/ANNarchy/generator/Projection/SingleThread/__init__.py +0 -0
- {annarchy-5.0.2 → annarchy-5.0.3}/ANNarchy/generator/Projection/__init__.py +0 -0
- {annarchy-5.0.2 → annarchy-5.0.3}/ANNarchy/generator/Sanity.py +0 -0
- {annarchy-5.0.2 → annarchy-5.0.3}/ANNarchy/generator/Template/__init__.py +0 -0
- {annarchy-5.0.2 → annarchy-5.0.3}/ANNarchy/generator/__init__.py +0 -0
- {annarchy-5.0.2 → annarchy-5.0.3}/ANNarchy/include/Specific.hpp +0 -0
- {annarchy-5.0.2 → annarchy-5.0.3}/ANNarchy/inputs/CurrentInjection.py +0 -0
- {annarchy-5.0.2 → annarchy-5.0.3}/ANNarchy/inputs/DecodingProjection.py +0 -0
- {annarchy-5.0.2 → annarchy-5.0.3}/ANNarchy/inputs/InputArray.py +0 -0
- {annarchy-5.0.2 → annarchy-5.0.3}/ANNarchy/inputs/PoissonPopulation.py +0 -0
- {annarchy-5.0.2 → annarchy-5.0.3}/ANNarchy/inputs/SpikeSourceArray.py +0 -0
- {annarchy-5.0.2 → annarchy-5.0.3}/ANNarchy/inputs/__init__.py +0 -0
- {annarchy-5.0.2 → annarchy-5.0.3}/ANNarchy/intern/GlobalObjects.py +0 -0
- {annarchy-5.0.2 → annarchy-5.0.3}/ANNarchy/intern/Messages.py +0 -0
- {annarchy-5.0.2 → annarchy-5.0.3}/ANNarchy/intern/Profiler.py +0 -0
- {annarchy-5.0.2 → annarchy-5.0.3}/ANNarchy/intern/SpecificPopulation.py +0 -0
- {annarchy-5.0.2 → annarchy-5.0.3}/ANNarchy/intern/SpecificProjection.py +0 -0
- {annarchy-5.0.2 → annarchy-5.0.3}/ANNarchy/intern/__init__.py +0 -0
- {annarchy-5.0.2 → annarchy-5.0.3}/ANNarchy/models/Neurons.py +0 -0
- {annarchy-5.0.2 → annarchy-5.0.3}/ANNarchy/models/Synapses.py +0 -0
- {annarchy-5.0.2 → annarchy-5.0.3}/ANNarchy/models/__init__.py +0 -0
- {annarchy-5.0.2 → annarchy-5.0.3}/ANNarchy/parser/AnalyseNeuron.py +0 -0
- {annarchy-5.0.2 → annarchy-5.0.3}/ANNarchy/parser/AnalyseSynapse.py +0 -0
- {annarchy-5.0.2 → annarchy-5.0.3}/ANNarchy/parser/CoupledEquations.py +0 -0
- {annarchy-5.0.2 → annarchy-5.0.3}/ANNarchy/parser/Equation.py +0 -0
- {annarchy-5.0.2 → annarchy-5.0.3}/ANNarchy/parser/Extraction.py +0 -0
- {annarchy-5.0.2 → annarchy-5.0.3}/ANNarchy/parser/Function.py +0 -0
- {annarchy-5.0.2 → annarchy-5.0.3}/ANNarchy/parser/ITE.py +0 -0
- {annarchy-5.0.2 → annarchy-5.0.3}/ANNarchy/parser/ParserTemplate.py +0 -0
- {annarchy-5.0.2 → annarchy-5.0.3}/ANNarchy/parser/StringManipulation.py +0 -0
- {annarchy-5.0.2 → annarchy-5.0.3}/ANNarchy/parser/__init__.py +0 -0
- {annarchy-5.0.2 → annarchy-5.0.3}/ANNarchy/parser/report/LatexParser.py +0 -0
- {annarchy-5.0.2 → annarchy-5.0.3}/ANNarchy/parser/report/LatexReport.py +0 -0
- {annarchy-5.0.2 → annarchy-5.0.3}/ANNarchy/parser/report/MarkdownReport.py +0 -0
- {annarchy-5.0.2 → annarchy-5.0.3}/ANNarchy/parser/report/Report.py +0 -0
- {annarchy-5.0.2 → annarchy-5.0.3}/ANNarchy/parser/report/__init__.py +0 -0
- {annarchy-5.0.2 → annarchy-5.0.3}/ANNarchy/thirdparty/randutils.hpp +0 -0
- {annarchy-5.0.2 → annarchy-5.0.3}/ANNarchy.egg-info/dependency_links.txt +0 -0
- {annarchy-5.0.2 → annarchy-5.0.3}/ANNarchy.egg-info/requires.txt +0 -0
- {annarchy-5.0.2 → annarchy-5.0.3}/ANNarchy.egg-info/top_level.txt +0 -0
- {annarchy-5.0.2 → annarchy-5.0.3}/AUTHORS +0 -0
- {annarchy-5.0.2 → annarchy-5.0.3}/LICENSE +0 -0
- {annarchy-5.0.2 → annarchy-5.0.3}/MANIFEST.in +0 -0
- {annarchy-5.0.2 → annarchy-5.0.3}/setup.cfg +0 -0
|
@@ -58,6 +58,7 @@ from .models.Synapses import (
|
|
|
58
58
|
from .extensions import *
|
|
59
59
|
from .intern.ConfigManagement import setup
|
|
60
60
|
from .intern import Messages
|
|
61
|
+
from .core.CTypes import float32, float64
|
|
61
62
|
|
|
62
63
|
# Cython modules
|
|
63
64
|
try:
|
|
@@ -89,7 +90,7 @@ atexit.register(clear)
|
|
|
89
90
|
|
|
90
91
|
# Version
|
|
91
92
|
__version__ = "5.0"
|
|
92
|
-
__release__ = "5.0.
|
|
93
|
+
__release__ = "5.0.3"
|
|
93
94
|
|
|
94
95
|
# Deprecated imports from this module:
|
|
95
96
|
_deprecated = {
|
|
@@ -4,11 +4,9 @@
|
|
|
4
4
|
"""
|
|
5
5
|
|
|
6
6
|
from dataclasses import dataclass
|
|
7
|
-
from
|
|
8
|
-
|
|
9
|
-
# Parameters
|
|
10
|
-
|
|
7
|
+
from .Random import RandomDistribution
|
|
11
8
|
|
|
9
|
+
# Parameters are attributes which does not change during simulate
|
|
12
10
|
@dataclass
|
|
13
11
|
class Parameter:
|
|
14
12
|
"""
|
|
@@ -48,7 +46,7 @@ class Parameter:
|
|
|
48
46
|
type: str = "float"
|
|
49
47
|
|
|
50
48
|
|
|
51
|
-
# Variables
|
|
49
|
+
# Variables are attributes which does change during simulate via equations
|
|
52
50
|
@dataclass
|
|
53
51
|
class Variable:
|
|
54
52
|
"""
|
|
@@ -0,0 +1,74 @@
|
|
|
1
|
+
"""
|
|
2
|
+
:copyright: Copyright 2013 - now, see AUTHORS.
|
|
3
|
+
:license: GPLv2, see LICENSE for details.
|
|
4
|
+
"""
|
|
5
|
+
from dataclasses import dataclass
|
|
6
|
+
|
|
7
|
+
class CTypeBase:
|
|
8
|
+
"""
|
|
9
|
+
Base class for CTypes used in our framework. All functions should be
|
|
10
|
+
overloaded by the deriving classes, otherwise an exception is raised.
|
|
11
|
+
"""
|
|
12
|
+
@property
|
|
13
|
+
def cpp_decl_type(self) -> str:
|
|
14
|
+
"Returns data type used int the C++ simulation code as string."
|
|
15
|
+
raise NotImplementedError
|
|
16
|
+
|
|
17
|
+
@property
|
|
18
|
+
def py_decl_type(self) -> str:
|
|
19
|
+
"Returns data type used in the nanobind interface to the C++ simulation code as string."
|
|
20
|
+
raise NotImplementedError
|
|
21
|
+
|
|
22
|
+
@property
|
|
23
|
+
def bits(self) -> int:
|
|
24
|
+
"Returns number of bits, raises exception if not implemented by child type."
|
|
25
|
+
raise NotImplementedError
|
|
26
|
+
|
|
27
|
+
#
|
|
28
|
+
# Floating-point precision type
|
|
29
|
+
#
|
|
30
|
+
@dataclass(frozen=True)
|
|
31
|
+
class FloatType(CTypeBase):
|
|
32
|
+
"""
|
|
33
|
+
Floating-point data type.
|
|
34
|
+
"""
|
|
35
|
+
exp: int
|
|
36
|
+
mantissa: int
|
|
37
|
+
|
|
38
|
+
FP32 = (8, 23)
|
|
39
|
+
FP64 = (11, 52)
|
|
40
|
+
|
|
41
|
+
@property
|
|
42
|
+
def cpp_decl_type(self) -> str:
|
|
43
|
+
"Returns data type used int the C++ simulation code as string."
|
|
44
|
+
if (self.exp, self.mantissa) == FloatType.FP32:
|
|
45
|
+
return "float"
|
|
46
|
+
|
|
47
|
+
if (self.exp, self.mantissa) == FloatType.FP64:
|
|
48
|
+
return "double"
|
|
49
|
+
|
|
50
|
+
raise ValueError(
|
|
51
|
+
f"Unsupported float format: exp={self.exp}, mantissa={self.mantissa}"
|
|
52
|
+
)
|
|
53
|
+
|
|
54
|
+
@property
|
|
55
|
+
def py_decl_type(self) -> str:
|
|
56
|
+
"Returns data type used in the nanobind interface to the C++ simulation code as string."
|
|
57
|
+
if (self.exp, self.mantissa) == FloatType.FP32:
|
|
58
|
+
# ANNarchy4.x behavior force to double always
|
|
59
|
+
return "double"
|
|
60
|
+
|
|
61
|
+
if (self.exp, self.mantissa) == FloatType.FP64:
|
|
62
|
+
return "double"
|
|
63
|
+
|
|
64
|
+
raise ValueError(
|
|
65
|
+
f"Unsupported float format: exp={self.exp}, mantissa={self.mantissa}"
|
|
66
|
+
)
|
|
67
|
+
|
|
68
|
+
@property
|
|
69
|
+
def bits(self) -> int:
|
|
70
|
+
return 1 + self.exp + self.mantissa
|
|
71
|
+
|
|
72
|
+
# Some pre-defined types
|
|
73
|
+
float32 = FloatType(8, 23)
|
|
74
|
+
float64 = FloatType(11, 52)
|
|
@@ -843,7 +843,12 @@ def connect_from_file(
|
|
|
843
843
|
lil.w = [[float(data["w"])]]
|
|
844
844
|
elif isinstance(data["w"], (np.ndarray,)) and data["w"].size == 1:
|
|
845
845
|
single_w = True
|
|
846
|
-
|
|
846
|
+
try:
|
|
847
|
+
lil.w = [[float(data["w"])]]
|
|
848
|
+
except TypeError:
|
|
849
|
+
# newer NumPy versions, throw an TypeError exception:
|
|
850
|
+
# "only 0-dimensional arrays can be converted to Python scalars"
|
|
851
|
+
lil.w = [[float(data["w"][0][0])]]
|
|
847
852
|
else:
|
|
848
853
|
lil.w = data["w"]
|
|
849
854
|
|
|
@@ -555,13 +555,13 @@ class Monitor:
|
|
|
555
555
|
"""Returns the value of a variable with the given name."""
|
|
556
556
|
|
|
557
557
|
if isinstance(self.object, PopulationView):
|
|
558
|
-
return self._get_population(
|
|
558
|
+
return self._get_population(name, keep)
|
|
559
559
|
|
|
560
560
|
elif isinstance(self.object, Population):
|
|
561
561
|
if not reshape or name == "spike":
|
|
562
|
-
return self._get_population(
|
|
562
|
+
return self._get_population(name, keep)
|
|
563
563
|
return np.reshape(
|
|
564
|
-
self._get_population(
|
|
564
|
+
self._get_population(name, keep),
|
|
565
565
|
(-1,) + self.object.geometry,
|
|
566
566
|
)
|
|
567
567
|
|
|
@@ -658,7 +658,7 @@ class Monitor:
|
|
|
658
658
|
"Monitor.save: File type not recognized (Must be .hdf5 or .npy)."
|
|
659
659
|
)
|
|
660
660
|
|
|
661
|
-
def _get_population(self,
|
|
661
|
+
def _get_population(self, name, keep):
|
|
662
662
|
try:
|
|
663
663
|
data = getattr(self.cyInstance, name)
|
|
664
664
|
if not keep:
|
|
@@ -526,6 +526,7 @@ class Network(metaclass=NetworkMeta):
|
|
|
526
526
|
annarchy_json: str = "",
|
|
527
527
|
silent: bool = False,
|
|
528
528
|
debug_build: bool = False,
|
|
529
|
+
trace_calls: str = None,
|
|
529
530
|
profile_enabled: bool = False,
|
|
530
531
|
) -> None:
|
|
531
532
|
"""
|
|
@@ -539,12 +540,17 @@ class Network(metaclass=NetworkMeta):
|
|
|
539
540
|
:param annarchy_json: compiler flags etc are stored in a .json file normally placed in the home directory. With this flag one can directly assign a file location.
|
|
540
541
|
:param silent: defines if the "Compiling... OK" should be printed.
|
|
541
542
|
|
|
543
|
+
The following arguments are mostly intended for debugging purposes:
|
|
544
|
+
|
|
545
|
+
:param debug_build: creates a debug version of ANNarchy, which logs the creation of objects and some other data (default: False).
|
|
546
|
+
:param trace_calls: if set to *init*, *simulate*, or *both* simulation calls inside of the C++ kernel are logged to console (default: None).
|
|
542
547
|
"""
|
|
543
548
|
Compiler.compile(
|
|
544
549
|
directory=directory,
|
|
545
550
|
clean=clean,
|
|
546
551
|
silent=silent,
|
|
547
552
|
debug_build=debug_build,
|
|
553
|
+
trace_calls=trace_calls,
|
|
548
554
|
add_sources=add_sources,
|
|
549
555
|
extra_libs=extra_libs,
|
|
550
556
|
compiler=compiler,
|
|
@@ -1000,7 +1006,7 @@ class Network(metaclass=NetworkMeta):
|
|
|
1000
1006
|
* `dt`: simulation step size in milliseconds (default: 1.0).
|
|
1001
1007
|
* `paradigm`: parallel framework for code generation. Accepted values: "openmp" or "cuda" (default: "openmp").
|
|
1002
1008
|
* `method`: default method to numerize the ODEs. Default is the explicit forward Euler method ('explicit').
|
|
1003
|
-
* `
|
|
1009
|
+
* `dtype`: default data type used for attributes in ANNarchy. Accepted values, available on the top-level of the ANNarchy package: float32 or float64 (default: float64).
|
|
1004
1010
|
* `structural_plasticity`: allows synapses to be dynamically added/removed during the simulation (default: False).
|
|
1005
1011
|
* `seed`: the seed (integer) to be used in the random number generators (default = None is equivalent to time(NULL)).
|
|
1006
1012
|
* `num_threads`: number of treads used by openMP (overrides the environment variable ``OMP_NUM_THREADS`` when set, default = None).
|
|
@@ -1019,6 +1025,9 @@ class Network(metaclass=NetworkMeta):
|
|
|
1019
1025
|
* `show_time`: if True, initialization times are shown. Attention: verbose should be set to True additionally.
|
|
1020
1026
|
* `disable_shared_library_time_offset`: by default False. If set to True, the shared library generated by ANNarchy will not be extended by time offset.
|
|
1021
1027
|
"""
|
|
1028
|
+
# ANNarchy 4.x interface
|
|
1029
|
+
if 'precision' in kwargs.keys():
|
|
1030
|
+
Messages.error("The precision flag has been replaced by 'dtype'. Note that the arguments has changed too!")
|
|
1022
1031
|
|
|
1023
1032
|
# RNG-related arguments are treated differently
|
|
1024
1033
|
rng_changed = False
|
|
@@ -226,7 +226,7 @@ class Population:
|
|
|
226
226
|
Instantiates the population after compilation of the C++ simulation core.
|
|
227
227
|
The function should solely called by Compiler._instantiate().
|
|
228
228
|
|
|
229
|
-
:param module:
|
|
229
|
+
:param module: nanobind module (ANNarchyWrapper instance)
|
|
230
230
|
"""
|
|
231
231
|
if NetworkManager().get_network(net_id=self.net_id)._profiler is not None:
|
|
232
232
|
import time
|
|
@@ -489,37 +489,28 @@ class Population:
|
|
|
489
489
|
)
|
|
490
490
|
|
|
491
491
|
elif isinstance(value, list):
|
|
492
|
+
setattr(self.cyInstance, attribute, value)
|
|
493
|
+
# Attributes need to be updated during next simulate() call.
|
|
492
494
|
if _check_paradigm("cuda", self.net_id):
|
|
493
|
-
# See `ANNarchy.parser.Extraction.extract_boundsflags` for more details
|
|
494
|
-
if ctype == "char":
|
|
495
|
-
value = [str(1) if x else str(0) for x in value]
|
|
496
|
-
setattr(self.cyInstance, attribute, value)
|
|
497
495
|
setattr(self.cyInstance, attribute + "_host_to_device", True)
|
|
498
|
-
else:
|
|
499
|
-
setattr(self.cyInstance, attribute, value)
|
|
500
496
|
|
|
501
497
|
else:
|
|
498
|
+
setattr(
|
|
499
|
+
self.cyInstance,
|
|
500
|
+
attribute,
|
|
501
|
+
[value for _ in range(self.size)],
|
|
502
|
+
)
|
|
503
|
+
# Attributes need to be updated during next simulate() call.
|
|
502
504
|
if _check_paradigm("cuda", self.net_id):
|
|
503
|
-
# See `ANNarchy.parser.Extraction.extract_boundsflags` for more details
|
|
504
|
-
if ctype == "char":
|
|
505
|
-
value = str(1) if value else str(0)
|
|
506
|
-
setattr(
|
|
507
|
-
self.cyInstance,
|
|
508
|
-
attribute,
|
|
509
|
-
[value for _ in range(self.size)],
|
|
510
|
-
)
|
|
511
505
|
setattr(self.cyInstance, attribute + "_host_to_device", True)
|
|
512
|
-
else:
|
|
513
|
-
setattr(
|
|
514
|
-
self.cyInstance,
|
|
515
|
-
attribute,
|
|
516
|
-
[value for _ in range(self.size)],
|
|
517
|
-
)
|
|
518
506
|
|
|
519
507
|
else:
|
|
508
|
+
if not np.isscalar(value):
|
|
509
|
+
raise ValueError(f"Population (name={self.name}): Expected single value for global attribute '{attribute}' but received {type(value)}.")
|
|
510
|
+
|
|
520
511
|
setattr(self.cyInstance, attribute, value)
|
|
521
512
|
if _check_paradigm("cuda", self.net_id):
|
|
522
|
-
#
|
|
513
|
+
# Attributes need to be updated during next simulate() call.
|
|
523
514
|
if attribute in [
|
|
524
515
|
attr["name"]
|
|
525
516
|
for attr in self.neuron_type.description["variables"]
|
|
@@ -360,7 +360,7 @@ class Projection:
|
|
|
360
360
|
Instantiates the projection after compilation. The function should be
|
|
361
361
|
called by Compiler._instantiate().
|
|
362
362
|
|
|
363
|
-
:param module:
|
|
363
|
+
:param module: nanobind module (ANNarchyWrapper instance)
|
|
364
364
|
"""
|
|
365
365
|
if NetworkManager().get_network(net_id=self.net_id)._profiler is not None:
|
|
366
366
|
import time
|
|
@@ -404,7 +404,7 @@ class Projection:
|
|
|
404
404
|
|
|
405
405
|
Returns True, if the connector was successfully instantiated. Potential errors are kept by Python exceptions. If the Cython connector call fails (return False) the most likely reason is that there was not enough memory available.
|
|
406
406
|
|
|
407
|
-
:param module:
|
|
407
|
+
:param module: nanobind wrapper (ANNarchyWrapper instance)
|
|
408
408
|
|
|
409
409
|
"""
|
|
410
410
|
# Local import to prevent circular import (HD: 28th June 2021)
|
|
@@ -103,7 +103,7 @@ class AccProjection(SpecificProjection):
|
|
|
103
103
|
void start(int baseline_period) {
|
|
104
104
|
init_baseline_period=baseline_period;
|
|
105
105
|
time_for_init_baseline = t + baseline_period;
|
|
106
|
-
#
|
|
106
|
+
#ifndef NDEBUG
|
|
107
107
|
std::cout << "ProjStruct%(id_proj)s: set new baseline period from step " << t << " to step " << time_for_init_baseline << std::endl;
|
|
108
108
|
#endif
|
|
109
109
|
}
|
|
@@ -270,7 +270,7 @@ class AccProjection(SpecificProjection):
|
|
|
270
270
|
void start(int baseline_period) {
|
|
271
271
|
init_baseline_period=baseline_period;
|
|
272
272
|
time_for_init_baseline = t + baseline_period;
|
|
273
|
-
#
|
|
273
|
+
#ifndef NDEBUG
|
|
274
274
|
std::cout << "ProjStruct%(id_proj)s: set new baseline period from step " << t << " to step " << time_for_init_baseline << std::endl;
|
|
275
275
|
#endif
|
|
276
276
|
}
|
|
@@ -141,7 +141,7 @@ convolve_template_cuda = {
|
|
|
141
141
|
# no read-back is required
|
|
142
142
|
"host_device_transfer": """
|
|
143
143
|
if (pre_coords_dirty) {
|
|
144
|
-
#
|
|
144
|
+
#ifndef NDEBUG
|
|
145
145
|
std::cout << "ProjStruct%(id_proj)s (convolution): update device coords." << std::endl;
|
|
146
146
|
#endif
|
|
147
147
|
auto flat_coords = transform_2d_to_1d<int>(pre_coords);
|
|
@@ -174,7 +174,7 @@ conv_filter_template = {
|
|
|
174
174
|
// Local parameter w
|
|
175
175
|
%(type_w)s get_w() { return w; }
|
|
176
176
|
void set_w(%(type_w)s value) {
|
|
177
|
-
#
|
|
177
|
+
#ifndef NDEBUG
|
|
178
178
|
std::cout << "ProjStruct%(id_proj)s (convolution): set new filter on host" << std::endl;
|
|
179
179
|
#endif
|
|
180
180
|
w = value;
|
|
@@ -183,7 +183,7 @@ conv_filter_template = {
|
|
|
183
183
|
""",
|
|
184
184
|
"host_device_transfer": """
|
|
185
185
|
if ( host_w_dirty ) {
|
|
186
|
-
#
|
|
186
|
+
#ifndef NDEBUG
|
|
187
187
|
std::cout << "ProjStruct%(id_proj)s (convolution): update device filter." << std::endl;
|
|
188
188
|
#endif
|
|
189
189
|
auto flat_data = transform_%(pre_dim)sd_to_1d<%(ctype)s>(w);
|
|
@@ -234,7 +234,7 @@ void convolution_proj%(id_proj)s(RunConfig cfg, %(float_prec)s* __restrict__ psp
|
|
|
234
234
|
pop%(id_post)s->gpu__sum_%(target)s, proj%(id_proj)s->gpu_pre_coords, proj%(id_proj)s->gpu_w%(pre_variables_call)s
|
|
235
235
|
);
|
|
236
236
|
|
|
237
|
-
#
|
|
237
|
+
#ifndef NDEBUG
|
|
238
238
|
auto proj%(id_proj)s_conv_err = cudaDeviceSynchronize();
|
|
239
239
|
if ( proj%(id_proj)s_conv_err != cudaSuccess) {
|
|
240
240
|
std::cout << "Convolution projection %(id_proj)s - psp: " << cudaGetErrorString( proj%(id_proj)s_conv_err ) << std::endl;
|
|
@@ -269,7 +269,7 @@ cuda_convolution_bank_of_filter = {
|
|
|
269
269
|
pop%(id_post)s->gpu__sum_%(target)s, proj%(id_proj)s->gpu_pre_coords, proj%(id_proj)s->gpu_w%(pre_variables_call)s
|
|
270
270
|
);
|
|
271
271
|
|
|
272
|
-
#
|
|
272
|
+
#ifndef NDEBUG
|
|
273
273
|
auto proj%(id_proj)s_conv_err = cudaDeviceSynchronize();
|
|
274
274
|
if ( proj%(id_proj)s_conv_err != cudaSuccess) {
|
|
275
275
|
std::cout << "Convolution projection %(id_proj)s - psp: " << cudaGetErrorString( proj%(id_proj)s_conv_err ) << std::endl;
|
|
@@ -319,7 +319,7 @@ void convolution_proj%(id_proj)s(RunConfig cfg, %(float_prec)s* psp, const int*
|
|
|
319
319
|
pop%(id_post)s->gpu__sum_%(target)s, proj%(id_proj)s->gpu_pre_coords, proj%(id_proj)s->gpu_w%(pre_variables_call)s
|
|
320
320
|
);
|
|
321
321
|
|
|
322
|
-
#
|
|
322
|
+
#ifndef NDEBUG
|
|
323
323
|
auto proj%(id_proj)s_conv_err = cudaDeviceSynchronize();
|
|
324
324
|
if ( proj%(id_proj)s_conv_err != cudaSuccess) {
|
|
325
325
|
std::cout << "Convolution projection %(id_proj)s - psp: " << cudaGetErrorString( proj%(id_proj)s_conv_err ) << std::endl;
|
|
@@ -379,7 +379,7 @@ void convolution_proj%(id_proj)s(RunConfig cfg, %(float_prec)s* psp, const int*
|
|
|
379
379
|
pop%(id_post)s->gpu__sum_%(target)s, proj%(id_proj)s->gpu_pre_coords, proj%(id_proj)s->gpu_w%(pre_variables_call)s
|
|
380
380
|
);
|
|
381
381
|
|
|
382
|
-
#
|
|
382
|
+
#ifndef NDEBUG
|
|
383
383
|
auto proj%(id_proj)s_conv_err = cudaDeviceSynchronize();
|
|
384
384
|
if ( proj%(id_proj)s_conv_err != cudaSuccess) {
|
|
385
385
|
std::cout << "Convolution projection %(id_proj)s - psp: " << cudaGetErrorString( proj%(id_proj)s_conv_err ) << std::endl;
|
|
@@ -112,7 +112,7 @@ pooling_template_cuda = {
|
|
|
112
112
|
# no read-back is required
|
|
113
113
|
"host_device_transfer": """
|
|
114
114
|
if (pre_coords_dirty) {
|
|
115
|
-
#
|
|
115
|
+
#ifndef NDEBUG
|
|
116
116
|
std::cout << "ProjStruct%(id_proj)s (pooling): update device coords." << std::endl;
|
|
117
117
|
#endif
|
|
118
118
|
auto err = cudaGetLastError();
|
|
@@ -418,7 +418,7 @@ cuda_pooling_code_3d = {
|
|
|
418
418
|
if (proj%(id_proj)s->_transmission && pop%(id_post)s->_active ) {
|
|
419
419
|
pooling_proj%(id_proj)s(RunConfig(%(size_post)s, 1, 0, proj%(id_proj)s->stream), pop%(id_post)s->gpu__sum_%(target)s, proj%(id_proj)s->gpu_pre_coords, pop%(id_pre)s->gpu_%(pre_var)s );
|
|
420
420
|
|
|
421
|
-
#
|
|
421
|
+
#ifndef NDEBUG
|
|
422
422
|
auto proj%(id_proj)s_pool_err = cudaDeviceSynchronize();
|
|
423
423
|
if ( proj%(id_proj)s_pool_err != cudaSuccess) {
|
|
424
424
|
std::cout << "Pooling projection %(id_proj)s - psp: " << cudaGetErrorString( proj%(id_proj)s_pool_err ) << std::endl;
|
|
@@ -5,13 +5,13 @@
|
|
|
5
5
|
|
|
6
6
|
from ANNarchy.core.Population import Population
|
|
7
7
|
from ANNarchy.core.Neuron import Neuron
|
|
8
|
+
|
|
8
9
|
from ANNarchy.intern.ConfigManagement import ConfigManager
|
|
9
|
-
from ANNarchy.generator.Compiler import extra_libs
|
|
10
10
|
from ANNarchy.intern import Messages
|
|
11
11
|
|
|
12
12
|
try:
|
|
13
13
|
from PIL import Image
|
|
14
|
-
except:
|
|
14
|
+
except ImportError:
|
|
15
15
|
Messages.warning(
|
|
16
16
|
"The Python Image Library (pillow) is not installed on your system, unable to create ImagePopulations."
|
|
17
17
|
)
|
|
@@ -184,10 +184,6 @@ class VideoPopulation(ImagePopulation):
|
|
|
184
184
|
|
|
185
185
|
def _generate(self):
|
|
186
186
|
"Code generation"
|
|
187
|
-
# Add corresponding libs to the Makefile
|
|
188
|
-
extra_libs.append(
|
|
189
|
-
"`pkg-config opencv" + str(self.opencv_version) + " --cflags --libs`"
|
|
190
|
-
)
|
|
191
187
|
|
|
192
188
|
# Include opencv
|
|
193
189
|
self._specific_template["include_additional"] = """#include <opencv2/opencv.hpp>
|
|
@@ -149,6 +149,9 @@ class CmdLineArgParser(object):
|
|
|
149
149
|
if options.num_threads is not None:
|
|
150
150
|
ConfigManagement._update_global_config("num_threads", options.num_threads)
|
|
151
151
|
|
|
152
|
+
if options.debug is not False:
|
|
153
|
+
ConfigManagement._update_global_config("debug", options.debug)
|
|
154
|
+
|
|
152
155
|
if options.visible_cores is not None:
|
|
153
156
|
try:
|
|
154
157
|
core_list = [int(x) for x in options.visible_cores.split(",")]
|