Skip to main content

The DESILO FHE Library

Welcome to the DESILO FHE library!

The DESILO FHE library is a homomorphic encryption library that is fast and intuitive. It delivers state-of-the-art performance, maximum accuracy, and versatile usability. Designed to be accessible and efficient for everyone, from beginners unfamiliar with homomorphic encryption to experts developing advanced algorithms.

Built on C++ and CUDA, the DESILO FHE library is optimized for both CPUs and NVIDIA GPUs. It includes a Python wrapper for easy use and seamless integration into existing AI workflows. Additionally, it supports CPU parallelization for environments without GPU access.

Currently, the DESILO FHE library supports real and complex number operations based on the RNS-CKKS scheme, with plans to expand to various integer-based schemes in the future. It provides a powerful solution adaptable to diverse environments and requirements.

Documentation

Please refer to the official documentation for detailed installation instructions, examples, and documentation.

Quickstart

Encrypt / Decrypt

Encryption and decryption can be done with a secret key. You can encrypt and decrypt data as shown below. Note that CKKS is a real-number-based scheme, so a very small error is introduced during encryption and decryption.

from desilofhe import Engine

engine = Engine()

secret_key = engine.create_secret_key()

data = [1, 2, 3]
encrypted = engine.encrypt(data, secret_key)
decrypted = engine.decrypt(encrypted, secret_key)

print(decrypted[:3]) # [1. 2. 3.]

Encryption can also be done with a public key, which is genereated from a secret key.

from desilofhe import Engine

engine = Engine()

secret_key = engine.create_secret_key()
public_key = engine.create_public_key(secret_key)

data = [1, 2, 3]
encrypted = engine.encrypt(data, public_key)
decrypted = engine.decrypt(encrypted, secret_key)

print(decrypted[:3]) # [1. 2. 3.]

Add / Subtract

To add or subtract ciphertext, no additional keys are required beyond the public and secret keys. You can encrypt data separately and then perform addition and subtraction as follows:

from desilofhe import Engine

engine = Engine()

secret_key = engine.create_secret_key()

data1 = [1, 2, 3]
encrypted1 = engine.encrypt(data1, secret_key)

data2 = [4, 5, 6]
encrypted2 = engine.encrypt(data2, secret_key)

added = engine.add(encrypted1, encrypted2)
subtracted = engine.subtract(encrypted1, encrypted2)

decrypted1 = engine.decrypt(added, secret_key)
decrypted2 = engine.decrypt(subtracted, secret_key)

print(decrypted1[:3], decrypted2[:3]) # [5. 7. 9.] [-3. -3. -3.]

Multiply

To multiply ciphertexts, a special key called the relinearization key is required due to the nature of homomorphic encryption. You can encrypt data and perform multiplication as shown below. Note that ciphertexts in homomorphic encryption have a maximum multiplication depth, which will decrease after multiplication.

from desilofhe import Engine

engine = Engine()

secret_key = engine.create_secret_key()
relinearization_key = engine.create_relinearization_key(secret_key)

data1 = [1, 2, 3]
encrypted1 = engine.encrypt(data1, secret_key)

data2 = [4, 5, 6]
encrypted2 = engine.encrypt(data2, secret_key)

multiplied = engine.multiply(encrypted1, encrypted2, relinearization_key)

decrypted = engine.decrypt(multiplied, secret_key)

print(decrypted[:3]) # [~4 ~10 ~18]
print(encrypted1.level, encrypted2.level, multiplied.level) # 7 7 6

Contact

If you have any questions, please contact us at library@desilo.ai.

Download files

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

Source Distributions

No source distribution files available for this release.See tutorial on generating distribution archives.

Built Distributions

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

desilofhe-1.15.1-cp314-cp314-musllinux_1_2_x86_64.whl (2.1 MB view details)

Uploaded CPython 3.14musllinux: musl 1.2+ x86-64

desilofhe-1.15.1-cp314-cp314-manylinux_2_34_x86_64.whl (1.0 MB view details)

Uploaded CPython 3.14manylinux: glibc 2.34+ x86-64

desilofhe-1.15.1-cp314-cp314-macosx_11_0_x86_64.whl (848.0 kB view details)

Uploaded CPython 3.14macOS 11.0+ x86-64

desilofhe-1.15.1-cp314-cp314-macosx_11_0_arm64.whl (769.3 kB view details)

Uploaded CPython 3.14macOS 11.0+ ARM64

desilofhe-1.15.1-cp313-cp313-musllinux_1_2_x86_64.whl (2.1 MB view details)

Uploaded CPython 3.13musllinux: musl 1.2+ x86-64

desilofhe-1.15.1-cp313-cp313-manylinux_2_34_x86_64.whl (1.0 MB view details)

Uploaded CPython 3.13manylinux: glibc 2.34+ x86-64

desilofhe-1.15.1-cp313-cp313-macosx_11_0_x86_64.whl (847.9 kB view details)

Uploaded CPython 3.13macOS 11.0+ x86-64

desilofhe-1.15.1-cp313-cp313-macosx_11_0_arm64.whl (769.2 kB view details)

Uploaded CPython 3.13macOS 11.0+ ARM64

desilofhe-1.15.1-cp312-cp312-musllinux_1_2_x86_64.whl (2.1 MB view details)

Uploaded CPython 3.12musllinux: musl 1.2+ x86-64

desilofhe-1.15.1-cp312-cp312-manylinux_2_34_x86_64.whl (1.0 MB view details)

Uploaded CPython 3.12manylinux: glibc 2.34+ x86-64

desilofhe-1.15.1-cp312-cp312-macosx_11_0_x86_64.whl (847.4 kB view details)

Uploaded CPython 3.12macOS 11.0+ x86-64

desilofhe-1.15.1-cp312-cp312-macosx_11_0_arm64.whl (768.6 kB view details)

Uploaded CPython 3.12macOS 11.0+ ARM64

desilofhe-1.15.1-cp311-cp311-musllinux_1_2_x86_64.whl (2.1 MB view details)

Uploaded CPython 3.11musllinux: musl 1.2+ x86-64

desilofhe-1.15.1-cp311-cp311-manylinux_2_34_x86_64.whl (1.0 MB view details)

Uploaded CPython 3.11manylinux: glibc 2.34+ x86-64

desilofhe-1.15.1-cp311-cp311-macosx_11_0_x86_64.whl (846.7 kB view details)

Uploaded CPython 3.11macOS 11.0+ x86-64

desilofhe-1.15.1-cp311-cp311-macosx_11_0_arm64.whl (766.6 kB view details)

Uploaded CPython 3.11macOS 11.0+ ARM64

desilofhe-1.15.1-cp310-cp310-musllinux_1_2_x86_64.whl (2.1 MB view details)

Uploaded CPython 3.10musllinux: musl 1.2+ x86-64

desilofhe-1.15.1-cp310-cp310-manylinux_2_34_x86_64.whl (1.0 MB view details)

Uploaded CPython 3.10manylinux: glibc 2.34+ x86-64

desilofhe-1.15.1-cp310-cp310-macosx_11_0_x86_64.whl (844.5 kB view details)

Uploaded CPython 3.10macOS 11.0+ x86-64

desilofhe-1.15.1-cp310-cp310-macosx_11_0_arm64.whl (764.4 kB view details)

Uploaded CPython 3.10macOS 11.0+ ARM64

File details

Details for the file desilofhe-1.15.1-cp314-cp314-musllinux_1_2_x86_64.whl.

File metadata

File hashes

Hashes for desilofhe-1.15.1-cp314-cp314-musllinux_1_2_x86_64.whl
Algorithm Hash digest
SHA256 4c48d26819b958ffc8764eaf4a1c1c4f3c3b6feedbd89bccc7baa7cf7397af0a
MD5 f8f3c12da8ef7f9c2b5adf38de900e03
BLAKE2b-256 9bd5e563fb533b54d4e96e4b11449f0ba6e82aa57f3eff6c956998646c1c70fb

See more details on using hashes here.

File details

Details for the file desilofhe-1.15.1-cp314-cp314-manylinux_2_34_x86_64.whl.

File metadata

File hashes

Hashes for desilofhe-1.15.1-cp314-cp314-manylinux_2_34_x86_64.whl
Algorithm Hash digest
SHA256 ea4e6dc3790613a468dc63111056e5c55d40398403c78abdf900cc1692be4e13
MD5 3ed5969bbcc6f28b1da98a5d18c8ca8c
BLAKE2b-256 1f70579c6795a61f6bac8447b0890e434fd136e2356451d85c23d5a21db83611

See more details on using hashes here.

File details

Details for the file desilofhe-1.15.1-cp314-cp314-macosx_11_0_x86_64.whl.

File metadata

File hashes

Hashes for desilofhe-1.15.1-cp314-cp314-macosx_11_0_x86_64.whl
Algorithm Hash digest
SHA256 b386756d285de396eba0c364df1f0dcae9c80135293e570c6a744d9bd6d3fe48
MD5 01b9d6df19f11370eb6e901062f91bc8
BLAKE2b-256 76087ddb80be4fc0839ab960a2ba091ea3b24b136ab3b43a89f7de9ecff503dd

See more details on using hashes here.

File details

Details for the file desilofhe-1.15.1-cp314-cp314-macosx_11_0_arm64.whl.

File metadata

File hashes

Hashes for desilofhe-1.15.1-cp314-cp314-macosx_11_0_arm64.whl
Algorithm Hash digest
SHA256 b9b13cee1b6329b585087e140a313f1c3d0784da39e692d6e7cd5f471e680139
MD5 c6035d03163eaaeee4f28117723f24ba
BLAKE2b-256 3a1704e9b2d7cb3b1ef04445e6a88cd130a47f8da23092c38851c06563dec94a

See more details on using hashes here.

File details

Details for the file desilofhe-1.15.1-cp313-cp313-musllinux_1_2_x86_64.whl.

File metadata

File hashes

Hashes for desilofhe-1.15.1-cp313-cp313-musllinux_1_2_x86_64.whl
Algorithm Hash digest
SHA256 83c1a216da1f1897caf0dadf254d75a19c637c18db9abdcd7b606bd74e663aab
MD5 6713b9bdca4f5a9466d8913b74f5a0b3
BLAKE2b-256 a1ec4465792cedb481841a7b6ddf5834a8e60c0d26fc7538f8ab042640ecac25

See more details on using hashes here.

File details

Details for the file desilofhe-1.15.1-cp313-cp313-manylinux_2_34_x86_64.whl.

File metadata

File hashes

Hashes for desilofhe-1.15.1-cp313-cp313-manylinux_2_34_x86_64.whl
Algorithm Hash digest
SHA256 89dcdca381fdc65837e19ff043bd3ab1d070e2dbc13a2148537a8202db304a57
MD5 8cfc266216829fb2a9ff5dbec09001a9
BLAKE2b-256 b0928e50957afae8cba43533d8012bc31a490ad37c090c1d29aa1ecebf7ddadd

See more details on using hashes here.

File details

Details for the file desilofhe-1.15.1-cp313-cp313-macosx_11_0_x86_64.whl.

File metadata

File hashes

Hashes for desilofhe-1.15.1-cp313-cp313-macosx_11_0_x86_64.whl
Algorithm Hash digest
SHA256 fd72a0cdec671a121a8da46de545b1c966c7722db715e4775f11f7c80d4b6f8d
MD5 47a382a0cbeece99a23aedea6739a2d1
BLAKE2b-256 18bc35a73ff4824a0c2a03c4a27f687be208fd7b395838ded8704a8076f8ef41

See more details on using hashes here.

File details

Details for the file desilofhe-1.15.1-cp313-cp313-macosx_11_0_arm64.whl.

File metadata

File hashes

Hashes for desilofhe-1.15.1-cp313-cp313-macosx_11_0_arm64.whl
Algorithm Hash digest
SHA256 f64ba5e1cef795c1b88edde13bcb68ac2a5430333a40dfb7e9e9fdac025f0b31
MD5 5ab147b6315369ca701904edc2edfbb2
BLAKE2b-256 c3f1141453b846b051cc1fc8b737839102fbcbb7bd582f9a1a7e7c721a7bdaa3

See more details on using hashes here.

File details

Details for the file desilofhe-1.15.1-cp312-cp312-musllinux_1_2_x86_64.whl.

File metadata

File hashes

Hashes for desilofhe-1.15.1-cp312-cp312-musllinux_1_2_x86_64.whl
Algorithm Hash digest
SHA256 ea85b2f2fecae908b4405c6e67cffccf41e4f6aebe499a1c2ee7ae1eef6edc04
MD5 7ff018348fb8abfb60e546a8e3284db9
BLAKE2b-256 e3ae6c779f6f1b56c8b68f2619a2496f12d49eb99bf112966b5b7d6222f2d6bc

See more details on using hashes here.

File details

Details for the file desilofhe-1.15.1-cp312-cp312-manylinux_2_34_x86_64.whl.

File metadata

File hashes

Hashes for desilofhe-1.15.1-cp312-cp312-manylinux_2_34_x86_64.whl
Algorithm Hash digest
SHA256 d74a3f21f39e9ebb4f54024bab725c4fa907f8162242d7482b59336e396e9c92
MD5 02c58e502dbc5e18c1592bc6cd57b2be
BLAKE2b-256 ab1f6ee97935fd4d015f327eacb81d171ab38979874b1564c2554842d5eb9144

See more details on using hashes here.

File details

Details for the file desilofhe-1.15.1-cp312-cp312-macosx_11_0_x86_64.whl.

File metadata

File hashes

Hashes for desilofhe-1.15.1-cp312-cp312-macosx_11_0_x86_64.whl
Algorithm Hash digest
SHA256 d8a928f4c4b19e37d49c47630dd5f2356796ebcc9065b0f838b7d9f4c4f59205
MD5 a3066498e769c86ae05bbcb15432a6f8
BLAKE2b-256 074f2d2e8d56c8a96784c374a2faeee708e4e564e8ccedde8b902dfb7b691cf3

See more details on using hashes here.

File details

Details for the file desilofhe-1.15.1-cp312-cp312-macosx_11_0_arm64.whl.

File metadata

File hashes

Hashes for desilofhe-1.15.1-cp312-cp312-macosx_11_0_arm64.whl
Algorithm Hash digest
SHA256 39d9c5ab0e312a0662e7e35190ae07f6b96bfc488395b01d1da195bb000769aa
MD5 dd3351ee6661e679312c69ddf6d5c03a
BLAKE2b-256 fdac227dbf3216e0b8f5e5745b02f37ef85dc002bb8664319ad5ebbe3791e497

See more details on using hashes here.

File details

Details for the file desilofhe-1.15.1-cp311-cp311-musllinux_1_2_x86_64.whl.

File metadata

File hashes

Hashes for desilofhe-1.15.1-cp311-cp311-musllinux_1_2_x86_64.whl
Algorithm Hash digest
SHA256 53b206181625f854e5e1b3af60e2b2edc615c54d686d7e06334a9623e7ee3285
MD5 4d2c07be8b0a56a0eea0eb76bf402c36
BLAKE2b-256 e6fd39819400c8099c0213108f2407880e6285f20bc4ebff3a8b66ddc656c96e

See more details on using hashes here.

File details

Details for the file desilofhe-1.15.1-cp311-cp311-manylinux_2_34_x86_64.whl.

File metadata

File hashes

Hashes for desilofhe-1.15.1-cp311-cp311-manylinux_2_34_x86_64.whl
Algorithm Hash digest
SHA256 e3793dde99720924b9d5a6978dd1d80af80dd54f59a949601874726492a5ba36
MD5 7ba66d10b5d1f0dd0d0869c6527a69cf
BLAKE2b-256 b0ce96e9ad8d04c2cd497c2c225c5b8de86562674d2fb91d9ff6f3bdd9e19bb2

See more details on using hashes here.

File details

Details for the file desilofhe-1.15.1-cp311-cp311-macosx_11_0_x86_64.whl.

File metadata

File hashes

Hashes for desilofhe-1.15.1-cp311-cp311-macosx_11_0_x86_64.whl
Algorithm Hash digest
SHA256 3e830cacb2c66e7a1b62b863014a6cfd1811363989d977da945940302887fdd1
MD5 bf7ce6f2a3b76f98271fded8d3bba7b0
BLAKE2b-256 0ba28784c2a1023cf9e15cfdfec1d12864f9179761a17e8e1462a51befed2017

See more details on using hashes here.

File details

Details for the file desilofhe-1.15.1-cp311-cp311-macosx_11_0_arm64.whl.

File metadata

File hashes

Hashes for desilofhe-1.15.1-cp311-cp311-macosx_11_0_arm64.whl
Algorithm Hash digest
SHA256 de3d132055b64cf7103963a3b772ca54596022ead4c8ce24f14cbaf4116e0540
MD5 c9bec671be99c406863129e3055c1201
BLAKE2b-256 8fbe8f9b565529ccd83201c135962b817ad09be77338267b1d1a9b2b4f6922a7

See more details on using hashes here.

File details

Details for the file desilofhe-1.15.1-cp310-cp310-musllinux_1_2_x86_64.whl.

File metadata

File hashes

Hashes for desilofhe-1.15.1-cp310-cp310-musllinux_1_2_x86_64.whl
Algorithm Hash digest
SHA256 064b9c5520ead512193926b027166b35c32f5b2dd283b895d2d1a1320d0e497b
MD5 3f23bb46e891ad03d528500300e1a685
BLAKE2b-256 abe45a69924d52b0adb95c88eea6588e9b610d633f7b59709b9dd95ac3205235

See more details on using hashes here.

File details

Details for the file desilofhe-1.15.1-cp310-cp310-manylinux_2_34_x86_64.whl.

File metadata

File hashes

Hashes for desilofhe-1.15.1-cp310-cp310-manylinux_2_34_x86_64.whl
Algorithm Hash digest
SHA256 5f0c38dae736081393dc581f12b6886f3010d461328719fa5d3ec907e28a81f4
MD5 36f2ed9b7dddafd2bde03e2eadfa87c8
BLAKE2b-256 bcebbcbb1b51373b7955dd41b48e6aab96fa8670982e0abf8f00d526fee38a5d

See more details on using hashes here.

File details

Details for the file desilofhe-1.15.1-cp310-cp310-macosx_11_0_x86_64.whl.

File metadata

File hashes

Hashes for desilofhe-1.15.1-cp310-cp310-macosx_11_0_x86_64.whl
Algorithm Hash digest
SHA256 ad319189ccdc0fee4a9036a7cb0b68013fc1e6caaf0af8befcf8b647e17d77df
MD5 fbf1a0d765eec3f9d22b43b98f5a56fd
BLAKE2b-256 6128f630c214b25e82bb2b8bad8ae55a5eface1abe49d0d6d2e043d80a698a17

See more details on using hashes here.

File details

Details for the file desilofhe-1.15.1-cp310-cp310-macosx_11_0_arm64.whl.

File metadata

File hashes

Hashes for desilofhe-1.15.1-cp310-cp310-macosx_11_0_arm64.whl
Algorithm Hash digest
SHA256 6357bdb167a6a579643e5521514b276b603ae0526b27b96a18ac2941be71431d
MD5 ca34e958d321a427b5159f7a8fe1a8e8
BLAKE2b-256 d0bacb6e0a23f9b5cfd594c8fe3bd2323eaf410abfc958c0f2cd481e0f490084

See more details on using hashes here.

Release history Release notifications | RSS feed

1.16.0

20 files

This release

1.15.1 This release

20 files

1.15.0

20 files

1.14.1

20 files

1.14.0

20 files

1.13.0

20 files

1.12.0

20 files

1.11.2

20 files

1.11.1

20 files

1.11.0

20 files

1.10.0

20 files

1.9.0

20 files

1.8.0

20 files

1.7.0

20 files

1.6.0

20 files

1.5.1

20 files

1.5.0

20 files

1.4.0

20 files

1.3.0

20 files

1.2.0

20 files

1.1.1

20 files

1.1.0

20 files

1.0.3

20 files

1.0.2

20 files

1.0.1

5 files

1.0.0

5 files

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page