Skip to content

Commit

Permalink
remove contaminants and blanks by default
Browse files Browse the repository at this point in the history
  • Loading branch information
pieterprovoost committed Jan 19, 2024
1 parent bbd1fd7 commit 439d434
Showing 1 changed file with 9 additions and 2 deletions.
11 changes: 9 additions & 2 deletions index.py
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,8 @@
OUPUT_FOLDER = "output"
# TODO: read contaminants from JSON
CONTAMINANTS = ["Homo", "Sus", "Gallus", "Canis", "Bos", "Felis", "Ovis", "Mus", "Vulpes", "Rattus", "Capra", "Rangifer"]
REMOVE_CONTAMINANTS = False
REMOVE_CONTAMINANTS = True
REMOVE_BLANK = True


def download_results() -> None:
Expand Down Expand Up @@ -105,9 +106,15 @@ def derive_marker_name(input: str) -> str:
"decimalLongitude": sample["area_longitude"],
"decimalLatitude": sample["area_latitude"],
"sampleSize": sample["size"],
"higherGeography": sample["parent_area_name"]
"higherGeography": sample["parent_area_name"],
"blank": sample["blank"]
} for sample in metadata["samples"]])

if REMOVE_BLANK:
metadata_df = metadata_df[metadata_df["blank"] == False]

metadata_df = metadata_df.drop(columns=["blank"])

# organize data folders by site

dataset_folders = list_datasets()
Expand Down

0 comments on commit 439d434

Please sign in to comment.