Skip to content

Commit

Permalink
finer grid
Browse files Browse the repository at this point in the history
  • Loading branch information
meandmytram committed Dec 6, 2024
1 parent 188dbbf commit 84ddb75
Showing 1 changed file with 24 additions and 13 deletions.
37 changes: 24 additions & 13 deletions examples/decoding/quantum_surface.sh
Original file line number Diff line number Diff line change
Expand Up @@ -14,21 +14,32 @@ pip install --no-index --upgrade pip
pip install --no-index numpy scipy opt_einsum tqdm qecstruct more_itertools networkx matrex@git+https://github.com/quicophy/matrex

# Define arrays of lattice sizes, bond dimensions, error rates, and seeds
lattice_sizes=(3 5 7 9 11)
bond_dims=(64 128 256)
seeds=(123 124 125 126) # 4 random seeds
num_experiments=25 # Per each random seed
lattice_sizes=(13)
bond_dims=(256)
seeds=(
123 124 125 126 127 128 129 130 131 132
133 134 135 136 137 138 139 140 141 142
143 144 145 146 147 148 149 150 151 152
153 154 155 156 157 158 159 160 161 162
163 164 165 166 167 168 169 170 171 172
173 174 175 176 177 178 179 180 181 182
183 184 185 186 187 188 189 190 191 192
193 194 195 196 197 198 199 200 201 202
203 204 205 206 207 208 209 210 211 212
213 214 215 216 217 218 219 220 221 222
) # 100 random seeds
num_experiments=10 # Per each random seed
error_model="Bit Flip" # Error model used in the experiments

error_rates=()
start=0.05
end=0.15
num_points=11
step=$(echo "($end - $start) / ($num_points - 1)" | bc -l)
for ((i=0; i<$num_points; i++))
start=0.105
end=0.115
step=0.001
current=$start
while (( $(echo "$current <= $end" | bc -l) ))
do
value=$(echo "$start + $i * $step" | bc -l)
error_rates+=($value)
error_rates+=($current)
current=$(echo "$current + $step" | bc -l)
done

# Create job submission scripts by iterating over combinations of the arguments
Expand All @@ -43,9 +54,9 @@ for seed in "${seeds[@]}"; do
# Create the job submission script
cat > "$job_script" <<EOS
#!/bin/bash
#SBATCH --time=24:00:00 # Time limit (hh:mm:ss)
#SBATCH --time=48:00:00 # Time limit (hh:mm:ss)
#SBATCH --cpus-per-task=1 # Number of CPU cores per task
#SBATCH --mem=32000 # Memory per node
#SBATCH --mem=64000 # Memory per node
#SBATCH --job-name=decoding-${lattice_size}-${bond_dim}-${error_rate}-${sanitized_error_model}-${seed} # Descriptive job name
#SBATCH --output=decoding-${lattice_size}-${bond_dim}-${error_rate}-${sanitized_error_model}-${seed}-%j.out # Standard output and error log
Expand Down

0 comments on commit 84ddb75

Please sign in to comment.