purem 2.0.3__tar.gz → 2.1.0__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.
- {purem-2.0.3/purem.egg-info → purem-2.1.0}/PKG-INFO +1 -1
- {purem-2.0.3 → purem-2.1.0}/README.md +3 -3
- purem-2.1.0/VERSION +1 -0
- {purem-2.0.3 → purem-2.1.0}/purem/core.py +16 -11
- {purem-2.0.3 → purem-2.1.0}/purem/logger.py +6 -0
- {purem-2.0.3 → purem-2.1.0/purem.egg-info}/PKG-INFO +1 -1
- {purem-2.0.3 → purem-2.1.0}/pyproject.toml +1 -1
- purem-2.0.3/VERSION +0 -1
- {purem-2.0.3 → purem-2.1.0}/LICENSE +0 -0
- {purem-2.0.3 → purem-2.1.0}/MANIFEST.in +0 -0
- {purem-2.0.3 → purem-2.1.0}/README.rst +0 -0
- {purem-2.0.3 → purem-2.1.0}/purem/__init__.py +0 -0
- {purem-2.0.3 → purem-2.1.0}/purem/env_config.py +0 -0
- {purem-2.0.3 → purem-2.1.0}/purem/file_structure.py +0 -0
- {purem-2.0.3 → purem-2.1.0}/purem/loader.py +0 -0
- {purem-2.0.3 → purem-2.1.0}/purem/utils.py +0 -0
- {purem-2.0.3 → purem-2.1.0}/purem.egg-info/SOURCES.txt +0 -0
- {purem-2.0.3 → purem-2.1.0}/purem.egg-info/dependency_links.txt +0 -0
- {purem-2.0.3 → purem-2.1.0}/purem.egg-info/requires.txt +0 -0
- {purem-2.0.3 → purem-2.1.0}/purem.egg-info/top_level.txt +0 -0
- {purem-2.0.3 → purem-2.1.0}/setup.cfg +0 -0
@@ -7,9 +7,9 @@
|
|
7
7
|
**Purem** is an advanced high-performance computational library optimized for vectorized mathematical operations. This project focuses on efficient execution of element-wise transformations, including `softmax`, `exp`, and other mathematical functions, leveraging highly optimized assembly code for modern architectures.
|
8
8
|
|
9
9
|
## Key Features
|
10
|
-
|
11
|
-
Achieve up to 80× faster performance on CPU/GPU/TPU — no rewrites, no dependencies, just speed.
|
12
|
-
|
10
|
+
|
11
|
+
Purem is a blazing-fast AI math engine that turns your Python formulas into native-speed vectorized execution. Achieve up to 80× faster performance on CPU/GPU/TPU — no rewrites, no dependencies, just speed. Designed for ML researchers, scientific computing, and production-grade workloads that can’t afford to wait.
|
12
|
+
|
13
13
|
---
|
14
14
|
|
15
15
|
## 🔧 Installation
|
purem-2.1.0/VERSION
ADDED
@@ -0,0 +1 @@
|
|
1
|
+
2.1.0
|
@@ -201,25 +201,31 @@ class Purem:
|
|
201
201
|
|
202
202
|
def _download_and_extract_binary(self):
|
203
203
|
req = urllib.request.Request(
|
204
|
-
self._download_binary_url,
|
204
|
+
self._download_binary_url,
|
205
|
+
headers={"User-Agent": "Mozilla/5.0"}
|
205
206
|
)
|
206
207
|
|
207
|
-
|
208
|
-
with
|
209
|
-
|
210
|
-
|
211
|
-
with open(self._binary_archive_path_tmp, "rb") as f:
|
212
|
-
zip_utf = base64.b64decode(f.read())
|
208
|
+
try:
|
209
|
+
with urllib.request.urlopen(req, context=self._ctx) as response:
|
210
|
+
with open(self._binary_archive_path_tmp, "wb") as out_file:
|
211
|
+
shutil.copyfileobj(response, out_file)
|
213
212
|
|
214
|
-
|
215
|
-
|
213
|
+
shutil.move(self._binary_archive_path_tmp, self._binary_archive_path)
|
214
|
+
except Exception as e:
|
215
|
+
raise RuntimeError(
|
216
|
+
self._log.info(
|
217
|
+
f"The Purem archive appears to be corrupted or incomplete.\nDetails: {e}"
|
218
|
+
"Please ensure the package downloaded fully and is unmodified.\n"
|
219
|
+
"Need help? Contact support@worktif.com – we'll assist right away.\n"
|
220
|
+
)
|
221
|
+
)
|
216
222
|
|
217
223
|
try:
|
218
224
|
with zipfile.ZipFile(self._binary_archive_path, "r") as zip_ref:
|
219
225
|
zip_ref.extractall(
|
220
226
|
self._file_structure.dirs.project_root_binary_dir_path
|
221
227
|
)
|
222
|
-
self._log.
|
228
|
+
self._log.info_new_line(
|
223
229
|
f"Purem binary extracted to: {self._file_structure.dirs.binary_dir_path}"
|
224
230
|
)
|
225
231
|
except zipfile.BadZipFile as e:
|
@@ -232,4 +238,3 @@ class Purem:
|
|
232
238
|
)
|
233
239
|
|
234
240
|
self._binary_archive_path.unlink()
|
235
|
-
self._binary_archive_path_tmp.unlink()
|
@@ -25,6 +25,12 @@ class Logger:
|
|
25
25
|
else:
|
26
26
|
return f"[purem]: {self._default_info_message}\n"
|
27
27
|
|
28
|
+
def info_new_line(self, message: str) -> str:
|
29
|
+
if self._env.PUREM_VERBOSE is True:
|
30
|
+
return f"\n[purem]: {message}\n"
|
31
|
+
else:
|
32
|
+
return f"\n[purem]: {self._default_info_message}\n"
|
33
|
+
|
28
34
|
def printr(self, message: str) -> str or None:
|
29
35
|
if self._env.PUREM_VERBOSE is True:
|
30
36
|
print(self.info(message))
|
@@ -4,7 +4,7 @@ build-backend = "setuptools.build_meta"
|
|
4
4
|
|
5
5
|
[project]
|
6
6
|
name = "purem"
|
7
|
-
version = "2.0
|
7
|
+
version = "2.1.0"
|
8
8
|
description = "High-performance mapping function for mixed-type arrays"
|
9
9
|
readme = { file = "README.rst", content-type = "text/x-rst" }
|
10
10
|
requires-python = ">=3.11"
|
purem-2.0.3/VERSION
DELETED
@@ -1 +0,0 @@
|
|
1
|
-
2.0.3
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|