File size: 1,311 Bytes
8685a5b efbb268 8685a5b 46f38e3 8685a5b a0fc244 025b651 882df3c 8685a5b | 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 | #!/usr/bin/env python3
# -*- coding: utf-8 -*-
"""
Entry point for application:
runs numerical experiment to verify Choi-Cholesky decomposition of CP(TP)-maps.
"""
# ----------------------------------------------------------------
# IMPORTS
# ----------------------------------------------------------------
import os
import sys
from pathlib import Path
os.chdir(Path(__file__).parent.parent.as_posix())
sys.path.insert(0, os.getcwd())
from .choi_cholesky._core.logging import *
from .choi_cholesky.experiments.choi_cholesky import *
from .choi_cholesky.queries._console.prog_examples import *
from .choi_cholesky.setup import *
# ----------------------------------------------------------------
# EXECUTION
# ----------------------------------------------------------------
if __name__ == "__main__":
# set sessions settings
sys.tracebacklimit = 0
# parse cli flags
args = CliArguments(info=INFO).parse(*sys.argv[1:])
# early terminate if only version requested
if args.mode == "version":
print(VERSION)
exit(0)
# set up logging
configure_logging()
# execute main method
verify_choi_cholesky(
d1=args.dim1,
d2=args.dim2,
n=args.num,
map=args.map,
algorithm=args.algorithm,
seed=args.seed,
)
|