This release has been yanked by its maintainers, and will be ignored by installers, except when explicitly specified.
Consider using release 0.9.7 instead.
Reason given by maintainers: SDK 已迁移为 0.9.2 核心包加独立算法插件架构;旧版本停止推荐安装。
Ascent Science Python SDK
Ascent Science SDK 0.5.2 separates two execution modes:
ascent.local.LocalOptimizerexecutes exact and heuristic algorithms in the caller's Python process. It is intended for debugging, benchmarks, and small-scale workloads.ascent.cim.CIMOptimizersubmits QUBO/Ising matrices to an explicitly configured real CIM gateway, polls task state, downloads the result, and caches successful results locally.
The hardware client never falls back to a simulator. Without ASCENT_CIM_ENDPOINT, construction raises ConfigurationError.
Local execution
from ascent.local import LocalOptimizer
optimizer = LocalOptimizer("qubo", method="exact")
result = optimizer.solve([[-2.0, 0.0], [0.0, -1.0]])
print(result.best_solution, result.best_value)
Supported pairs:
qubo/exactqubo/cim_simulatortsp/acocontinuous/pso
Concrete ACOOptimizer, PSOOptimizer, and CIMSimulator classes remain available from ascent.local.
One-command ant colony solver
After the SDK is installed and activated, run the built-in TSP example directly:
ascent-aco
Use a JSON or CSV distance matrix for your own problem:
ascent-aco --matrix distances.json --ants 50 --iterations 300 --start-city 0
JSON input may be a two-dimensional array or an object with a distance_matrix field. Add
--json when the result will be consumed by another program.
One-command particle swarm solver
Run the default two-dimensional Sphere benchmark:
ascent-pso
Choose an included objective and tune the search space:
ascent-pso --objective rastrigin --dimensions 5 --lower -5.12 --upper 5.12 \
--particles 50 --iterations 300
Available command-line objectives are sphere, rastrigin, and rosenbrock. Python callers can
continue passing any callable objective to LocalOptimizer("continuous", method="pso").
CIM hardware execution
from ascent.cim import CIMOptimizer
optimizer = CIMOptimizer(
task_name="production-qubo",
endpoint="https://your-real-cim-gateway.example/v1",
)
task = optimizer.solve_qubo([[-2.0, 0.0], [0.0, -1.0]])
result = task.wait(timeout=600)
print(result.best_solution, result.best_value, result.cached)
Set ASCENT_CIM_ENDPOINT instead of passing endpoint in application code. The configured service must implement POST /tasks, GET /tasks/{id}, POST /tasks/{id}/cancel, and GET /tasks/{id}/logs.
First-use SDK activation stores an owner-only license at ~/.ascent/license.json. Hardware results are cached under ~/.ascent/cim-cache unless caching is disabled.
Metadata
Release files for ascent-science 0.5.2
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | |
|---|---|---|---|
| ascent_science-0.5.2.tar.gz | 19.6 kB | Details |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Reset |
|---|---|---|---|---|
| ascent_science-0.5.2-py3-none-any.whl | Python 3 | none | any | Details |
Total release size: 42.9 kB
Release files / ascent_science-0.5.2.tar.gz
| Download URL | ascent_science-0.5.2.tar.gz |
|---|---|
| Size | 19.6 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
ac62e3ee6c1da618deed6623264895a32eff6e3617063879906d697fcaba9cd9
|
|
BLAKE2b-256 checksum How to use checksums |
a1e8dc6dc2ab9edb45468d22d0c666dcefa4573a6619bdf2eaacd6400649750f
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/7.0.0 CPython/3.14.3
|
Release files / ascent_science-0.5.2-py3-none-any.whl
| Download URL | ascent_science-0.5.2-py3-none-any.whl |
|---|---|
| Size | 23.2 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
47234f35eb027cf7bedbcb96019d4d18dc1740716ba10cbb709ce38338e7411d
|
|
BLAKE2b-256 checksum How to use checksums |
0ef9da6c2a04088aaa2ad7b00d481600771b5f14e95b528d1d7a2a042014dfeb
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/7.0.0 CPython/3.14.3
|