Numstore is a from the ground up database engine designed specifically for arrays. It allows for creating and deleting variables and modifying arrays. It's novel algorithms make inner mutations O(log n) rather than O(n) of a traditional flat file
Numstore offers a variety of functionalities, ensuring that users can perform critical operations with ease:
Utilizing Numstore for basic operations is straightforward. The following code snippet demonstrates how to work with a Numstore database:
import numpy as np
import pynumstore as ns
# Basic Operations
with ns.open("mydb") as db:
# Create or get a variable
y = db.get_or_create("y", dtype="f32")
# Initialize dataset
del y[0:]
print("Initial State: ", y[0:])
# Append data
y.append(np.array([1.0, 2.0, 3.0], dtype=np.float32))
y.append(np.array([4.0, 5.0, 6.0], dtype=np.float32))
print("Seed Data: ", y[0:])
# Insert data
y.insert(2, np.array([4.0, 5.0, 6.0], dtype=np.float32))
print("After inner insert: ", y[0:])
# Modify entries
y[1:4] = np.array([9.0, 9.0, 9.0], dtype=np.float32)
print("After overwrite 1: ", y[0:])
# Remove even indices
del y[0::2]
print("End state: ", y[0:])
By leveraging Numstore, developers gain access to a flexible and efficient database engine, specifically crafted to optimize operations on arrays. With robust transaction support and an intuitive interface, Numstore enables quick development cycles and ensures data integrity.
For those interested in exploring further, additional sample applications are available in the repository, along with comprehensive documentation to assist in the onboarding process.
No comments yet.
Sign in to be the first to comment.