|
5 | 5 | @author: Anna Grim |
6 | 6 | |
7 | 7 |
|
8 | | -
|
9 | 8 | Code for helper routines. |
10 | 9 |
|
11 | 10 | """ |
@@ -35,7 +34,7 @@ def mkdir(path, delete=False): |
35 | 34 | Path of directory to be created. |
36 | 35 | delete : bool, optional |
37 | 36 | Indication of whether to delete directory at path if it already |
38 | | - exists. The default is False. |
| 37 | + exists. Default is False. |
39 | 38 | """ |
40 | 39 | if delete: |
41 | 40 | rmdir(path) |
@@ -66,7 +65,7 @@ def list_dir(directory, extension=None): |
66 | 65 | directory : str |
67 | 66 | Path to directory to be searched. |
68 | 67 | extension : str, optional |
69 | | - Extension of filenames to be returned. The default is None. |
| 68 | + Extension of filenames to be returned. Default is None. |
70 | 69 |
|
71 | 70 | Returns |
72 | 71 | ------- |
@@ -116,7 +115,6 @@ def read_zip(zip_file, path): |
116 | 115 | ------- |
117 | 116 | str |
118 | 117 | Contents of a TXT file. |
119 | | -
|
120 | 118 | """ |
121 | 119 | with zip_file.open(path) as f: |
122 | 120 | return f.read().decode("utf-8") |
@@ -208,7 +206,7 @@ def list_gcs_filenames(bucket_name, prefix, extension): |
208 | 206 | Returns |
209 | 207 | ------- |
210 | 208 | List[str] |
211 | | - Filenames stored at "cloud" path with the given extension. |
| 209 | + Filenames stored at the GCS path with the given extension. |
212 | 210 | """ |
213 | 211 | bucket = storage.Client().bucket(bucket_name) |
214 | 212 | blobs = bucket.list_blobs(prefix=prefix) |
@@ -438,6 +436,8 @@ def kdtree_query(kdtree, xyz): |
438 | 436 |
|
439 | 437 | Parameters |
440 | 438 | ---------- |
| 439 | + kdtree : scipy.spatial.KDTree |
| 440 | + KD-Tree to be searched. |
441 | 441 | xyz : ArrayLike |
442 | 442 | Coordinate to be queried. |
443 | 443 |
|
@@ -501,3 +501,4 @@ def save_results(path, stats): |
501 | 501 | sheet.write(i + 1, j + 1, round(stats[swc_id][metric], 4)) |
502 | 502 |
|
503 | 503 | wb.save(path) |
| 504 | + |
0 commit comments