@@ -258,7 +258,7 @@ advector = VectorField(pyargs(...
258
258
let periodic = py . import_bound (" PyMPDATA.boundary_conditions" )? . getattr (" Periodic" )? ;
259
259
260
260
let nx_ny = [24 , 24 ];
261
- let Cx_Cy = [- 0.5 , - 0.25 ];
261
+ let cx_cy = [- 0.5 , - 0.25 ];
262
262
let boundary_con = PyTuple :: new_bound (py , [periodic . call0 ()? , periodic . call0 ()? ]). into_any ();
263
263
let halo = options . getattr (" n_halo" )? ;
264
264
@@ -281,7 +281,7 @@ import numpy as np
281
281
nx, ny = {}, {}
282
282
Cx, Cy = {}, {}
283
283
data = (np.full((nx + 1, ny), Cx), np.full((nx, ny + 1), Cy))
284
- " # , nx_ny [0 ], nx_ny [1 ], Cx_Cy [0 ], Cx_Cy [1 ]), None , Some (& full )). unwrap ();
284
+ " # , nx_ny [0 ], nx_ny [1 ], cx_cy [0 ], cx_cy [1 ]), None , Some (& full )). unwrap ();
285
285
let boundary_con = PyTuple :: new_bound (py , [periodic . call0 ()? , periodic . call0 ()? ]). into_any ();
286
286
let advector_arg = vec! [(" data" , full . get_item (" data" )? ), (" halo" , Some (halo . clone ())), (" boundary_conditions" , Some (boundary_con ))]. into_py_dict_bound (py );
287
287
let advector = vector_field . call ((), Some (& advector_arg ))? ;
@@ -365,8 +365,8 @@ stepper = Stepper(pyargs(...
365
365
``` Rust
366
366
let n_dims : i32 = 2 ;
367
367
let stepper_arg = PyDict :: new_bound (py );
368
- PyDictMethods :: set_item (& stepper_arg , " options" , & options );
369
- PyDictMethods :: set_item (& stepper_arg , " n_dims" , & n_dims );
368
+ let _ = PyDictMethods :: set_item (& stepper_arg , " options" , & options );
369
+ let _ = PyDictMethods :: set_item (& stepper_arg , " n_dims" , & n_dims );
370
370
```
371
371
</details >
372
372
@@ -401,10 +401,9 @@ stepper = Stepper(pyargs(...
401
401
<summary >Rust code (click to expand)</summary >
402
402
403
403
``` Rust
404
- let stepper_arg_alternative = vec! [(" options" , & options ), (" grid" , & PyTuple :: new_bound (py , nx_ny ). into_any ())]. into_py_dict_bound (py );
404
+ let _stepper_arg_alternative = vec! [(" options" , & options ), (" grid" , & PyTuple :: new_bound (py , nx_ny ). into_any ())]. into_py_dict_bound (py );
405
405
let stepper_ = py . import_bound (" PyMPDATA" )? . getattr (" Stepper" )? ;
406
- let stepper = stepper_ . call ((), Some (& stepper_arg ))? ;
407
- // or stepper_arg_alternative
406
+ let stepper = stepper_ . call ((), Some (& stepper_arg ))? ; // or use stepper args alternative
408
407
```
409
408
</details >
410
409
0 commit comments