Skip to content
This repository was archived by the owner on Sep 11, 2023. It is now read-only.

Commit da14646

Browse files
committed
Merge branch 'issue/add-fake-km-option'
2 parents 42989d5 + 7b09565 commit da14646

File tree

1 file changed

+6
-6
lines changed

1 file changed

+6
-6
lines changed

nowcasting_dataset/data_sources/fake/coordinates.py

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -23,25 +23,25 @@ def make_random_image_coords_osgb(
2323
size: int,
2424
x_center_osgb: Optional = None,
2525
y_center_osgb: Optional = None,
26-
km_spaceing: Optional[int] = 4,
26+
km_spacing: Optional[int] = 4,
2727
):
2828
"""
2929
Make random coords for image. These are ranges for the pixels
3030
3131
Args:
3232
size: The size of the coordinates to make
33-
x_center_osgb: center coord for x (in osgb)
34-
y_center_osgb: center coord for y (in osgb)
35-
km_spaceing: the km spacing between the coordinates.
33+
x_center_osgb: center coordinates for x (in osgb)
34+
y_center_osgb: center coordinates for y (in osgb)
35+
km_spacing: the km spacing between the coordinates.
3636
3737
Returns: X,Y random coordinates [OSGB]
3838
"""
3939

4040
ONE_KILOMETER = 10**3
4141

4242
# 4 kilometer spacing seemed about right for real satellite images
43-
x = km_spaceing * ONE_KILOMETER * np.array((range(0, size)))
44-
y = km_spaceing * ONE_KILOMETER * np.array((range(size, 0, -1)))
43+
x = km_spacing * ONE_KILOMETER * np.array((range(0, size)))
44+
y = km_spacing * ONE_KILOMETER * np.array((range(size, 0, -1)))
4545

4646
return add_uk_centroid_osgb(
4747
x, y, x_center_osgb=x_center_osgb, y_center_osgb=y_center_osgb, first_value_center=False

0 commit comments

Comments
 (0)