usearch 0.16.2 → 0.16.3

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.
package/Cargo.toml CHANGED
@@ -1,6 +1,6 @@
1
1
  [package]
2
2
  name = "usearch"
3
- version = "0.16.2"
3
+ version = "0.16.3"
4
4
  authors = ["Ashot Vardanian <1983160+ashvardanian@users.noreply.github.com>"]
5
5
  description = "Smaller & Faster Single-File Vector Search Engine from Unum"
6
6
  edition = "2021"
package/conanfile.py CHANGED
@@ -4,7 +4,7 @@ from conans import ConanFile
4
4
  class USearchConan(ConanFile):
5
5
 
6
6
  name = 'USearch'
7
- version = '0.16.2'
7
+ version = '0.16.3'
8
8
  license = 'Apache 2.0'
9
9
  url = 'https://github.com/unum-cloud/usearch'
10
10
  description = 'Smaller & Faster Single-File Vector Search Engine from Unum'
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "usearch",
3
- "version": "0.16.2",
3
+ "version": "0.16.3",
4
4
  "description": "Smaller & Faster Single-File Vector Search Engine from Unum",
5
5
  "author": "Ashot Vardanian",
6
6
  "license": "Apache 2.0",
@@ -1,4 +1,3 @@
1
- from time import time_ns
2
1
  from typing import Tuple, Any, Callable, Union, Optional, List
3
2
  from dataclasses import dataclass, asdict
4
3
  from collections import defaultdict
@@ -9,6 +8,17 @@ from usearch.io import load_matrix
9
8
  from usearch.index import Index, Matches, MetricKind, MetricKindBitwise
10
9
 
11
10
 
11
+ # For compatibility with Python 3.6
12
+ try:
13
+ from time import time_ns
14
+ except ImportError:
15
+ from datetime import datetime
16
+
17
+ def time_ns():
18
+ now = datetime.now()
19
+ return int(now.timestamp() * 1e9)
20
+
21
+
12
22
  def random_vectors(
13
23
  count: int,
14
24
  metric: MetricKind = MetricKind.IP,