<jupyter_start><jupyter_text>Large sample simulation  Scalable methodShould run with qubits < 300<jupyter_code>from scalable_class import ScalableEstimate
import numpy as np

scalable = ScalableEstimate(
    qubit_list=np.arange(2, 7),
    optimization_lvl='high',
    error_name='TQ Dep',
    error_list=np.arange(0.001, 0.05, 0.005),
)
scalable.run('avg')
scalable.table('act')
scalable.plot('act')<jupyter_output><empty_output><jupyter_text>Numerical simulationShould run with < 10 qubits<jupyter_code>from numerical_class import NumericalEstimate
import numpy as np

numeric = NumericalEstimate(
    qubit_list=np.arange(2, 7),
    optimization_lvl='high',
    error_name='TQ Dep',
    error_list=np.arange(0.001, 0.05, 0.005),
    ntrials=100
)
numeric.run()
numeric.table('act')
numeric.plot('act')<jupyter_output><empty_output><jupyter_text>Confidence interval comparison<jupyter_code>from confidence_interval_funcs import analyze_confidence_intervals

success, lower, coverage = analyze_confidence_intervals(
    numeric.act_success,
    ns_list=[1, 10, 100],
    nc_list=[100, 200, 300],
    reps=100
)
coverage['bootstrap'][2, 0.001]
coverage['original'][2, 0.001]<jupyter_output><empty_output><jupyter_text>Estimate passing error magnitudesQVEstimate heavy output frequencies must be above and below the specified threshold.<jupyter_code>from utils import passing_error_estimate

scalable_estimate = passing_error_estimate(scalable, 6, threshold=2/3)
numeric_estimate = passing_error_estimate(numeric, 6, threshold=2/3)

print(f'Error magnitude threhsold (scalable) = {scalable_estimate: .6f}')
print(f'Error magnitude threhsold (numeric)  = {numeric_estimate: .6f}')<jupyter_output>Error magnitude threhsold (scalable) =  0.018044
Error magnitude threhsold (numeric)  =  0.018650
{'fraction_non_alphanumeric': 0.11055276381909548, 'fraction_numerical': 0.04690117252931323, 'mean_word_length': 7.0, 'pattern_counts': {'":': 0, '<': 18, '<?xml version=': 0, '>': 16, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'chain_length': '4', 'dir': 'jupyter-structured-clean-dedup', 'id': '355587', 'license': 'Apache-2.0', 'n_tokens_mistral': 680, 'n_tokens_neox': 621, 'n_words': 122, 'path': 'qvt_large_simulations.ipynb', 'repo_name': 'CQCL/qvtsim', 'size': '1791'}