Skip to content
Extraits de code Groupes Projets
Valider 287a7135 rédigé par Adrien Payen's avatar Adrien Payen
Parcourir les fichiers

tmc update

parent b99d7af9
Aucune branche associée trouvée
Aucune étiquette associée trouvée
Aucune requête de fusion associée trouvée
...@@ -175,7 +175,7 @@ class TransitionMatrixCalculator: ...@@ -175,7 +175,7 @@ class TransitionMatrixCalculator:
k_prime = k + s k_prime = k + s
k_prime = k_prime % 15 if circle else min(14, k_prime) k_prime = k_prime % 15 if circle else min(14, k_prime)
if layout[k_prime] in [1, 2, 4]: if layout[k_prime] in [1, 2]:
if layout[k_prime] == 1: if layout[k_prime] == 1:
k_prime = 0 k_prime = 0
self.matrix_risky[k,k_prime] += p self.matrix_risky[k,k_prime] += p
...@@ -204,10 +204,10 @@ class TransitionMatrixCalculator: ...@@ -204,10 +204,10 @@ class TransitionMatrixCalculator:
array = np.zeros(15, dtype=int) array = np.zeros(15, dtype=int)
# Generate 3 random indices between 1 and 13 (exclusive) # Generate 3 random indices between 1 and 13 (exclusive)
indices = rd.sample(range(1, 14), 4) indices = rd.sample(range(1, 14), 3)
# Assign the values 1, 2 and 3 to the randomly generated indices # Assign the values 1, 2 and 3 to the randomly generated indices
array[indices] = 1, 2, 3,4 array[indices] = 1, 2, 3
# Append the generated array to the list # Append the generated array to the list
arrays.append(array) arrays.append(array)
......
0% Chargement en cours ou .
You are about to add 0 people to the discussion. Proceed with caution.
Terminez d'abord l'édition de ce message.
Veuillez vous inscrire ou vous pour commenter