Skip to content

Commit da5ddec

Browse files
authored
[All] fix some language typos (PR 3) (#1757)
1 parent 192eae3 commit da5ddec

32 files changed

Lines changed: 143 additions & 143 deletions

File tree

buildbot/check_sycl_include.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -37,7 +37,7 @@ def write_file(fname, source):
3737
f.close()
3838

3939

40-
def should_corect(source):
40+
def should_correct(source):
4141
if "#include <hipSYCL" in source:
4242
return True
4343

@@ -53,7 +53,7 @@ def autocorrect(source):
5353
if should_check_file(fname):
5454
source = load_file(fname)
5555

56-
if should_corect(source):
56+
if should_correct(source):
5757
if not has_found_errors:
5858
print(" => \033[1;34mNon standard SYCL #include found \033[0;0m: ")
5959
print("The check found so instances of sycl inclusion using non standard headers")

buildbot/lib/make_report.py

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -222,7 +222,7 @@ def make_tex_report(dat):
222222

223223
dic_int["world size = " + str(wsz)][dat[config_k]["description"]] = {
224224
"results": dic_res,
225-
"succes_cnt": dic_suc_cnt,
225+
"success_cnt": dic_suc_cnt,
226226
"global_suc_cnt": cnt_succes,
227227
"global_test_cnt": cnt_test,
228228
}
@@ -329,9 +329,9 @@ def make_tex_report(dat):
329329
\hline
330330
Test name & Status & Successful asserts / total number of asserts \\ \hline \hline
331331
"""
332-
for ktest in dic_int[kworldsz][kconfig]["succes_cnt"].keys():
333-
assert_suc_cnt = dic_int[kworldsz][kconfig]["succes_cnt"][ktest]["suc_cnt"]
334-
assert_cnt = dic_int[kworldsz][kconfig]["succes_cnt"][ktest]["assert_cnt"]
332+
for ktest in dic_int[kworldsz][kconfig]["success_cnt"].keys():
333+
assert_suc_cnt = dic_int[kworldsz][kconfig]["success_cnt"][ktest]["suc_cnt"]
334+
assert_cnt = dic_int[kworldsz][kconfig]["success_cnt"][ktest]["assert_cnt"]
335335

336336
succes = assert_suc_cnt == assert_cnt
337337

examples/TO_MIGRATE/ramses/godunov_dusty_wave_test.py

Lines changed: 26 additions & 26 deletions
Original file line numberDiff line numberDiff line change
@@ -100,7 +100,7 @@ def run_sim(times, x0, normalized_rd_num, normalized_rg_num, normalized_vd_num,
100100

101101
# ================= Fields maps =========================
102102

103-
def pertubation(x, A, Re, Im, L) -> float:
103+
def perturbation(x, A, Re, Im, L) -> float:
104104
return A * (Re * cos(2 * x * pi / L) - Im * sin(2 * x * pi / L))
105105

106106
"""
@@ -123,28 +123,28 @@ def pertubation(x, A, Re, Im, L) -> float:
123123
### Gas maps
124124
def rho_map(rmin,rmax)->float:
125125
x,y,z = rmin
126-
return rhog_0 + pertubation(x,A_rho,Re_rho,Im_rho,L)
126+
return rhog_0 + perturbation(x,A_rho,Re_rho,Im_rho,L)
127127
def rhovel_map(rmin, rmax)->tuple[float,float,float]:
128128
x,y,z = rmin
129-
rho = rhog_0 + pertubation(x,A_rho,Re_rho,Im_rho,L)
130-
vx = pertubation(x,A_vel,Re_vel,Im_vel,L)
129+
rho = rhog_0 + perturbation(x,A_rho,Re_rho,Im_rho,L)
130+
vx = perturbation(x,A_vel,Re_vel,Im_vel,L)
131131
return (rho*vx, 0, 0)
132132
def rhoe_map (rmin, rmax)->float:
133133
x,y,z = rmin
134-
rho = rhog_0 + pertubation(x,A_rho,Re_rho,Im_rho,L)
135-
vx = pertubation(x,A_vel,Re_vel,Im_vel,L)
134+
rho = rhog_0 + perturbation(x,A_rho,Re_rho,Im_rho,L)
135+
vx = perturbation(x,A_vel,Re_vel,Im_vel,L)
136136
press = (cs * cs * rho) / gamma
137137
rhoeint = press / (gamma - 1.0)
138138
rhoekin = 0.5 * rho * (vx *vx + 0.0)
139139
return (rhoeint + rhoekin)
140140
### Dust maps
141141
def rho_d_map(rmin,rmax)->float:
142142
x,y,z = rmin
143-
return rhod_0 + pertubation(x,A_rho,Re_rd,Im_rd,L)
143+
return rhod_0 + perturbation(x,A_rho,Re_rd,Im_rd,L)
144144
def rhovel_d_map(rmin, rmax)->tuple[float,float,float]:
145145
x,y,z = rmin
146-
rho = rhod_0 + pertubation(x,A_rho,Re_rd,Im_rd,L)
147-
vx = pertubation(x,A_vel,Re_vd,Im_vd,L)
146+
rho = rhod_0 + perturbation(x,A_rho,Re_rd,Im_rd,L)
147+
vx = perturbation(x,A_vel,Re_vd,Im_vd,L)
148148
return (rho*vx, 0, 0)"""
149149

150150
## 5 fluids test setup
@@ -188,18 +188,18 @@ def rhovel_d_map(rmin, rmax)->tuple[float,float,float]:
188188
### Gas maps
189189
def rho_map(rmin, rmax) -> float:
190190
x, y, z = rmin
191-
return rhog_0 + pertubation(x, A_rho, Re_rho, Im_rho, L)
191+
return rhog_0 + perturbation(x, A_rho, Re_rho, Im_rho, L)
192192

193193
def rhovel_map(rmin, rmax) -> tuple[float, float, float]:
194194
x, y, z = rmin
195-
rho = rhog_0 + pertubation(x, A_rho, Re_rho, Im_rho, L)
196-
vx = pertubation(x, A_vel, Re_vel, Im_vel, L)
195+
rho = rhog_0 + perturbation(x, A_rho, Re_rho, Im_rho, L)
196+
vx = perturbation(x, A_vel, Re_vel, Im_vel, L)
197197
return (rho * vx, 0, 0)
198198

199199
def rhoe_map(rmin, rmax) -> float:
200200
x, y, z = rmin
201-
rho = rhog_0 + pertubation(x, A_rho, Re_rho, Im_rho, L)
202-
vx = pertubation(x, A_vel, Re_vel, Im_vel, L)
201+
rho = rhog_0 + perturbation(x, A_rho, Re_rho, Im_rho, L)
202+
vx = perturbation(x, A_vel, Re_vel, Im_vel, L)
203203
press = (cs * cs * rho) / gamma
204204
rhoeint = press / (gamma - 1.0)
205205
rhoekin = 0.5 * rho * (vx * vx + 0.0)
@@ -209,42 +209,42 @@ def rhoe_map(rmin, rmax) -> float:
209209

210210
def rho_d_1_map(rmin, rmax) -> float:
211211
x, y, z = rmin
212-
return rhod_1 + pertubation(x, A_rho, Re_rd_1, Im_rd_1, L)
212+
return rhod_1 + perturbation(x, A_rho, Re_rd_1, Im_rd_1, L)
213213

214214
def rhovel_d_1_map(rmin, rmax) -> tuple[float, float, float]:
215215
x, y, z = rmin
216-
rho = rhod_1 + pertubation(x, A_rho, Re_rd_1, Im_rd_1, L)
217-
vx = pertubation(x, A_vel, Re_vd_1, Im_vd_1, L)
216+
rho = rhod_1 + perturbation(x, A_rho, Re_rd_1, Im_rd_1, L)
217+
vx = perturbation(x, A_vel, Re_vd_1, Im_vd_1, L)
218218
return (rho * vx, 0, 0)
219219

220220
def rho_d_2_map(rmin, rmax) -> float:
221221
x, y, z = rmin
222-
return rhod_2 + pertubation(x, A_rho, Re_rd_2, Im_rd_2, L)
222+
return rhod_2 + perturbation(x, A_rho, Re_rd_2, Im_rd_2, L)
223223

224224
def rhovel_d_2_map(rmin, rmax) -> tuple[float, float, float]:
225225
x, y, z = rmin
226-
rho = rhod_2 + pertubation(x, A_rho, Re_rd_2, Im_rd_2, L)
227-
vx = pertubation(x, A_vel, Re_vd_2, Im_vd_2, L)
226+
rho = rhod_2 + perturbation(x, A_rho, Re_rd_2, Im_rd_2, L)
227+
vx = perturbation(x, A_vel, Re_vd_2, Im_vd_2, L)
228228
return (rho * vx, 0, 0)
229229

230230
def rho_d_3_map(rmin, rmax) -> float:
231231
x, y, z = rmin
232-
return rhod_3 + pertubation(x, A_rho, Re_rd_3, Im_rd_3, L)
232+
return rhod_3 + perturbation(x, A_rho, Re_rd_3, Im_rd_3, L)
233233

234234
def rhovel_d_3_map(rmin, rmax) -> tuple[float, float, float]:
235235
x, y, z = rmin
236-
rho = rhod_3 + pertubation(x, A_rho, Re_rd_3, Im_rd_3, L)
237-
vx = pertubation(x, A_vel, Re_vd_3, Im_vd_3, L)
236+
rho = rhod_3 + perturbation(x, A_rho, Re_rd_3, Im_rd_3, L)
237+
vx = perturbation(x, A_vel, Re_vd_3, Im_vd_3, L)
238238
return (rho * vx, 0, 0)
239239

240240
def rho_d_4_map(rmin, rmax) -> float:
241241
x, y, z = rmin
242-
return rhod_4 + pertubation(x, A_rho, Re_rd_4, Im_rd_4, L)
242+
return rhod_4 + perturbation(x, A_rho, Re_rd_4, Im_rd_4, L)
243243

244244
def rhovel_d_4_map(rmin, rmax) -> tuple[float, float, float]:
245245
x, y, z = rmin
246-
rho = rhod_4 + pertubation(x, A_rho, Re_rd_4, Im_rd_4, L)
247-
vx = pertubation(x, A_vel, Re_vd_4, Im_vd_4, L)
246+
rho = rhod_4 + perturbation(x, A_rho, Re_rd_4, Im_rd_4, L)
247+
vx = perturbation(x, A_vel, Re_vd_4, Im_vd_4, L)
248248
return (rho * vx, 0, 0)
249249

250250
# ============ set init fields values for gas =============

examples/tests_ci/dustywave_godunov.py

Lines changed: 26 additions & 26 deletions
Original file line numberDiff line numberDiff line change
@@ -51,7 +51,7 @@ def run_sim(times, x0, normalized_rd_num, normalized_rg_num, normalized_vd_num,
5151

5252
# ================= Fields maps =========================
5353

54-
def pertubation(x, A, Re, Im, L):
54+
def perturbation(x, A, Re, Im, L):
5555
return A * (Re * cos(2 * x * pi / L) - Im * sin(2 * x * pi / L))
5656

5757
""" ## 2 fluids test setup
@@ -73,28 +73,28 @@ def pertubation(x, A, Re, Im, L):
7373
### Gas maps
7474
def rho_map(rmin,rmax)->float:
7575
x,y,z = rmin
76-
return rhog_0 + pertubation(x,A_rho,Re_rho,Im_rho,L)
76+
return rhog_0 + perturbation(x,A_rho,Re_rho,Im_rho,L)
7777
def rhovel_map(rmin, rmax)->tuple[float,float,float]:
7878
x,y,z = rmin
79-
rho = rhog_0 + pertubation(x,A_rho,Re_rho,Im_rho,L)
80-
vx = pertubation(x,A_vel,Re_vel,Im_vel,L)
79+
rho = rhog_0 + perturbation(x,A_rho,Re_rho,Im_rho,L)
80+
vx = perturbation(x,A_vel,Re_vel,Im_vel,L)
8181
return (rho*vx, 0, 0)
8282
def rhoe_map (rmin, rmax)->float:
8383
x,y,z = rmin
84-
rho = rhog_0 + pertubation(x,A_rho,Re_rho,Im_rho,L)
85-
vx = pertubation(x,A_vel,Re_vel,Im_vel,L)
84+
rho = rhog_0 + perturbation(x,A_rho,Re_rho,Im_rho,L)
85+
vx = perturbation(x,A_vel,Re_vel,Im_vel,L)
8686
press = (cs * cs * rho) / gamma
8787
rhoeint = press / (gamma - 1.0)
8888
rhoekin = 0.5 * rho * (vx *vx + 0.0)
8989
return (rhoeint + rhoekin)
9090
### Dust maps
9191
def rho_d_map(rmin,rmax)->float:
9292
x,y,z = rmin
93-
return rhod_0 + pertubation(x,A_rho,Re_rd,Im_rd,L)
93+
return rhod_0 + perturbation(x,A_rho,Re_rd,Im_rd,L)
9494
def rhovel_d_map(rmin, rmax)->tuple[float,float,float]:
9595
x,y,z = rmin
96-
rho = rhod_0 + pertubation(x,A_rho,Re_rd,Im_rd,L)
97-
vx = pertubation(x,A_vel,Re_vd,Im_vd,L)
96+
rho = rhod_0 + perturbation(x,A_rho,Re_rd,Im_rd,L)
97+
vx = perturbation(x,A_vel,Re_vd,Im_vd,L)
9898
return (rho*vx, 0, 0)"""
9999

100100
## 5 fluids test setup
@@ -138,18 +138,18 @@ def rhovel_d_map(rmin, rmax)->tuple[float,float,float]:
138138
### Gas maps
139139
def rho_map(rmin, rmax):
140140
x, y, z = rmin
141-
return rhog_0 + pertubation(x, A_rho, Re_rho, Im_rho, L)
141+
return rhog_0 + perturbation(x, A_rho, Re_rho, Im_rho, L)
142142

143143
def rhovel_map(rmin, rmax):
144144
x, y, z = rmin
145-
rho = rhog_0 + pertubation(x, A_rho, Re_rho, Im_rho, L)
146-
vx = pertubation(x, A_vel, Re_vel, Im_vel, L)
145+
rho = rhog_0 + perturbation(x, A_rho, Re_rho, Im_rho, L)
146+
vx = perturbation(x, A_vel, Re_vel, Im_vel, L)
147147
return (rho * vx, 0, 0)
148148

149149
def rhoe_map(rmin, rmax):
150150
x, y, z = rmin
151-
rho = rhog_0 + pertubation(x, A_rho, Re_rho, Im_rho, L)
152-
vx = pertubation(x, A_vel, Re_vel, Im_vel, L)
151+
rho = rhog_0 + perturbation(x, A_rho, Re_rho, Im_rho, L)
152+
vx = perturbation(x, A_vel, Re_vel, Im_vel, L)
153153
press = (cs * cs * rho) / gamma
154154
rhoeint = press / (gamma - 1.0)
155155
rhoekin = 0.5 * rho * (vx * vx + 0.0)
@@ -159,42 +159,42 @@ def rhoe_map(rmin, rmax):
159159

160160
def rho_d_1_map(rmin, rmax):
161161
x, y, z = rmin
162-
return rhod_1 + pertubation(x, A_rho, Re_rd_1, Im_rd_1, L)
162+
return rhod_1 + perturbation(x, A_rho, Re_rd_1, Im_rd_1, L)
163163

164164
def rhovel_d_1_map(rmin, rmax):
165165
x, y, z = rmin
166-
rho = rhod_1 + pertubation(x, A_rho, Re_rd_1, Im_rd_1, L)
167-
vx = pertubation(x, A_vel, Re_vd_1, Im_vd_1, L)
166+
rho = rhod_1 + perturbation(x, A_rho, Re_rd_1, Im_rd_1, L)
167+
vx = perturbation(x, A_vel, Re_vd_1, Im_vd_1, L)
168168
return (rho * vx, 0, 0)
169169

170170
def rho_d_2_map(rmin, rmax):
171171
x, y, z = rmin
172-
return rhod_2 + pertubation(x, A_rho, Re_rd_2, Im_rd_2, L)
172+
return rhod_2 + perturbation(x, A_rho, Re_rd_2, Im_rd_2, L)
173173

174174
def rhovel_d_2_map(rmin, rmax):
175175
x, y, z = rmin
176-
rho = rhod_2 + pertubation(x, A_rho, Re_rd_2, Im_rd_2, L)
177-
vx = pertubation(x, A_vel, Re_vd_2, Im_vd_2, L)
176+
rho = rhod_2 + perturbation(x, A_rho, Re_rd_2, Im_rd_2, L)
177+
vx = perturbation(x, A_vel, Re_vd_2, Im_vd_2, L)
178178
return (rho * vx, 0, 0)
179179

180180
def rho_d_3_map(rmin, rmax):
181181
x, y, z = rmin
182-
return rhod_3 + pertubation(x, A_rho, Re_rd_3, Im_rd_3, L)
182+
return rhod_3 + perturbation(x, A_rho, Re_rd_3, Im_rd_3, L)
183183

184184
def rhovel_d_3_map(rmin, rmax):
185185
x, y, z = rmin
186-
rho = rhod_3 + pertubation(x, A_rho, Re_rd_3, Im_rd_3, L)
187-
vx = pertubation(x, A_vel, Re_vd_3, Im_vd_3, L)
186+
rho = rhod_3 + perturbation(x, A_rho, Re_rd_3, Im_rd_3, L)
187+
vx = perturbation(x, A_vel, Re_vd_3, Im_vd_3, L)
188188
return (rho * vx, 0, 0)
189189

190190
def rho_d_4_map(rmin, rmax):
191191
x, y, z = rmin
192-
return rhod_4 + pertubation(x, A_rho, Re_rd_4, Im_rd_4, L)
192+
return rhod_4 + perturbation(x, A_rho, Re_rd_4, Im_rd_4, L)
193193

194194
def rhovel_d_4_map(rmin, rmax):
195195
x, y, z = rmin
196-
rho = rhod_4 + pertubation(x, A_rho, Re_rd_4, Im_rd_4, L)
197-
vx = pertubation(x, A_vel, Re_vd_4, Im_vd_4, L)
196+
rho = rhod_4 + perturbation(x, A_rho, Re_rd_4, Im_rd_4, L)
197+
vx = perturbation(x, A_vel, Re_vd_4, Im_vd_4, L)
198198
return (rho * vx, 0, 0)
199199

200200
# ============ set init fields values for gas =============

src/shamalgs/include/shamalgs/atomic/DynamicIdGenerator.hpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -29,7 +29,7 @@ namespace shamalgs::atomic {
2929
* e.g. worker group 2 can not start if worker group 1 is not started
3030
* The performance overhead is minimal (10^-11 s/element on A100)
3131
*
32-
* \todo add figure for overhead measurment
32+
* \todo add figure for overhead measurement
3333
*
3434
* Example :
3535
*

src/shamalgs/include/shamalgs/collective/InvariantParallelGenerator.hpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -23,7 +23,7 @@
2323

2424
namespace shamalgs::collective {
2525

26-
/// A parralel generator that will spit the same sequence regardless of the number of ranks.
26+
/// A parallel generator that will spit the same sequence regardless of the number of ranks.
2727
template<class Engine = std::mt19937_64>
2828
class InvariantParallelGenerator {
2929
Engine eng_global;

src/shamalgs/include/shamalgs/collective/exchanges.hpp

Lines changed: 15 additions & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -58,34 +58,34 @@ namespace shamalgs::collective {
5858
// printf("table_data_count =
5959
// [%d,%d,%d,%d]\n",table_data_count[0],table_data_count[1],table_data_count[2],table_data_count[3]);
6060

61-
int *node_displacments_data_table = new int[shamcomm::world_size()];
61+
int *node_displacements_data_table = new int[shamcomm::world_size()];
6262

63-
node_displacments_data_table[0] = 0;
63+
node_displacements_data_table[0] = 0;
6464

6565
for (u32 i = 1; i < shamcomm::world_size(); i++) {
66-
node_displacments_data_table[i]
67-
= node_displacments_data_table[i - 1] + table_data_count[i - 1];
66+
node_displacements_data_table[i]
67+
= node_displacements_data_table[i - 1] + table_data_count[i - 1];
6868
}
6969

70-
// printf("node_displacments_data_table =
71-
// [%d,%d,%d,%d]\n",node_displacments_data_table[0],node_displacments_data_table[1],node_displacments_data_table[2],node_displacments_data_table[3]);
70+
// printf("node_displacements_data_table =
71+
// [%d,%d,%d,%d]\n",node_displacements_data_table[0],node_displacements_data_table[1],node_displacements_data_table[2],node_displacements_data_table[3]);
7272

7373
shamcomm::mpi::Allgatherv(
7474
&send_vec[0],
7575
send_vec.size(),
7676
send_type,
7777
&recv_vec[0],
7878
table_data_count,
79-
node_displacments_data_table,
79+
node_displacements_data_table,
8080
recv_type,
8181
comm);
8282

8383
delete[] table_data_count;
84-
delete[] node_displacments_data_table;
84+
delete[] node_displacements_data_table;
8585
}
8686

8787
/**
88-
* @brief allgatherv on vector with size query (size querrying variant of vector_allgatherv_ks)
88+
* @brief allgatherv on vector with size query (size querying variant of vector_allgatherv_ks)
8989
* //TODO add fault tolerance
9090
* @tparam T
9191
* @param send_vec
@@ -121,15 +121,15 @@ namespace shamalgs::collective {
121121
int global_len = 0;
122122
// use work duplication or MPI reduction
123123
#if false
124-
// querry global size and resize the receiving vector
124+
// query global size and resize the receiving vector
125125
shamcomm::mpi::Allreduce(
126126
&local_count, &global_len, 1, MPI_INT, MPI_SUM, comm);
127127
#else
128128
{
129129
u64 tmp = std::accumulate(table_data_count.begin(), table_data_count.end(), 0_u64);
130130

131131
// if it exceeds the max size of int, MPI will trip like crazy
132-
// god damn it just implement 64bits indicies ... Pleeeeeasssssse !!!
132+
// god damn it just implement 64bits indices ... Pleeeeeasssssse !!!
133133
global_len = shambase::narrow_or_throw<int>(tmp);
134134
}
135135
#endif
@@ -141,11 +141,11 @@ namespace shamalgs::collective {
141141
}
142142

143143
// here we can not overflow since we know that the sum can be narrowed to an int
144-
std::vector<int> node_displacments_data_table(static_cast<std::size_t>(comm_size));
144+
std::vector<int> node_displacements_data_table(static_cast<std::size_t>(comm_size));
145145
std::exclusive_scan(
146146
table_data_count.begin(),
147147
table_data_count.end(),
148-
node_displacments_data_table.begin(),
148+
node_displacements_data_table.begin(),
149149
0);
150150

151151
shamcomm::mpi::Allgatherv(
@@ -154,11 +154,11 @@ namespace shamalgs::collective {
154154
send_type,
155155
recv_vec.data(),
156156
table_data_count.data(),
157-
node_displacments_data_table.data(),
157+
node_displacements_data_table.data(),
158158
recv_type,
159159
comm);
160160

161-
return node_displacments_data_table;
161+
return node_displacements_data_table;
162162
}
163163

164164
/**

0 commit comments

Comments
 (0)