Skip to main content

Configurable memory allocations

Project description

Memory management in NumPy*

Binder PyPI version

*NumPy is a trademark owned by NumFOCUS.

Customize Memory Allocators

Α metaclass is used to override the internal data memory routines. The metaclass has four optional fields:

>>> import ctypes
>>> import numpy_allocator
>>> my = ctypes.CDLL('libmy.so')
>>> class my_allocator(metaclass=numpy_allocator.type):
...     _calloc_ = my.calloc_func
...     _free_ = my.free_func
...     _malloc_ = my.malloc_func
...     _realloc_ = my.realloc_func
...

An example using the allocator

>>> import numpy as np
>>> with my_allocator:
...     a = np.array([1, 2, 3])
...
>>> my_allocator.handles(a)
True

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

numpy-allocator-1.1.2.tar.gz (10.3 kB view details)

Uploaded Source

Built Distributions

If you're not sure about the file name format, learn more about wheel file names.

numpy_allocator-1.1.2-pp39-pypy39_pp73-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_17_x86_64.manylinux2014_x86_64.whl (13.4 kB view details)

Uploaded PyPymanylinux: glibc 2.17+ x86-64manylinux: glibc 2.5+ x86-64

numpy_allocator-1.1.2-pp39-pypy39_pp73-manylinux_2_5_i686.manylinux1_i686.manylinux_2_17_i686.manylinux2014_i686.whl (13.7 kB view details)

Uploaded PyPymanylinux: glibc 2.17+ i686manylinux: glibc 2.5+ i686

numpy_allocator-1.1.2-pp38-pypy38_pp73-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_17_x86_64.manylinux2014_x86_64.whl (13.4 kB view details)

Uploaded PyPymanylinux: glibc 2.17+ x86-64manylinux: glibc 2.5+ x86-64

numpy_allocator-1.1.2-pp38-pypy38_pp73-manylinux_2_5_i686.manylinux1_i686.manylinux_2_17_i686.manylinux2014_i686.whl (13.7 kB view details)

Uploaded PyPymanylinux: glibc 2.17+ i686manylinux: glibc 2.5+ i686

numpy_allocator-1.1.2-cp311-cp311-musllinux_1_1_x86_64.whl (35.9 kB view details)

Uploaded CPython 3.11musllinux: musl 1.1+ x86-64

numpy_allocator-1.1.2-cp311-cp311-musllinux_1_1_i686.whl (34.5 kB view details)

Uploaded CPython 3.11musllinux: musl 1.1+ i686

numpy_allocator-1.1.2-cp311-cp311-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_17_x86_64.manylinux2014_x86_64.whl (31.9 kB view details)

Uploaded CPython 3.11manylinux: glibc 2.17+ x86-64manylinux: glibc 2.5+ x86-64

numpy_allocator-1.1.2-cp311-cp311-manylinux_2_5_i686.manylinux1_i686.manylinux_2_17_i686.manylinux2014_i686.whl (30.4 kB view details)

Uploaded CPython 3.11manylinux: glibc 2.17+ i686manylinux: glibc 2.5+ i686

numpy_allocator-1.1.2-cp310-cp310-musllinux_1_1_x86_64.whl (34.9 kB view details)

Uploaded CPython 3.10musllinux: musl 1.1+ x86-64

numpy_allocator-1.1.2-cp310-cp310-musllinux_1_1_i686.whl (33.6 kB view details)

Uploaded CPython 3.10musllinux: musl 1.1+ i686

numpy_allocator-1.1.2-cp310-cp310-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_17_x86_64.manylinux2014_x86_64.whl (31.7 kB view details)

Uploaded CPython 3.10manylinux: glibc 2.17+ x86-64manylinux: glibc 2.5+ x86-64

numpy_allocator-1.1.2-cp310-cp310-manylinux_2_5_i686.manylinux1_i686.manylinux_2_17_i686.manylinux2014_i686.whl (30.1 kB view details)

Uploaded CPython 3.10manylinux: glibc 2.17+ i686manylinux: glibc 2.5+ i686

numpy_allocator-1.1.2-cp39-cp39-musllinux_1_1_x86_64.whl (34.3 kB view details)

Uploaded CPython 3.9musllinux: musl 1.1+ x86-64

numpy_allocator-1.1.2-cp39-cp39-musllinux_1_1_i686.whl (33.0 kB view details)

Uploaded CPython 3.9musllinux: musl 1.1+ i686

numpy_allocator-1.1.2-cp39-cp39-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_17_x86_64.manylinux2014_x86_64.whl (31.2 kB view details)

Uploaded CPython 3.9manylinux: glibc 2.17+ x86-64manylinux: glibc 2.5+ x86-64

numpy_allocator-1.1.2-cp39-cp39-manylinux_2_5_i686.manylinux1_i686.manylinux_2_17_i686.manylinux2014_i686.whl (29.7 kB view details)

Uploaded CPython 3.9manylinux: glibc 2.17+ i686manylinux: glibc 2.5+ i686

numpy_allocator-1.1.2-cp38-cp38-musllinux_1_1_x86_64.whl (35.4 kB view details)

Uploaded CPython 3.8musllinux: musl 1.1+ x86-64

numpy_allocator-1.1.2-cp38-cp38-musllinux_1_1_i686.whl (34.1 kB view details)

Uploaded CPython 3.8musllinux: musl 1.1+ i686

numpy_allocator-1.1.2-cp38-cp38-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_17_x86_64.manylinux2014_x86_64.whl (31.6 kB view details)

Uploaded CPython 3.8manylinux: glibc 2.17+ x86-64manylinux: glibc 2.5+ x86-64

numpy_allocator-1.1.2-cp38-cp38-manylinux_2_5_i686.manylinux1_i686.manylinux_2_17_i686.manylinux2014_i686.whl (30.1 kB view details)

Uploaded CPython 3.8manylinux: glibc 2.17+ i686manylinux: glibc 2.5+ i686

File details

Details for the file numpy-allocator-1.1.2.tar.gz.

File metadata

  • Download URL: numpy-allocator-1.1.2.tar.gz
  • Upload date:
  • Size: 10.3 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/4.0.1 CPython/3.9.15

File hashes

Hashes for numpy-allocator-1.1.2.tar.gz
Algorithm Hash digest
SHA256 a9bbe18590f387cac4dcbbb4b0207052d50a4c659555b68b80bfee611add2964
MD5 c9d661b5e0ab424b39f8aa956e0944be
BLAKE2b-256 d0e73970d8d80c71f84dc7277e36cba5f9eac92c300eb004d62e5f2731ef4678

See more details on using hashes here.

File details

Details for the file numpy_allocator-1.1.2-pp39-pypy39_pp73-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_17_x86_64.manylinux2014_x86_64.whl.

File metadata

File hashes

Hashes for numpy_allocator-1.1.2-pp39-pypy39_pp73-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_17_x86_64.manylinux2014_x86_64.whl
Algorithm Hash digest
SHA256 40fa58fc057fb3eb7622689e74a902300f2f9c6997275d423a787e0fb543124b
MD5 aa10df3e0e5510471763d2a1e07ab765
BLAKE2b-256 0456782c5584ae4d9915e81c71b6cb7c1ffe7a7a83eb98a77275e41b2c7c138c

See more details on using hashes here.

File details

Details for the file numpy_allocator-1.1.2-pp39-pypy39_pp73-manylinux_2_5_i686.manylinux1_i686.manylinux_2_17_i686.manylinux2014_i686.whl.

File metadata

File hashes

Hashes for numpy_allocator-1.1.2-pp39-pypy39_pp73-manylinux_2_5_i686.manylinux1_i686.manylinux_2_17_i686.manylinux2014_i686.whl
Algorithm Hash digest
SHA256 1f191f9695dd0fb227acc343f15ef2d8dfda46e88a930cd7403dd17f7efbd2c6
MD5 6ff03b81a293924b16f7dc24f95b8d2e
BLAKE2b-256 5466f3bba01d3887ace6d96162c442026052e7679a1bac192c5d40e1b536595d

See more details on using hashes here.

File details

Details for the file numpy_allocator-1.1.2-pp38-pypy38_pp73-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_17_x86_64.manylinux2014_x86_64.whl.

File metadata

File hashes

Hashes for numpy_allocator-1.1.2-pp38-pypy38_pp73-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_17_x86_64.manylinux2014_x86_64.whl
Algorithm Hash digest
SHA256 e2df62abe81bbaf3698789eb6c281c1ce7e70b7bbb389b4519063e82f97581bc
MD5 79e08f35f6d1c4976c3cf3ff72201deb
BLAKE2b-256 a06e0a8ff4f8e8a40c5e5cdc3a3e67992447f6d6f23859bb88d8b4075119e225

See more details on using hashes here.

File details

Details for the file numpy_allocator-1.1.2-pp38-pypy38_pp73-manylinux_2_5_i686.manylinux1_i686.manylinux_2_17_i686.manylinux2014_i686.whl.

File metadata

File hashes

Hashes for numpy_allocator-1.1.2-pp38-pypy38_pp73-manylinux_2_5_i686.manylinux1_i686.manylinux_2_17_i686.manylinux2014_i686.whl
Algorithm Hash digest
SHA256 f346021a174384f52c28266814ede8dbc0c19e17fad34c4d7cb3e0694c2185f1
MD5 53a215e70e0998282dbedda5c9fb2b69
BLAKE2b-256 2d1ca524a170fa592e17c1333cb214c8f8647879b6bbf904357b2c8aaabd787b

See more details on using hashes here.

File details

Details for the file numpy_allocator-1.1.2-cp311-cp311-musllinux_1_1_x86_64.whl.

File metadata

File hashes

Hashes for numpy_allocator-1.1.2-cp311-cp311-musllinux_1_1_x86_64.whl
Algorithm Hash digest
SHA256 dae73a3d8087c31bd590f2eef745c4dc08eb45d49d2bb762d0a1e80f05904951
MD5 4eebf2f41a63efc6f43fdd51ca0ff7c0
BLAKE2b-256 f1744d063cae837339297a46128216ceb27a62a152f3390d2a29b9e42427a11b

See more details on using hashes here.

File details

Details for the file numpy_allocator-1.1.2-cp311-cp311-musllinux_1_1_i686.whl.

File metadata

File hashes

Hashes for numpy_allocator-1.1.2-cp311-cp311-musllinux_1_1_i686.whl
Algorithm Hash digest
SHA256 c2240cc2d1986c6137989b632da6570ac2ef5c2be0f348f3d958d6478693b2f7
MD5 3573d1546d6b2b3ac4d53e79b595b642
BLAKE2b-256 7d58c3c5c7eac8d6740841e0cd214238a3f8b535cdb3068a34c363b47237a611

See more details on using hashes here.

File details

Details for the file numpy_allocator-1.1.2-cp311-cp311-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_17_x86_64.manylinux2014_x86_64.whl.

File metadata

File hashes

Hashes for numpy_allocator-1.1.2-cp311-cp311-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_17_x86_64.manylinux2014_x86_64.whl
Algorithm Hash digest
SHA256 74e641eba51c54eeca107da356ad94e5fe7380f116b976a13fff24a5d6f28d64
MD5 c8769011b6f9cb2f43a807ef6daa9721
BLAKE2b-256 3346a6908e588bf94d3937fa758c5cd42e8f3c150d9c76c4876d8823494e79b4

See more details on using hashes here.

File details

Details for the file numpy_allocator-1.1.2-cp311-cp311-manylinux_2_5_i686.manylinux1_i686.manylinux_2_17_i686.manylinux2014_i686.whl.

File metadata

File hashes

Hashes for numpy_allocator-1.1.2-cp311-cp311-manylinux_2_5_i686.manylinux1_i686.manylinux_2_17_i686.manylinux2014_i686.whl
Algorithm Hash digest
SHA256 18ece9d933c0d497c382e31f10160ab2c216be343161999dafbeac5215c8f277
MD5 c9cd18137dbbefa9da466cb394d695e8
BLAKE2b-256 73ea0661fa803e9c7d1e8ccacdeb4adfa21d8e9fe70a7b63380d492242412c3b

See more details on using hashes here.

File details

Details for the file numpy_allocator-1.1.2-cp310-cp310-musllinux_1_1_x86_64.whl.

File metadata

File hashes

Hashes for numpy_allocator-1.1.2-cp310-cp310-musllinux_1_1_x86_64.whl
Algorithm Hash digest
SHA256 e27efba27ef7ccfcdc2b42a4ee0c8713730a1852fabbeaef9cc1f79cc48bade7
MD5 baa226af4cbbcb3703b1ed29bec46238
BLAKE2b-256 a3570440590f7af14f9436503f607dd7d872245bbc9ffbc9310623c1d7271c22

See more details on using hashes here.

File details

Details for the file numpy_allocator-1.1.2-cp310-cp310-musllinux_1_1_i686.whl.

File metadata

File hashes

Hashes for numpy_allocator-1.1.2-cp310-cp310-musllinux_1_1_i686.whl
Algorithm Hash digest
SHA256 510b7ccf6d238962dff2f2a9909a812c7abf4a1daf2012b93dfa8738fea05cf5
MD5 72f352f2da5ffb8a2536152c260e85b3
BLAKE2b-256 f2e7ffa85f6ca6a1c07457ff88d9b3e6ecc08cb30d0f21e2a0e74fc716229088

See more details on using hashes here.

File details

Details for the file numpy_allocator-1.1.2-cp310-cp310-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_17_x86_64.manylinux2014_x86_64.whl.

File metadata

File hashes

Hashes for numpy_allocator-1.1.2-cp310-cp310-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_17_x86_64.manylinux2014_x86_64.whl
Algorithm Hash digest
SHA256 f84d96a18e41af7dd96f8b094a3f049848fb27034e026dd6ad734c2f39adffc7
MD5 317b235ff69fa32f1717128f0ebf80f3
BLAKE2b-256 1d0901dd92bf940006b559ce06d4383a8c8da5133c79fde82dd5786f4a591366

See more details on using hashes here.

File details

Details for the file numpy_allocator-1.1.2-cp310-cp310-manylinux_2_5_i686.manylinux1_i686.manylinux_2_17_i686.manylinux2014_i686.whl.

File metadata

File hashes

Hashes for numpy_allocator-1.1.2-cp310-cp310-manylinux_2_5_i686.manylinux1_i686.manylinux_2_17_i686.manylinux2014_i686.whl
Algorithm Hash digest
SHA256 67e95d8b609c1c73cb48b2dba8fd2a6e725d90146376109dd27ac30b7af7b225
MD5 eecffca1f4c5bbeaca0556b438683ec7
BLAKE2b-256 3de6fb0fc625a464f0b5c4896d78d0cdd3d5e2f5199f93f74237cfaaf89d11f6

See more details on using hashes here.

File details

Details for the file numpy_allocator-1.1.2-cp39-cp39-musllinux_1_1_x86_64.whl.

File metadata

File hashes

Hashes for numpy_allocator-1.1.2-cp39-cp39-musllinux_1_1_x86_64.whl
Algorithm Hash digest
SHA256 51e47116ea38090494e16630bbf76619d7d92af26840f1f4a948e5bc7be8a4ed
MD5 b99612e81cc727df0c75efdedb2c273e
BLAKE2b-256 812fcc1ee16ccc698ddea03af8eb54f3574c0e3658fcce04b22042663056cc92

See more details on using hashes here.

File details

Details for the file numpy_allocator-1.1.2-cp39-cp39-musllinux_1_1_i686.whl.

File metadata

File hashes

Hashes for numpy_allocator-1.1.2-cp39-cp39-musllinux_1_1_i686.whl
Algorithm Hash digest
SHA256 cc2b8dbc22a4d18141b4ec3be5a452b1d460a374cfbb02c8b9afcf015127d440
MD5 78d90f67968988f0b2c7e74291bd6311
BLAKE2b-256 b465f2ab54ade860f585adb891718d611dd1c895eedaf6b8697e17b2b046aca2

See more details on using hashes here.

File details

Details for the file numpy_allocator-1.1.2-cp39-cp39-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_17_x86_64.manylinux2014_x86_64.whl.

File metadata

File hashes

Hashes for numpy_allocator-1.1.2-cp39-cp39-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_17_x86_64.manylinux2014_x86_64.whl
Algorithm Hash digest
SHA256 2377d580da66121d622c7d3ccfd8498393371044b87f1aed47b1e1240a507ce0
MD5 a064aae5b19a3ba24032995e0be5cca5
BLAKE2b-256 344709bf52b15f4be179892d580f6d52bd41243da05af37d8613dafd3f139c87

See more details on using hashes here.

File details

Details for the file numpy_allocator-1.1.2-cp39-cp39-manylinux_2_5_i686.manylinux1_i686.manylinux_2_17_i686.manylinux2014_i686.whl.

File metadata

File hashes

Hashes for numpy_allocator-1.1.2-cp39-cp39-manylinux_2_5_i686.manylinux1_i686.manylinux_2_17_i686.manylinux2014_i686.whl
Algorithm Hash digest
SHA256 f9e2009dfa616e2b0a2efb8e3d9f8b8b14d53474e3bc5c20fe617bc782bb60c0
MD5 0bde1839f4c36f24ca9a054eab56bd0d
BLAKE2b-256 7623396e9d2cf6d3e33762c35cfca2e0f485e26e3a788b452be286d8eede0db2

See more details on using hashes here.

File details

Details for the file numpy_allocator-1.1.2-cp38-cp38-musllinux_1_1_x86_64.whl.

File metadata

File hashes

Hashes for numpy_allocator-1.1.2-cp38-cp38-musllinux_1_1_x86_64.whl
Algorithm Hash digest
SHA256 a3011a3a68f97783e9d7b4bf15f8434c956ed84809647afe0bbfb676c7b312e3
MD5 11c1dde08685544218602b8952ed4ba5
BLAKE2b-256 84f6e98067e8bea002b3eef12d95fec320ff38b4fb1a14f2b1144fd862b57ea6

See more details on using hashes here.

File details

Details for the file numpy_allocator-1.1.2-cp38-cp38-musllinux_1_1_i686.whl.

File metadata

File hashes

Hashes for numpy_allocator-1.1.2-cp38-cp38-musllinux_1_1_i686.whl
Algorithm Hash digest
SHA256 2834d19fd2ed13fab9594df6ec40d7390d7f26d2cabb9bb6f61ec731eb6a8326
MD5 cebc47796e13b14d8277db988268d940
BLAKE2b-256 0c0691c458bee30495bc631c255b636a753c79751a8f360b116d75fc89d08751

See more details on using hashes here.

File details

Details for the file numpy_allocator-1.1.2-cp38-cp38-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_17_x86_64.manylinux2014_x86_64.whl.

File metadata

File hashes

Hashes for numpy_allocator-1.1.2-cp38-cp38-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_17_x86_64.manylinux2014_x86_64.whl
Algorithm Hash digest
SHA256 69f1a39f279e6c33e0fc7eb3014dff75b220c8cb7716d40a72bb5da4d06b4e92
MD5 28a65bf6b6766450552fcdc0b4046596
BLAKE2b-256 2b605d172684c9469ad21f78b9d73efa9ab6ed67fb04a00b5e19d21d6475f817

See more details on using hashes here.

File details

Details for the file numpy_allocator-1.1.2-cp38-cp38-manylinux_2_5_i686.manylinux1_i686.manylinux_2_17_i686.manylinux2014_i686.whl.

File metadata

File hashes

Hashes for numpy_allocator-1.1.2-cp38-cp38-manylinux_2_5_i686.manylinux1_i686.manylinux_2_17_i686.manylinux2014_i686.whl
Algorithm Hash digest
SHA256 d0012bd46ed1374e017e4c2d061516ae8f8cfb4ae03b1e926bc4f63f54c5a28c
MD5 4e495c12a5a8a52662623069caa802af
BLAKE2b-256 ae9af0d608adeef740e52135f1758925fbc01de666ce8b03ab51d5c506b3bcc5

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page