Skip to main content

No project description provided

Project description

BQN↔NumPy bridge

>>> import numpy as np
>>> import bqn
>>> bqn.bqn('{(+´÷≠)˘7↕𝕩}',np.arange(0,10,dtype=np.int32))
array([3, 4, 5, 6], dtype=int8)
>>> bqn.bqn('¯1⊑(1⊸+⥊+)○≠(⌊`⊢⌊⊏⊸»∘⊢-0∾1+⊣)˝=⌜⟜⌽',"kitten","sitting")
3.0

Installation

Install the BQN C library, libcbqn.so (libcbqn.dylib on Mac) to /usr/local/lib, and headers. Then:

pip3 install pybqn

Limitations

  • Only supports integer and floating-point types.
  • Can't marshal Python integer scalars to BQN.
  • Doesn't marshal BQN strings to Python

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

pybqn-0.1.1.tar.gz (15.4 kB view details)

Uploaded Source

Built Distribution

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

pybqn-0.1.1-cp313-cp313-macosx_10_13_universal2.whl (23.0 kB view details)

Uploaded CPython 3.13macOS 10.13+ universal2 (ARM64, x86-64)

File details

Details for the file pybqn-0.1.1.tar.gz.

File metadata

  • Download URL: pybqn-0.1.1.tar.gz
  • Upload date:
  • Size: 15.4 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.13.7

File hashes

Hashes for pybqn-0.1.1.tar.gz
Algorithm Hash digest
SHA256 14780e1f2b5ad6fa119d4dd5bb38689949af44e51d10ae820374a18e339cce36
MD5 a7df1ace96b4bb3c9d886d1cd7e3fbf6
BLAKE2b-256 5d00a4d5b96def8040c7efa3262e0b6b0bd4049ffda75b1bfecb1f0ba8fc2b9a

See more details on using hashes here.

File details

Details for the file pybqn-0.1.1-cp313-cp313-macosx_10_13_universal2.whl.

File metadata

File hashes

Hashes for pybqn-0.1.1-cp313-cp313-macosx_10_13_universal2.whl
Algorithm Hash digest
SHA256 49dd861402f5583c440bc7b47259a857f00d53034ddd71c7a6071fd7b88f58aa
MD5 150d93a84ae9c0830bab772cf7ebc982
BLAKE2b-256 2414f7ff8c86d7db96333f59c5b142d0c95045adc803c5a700b379a2c0a88710

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