diff --git a/decimer_segmentation/decimer_segmentation.py b/decimer_segmentation/decimer_segmentation.py index c6ceb6c..f65b317 100644 --- a/decimer_segmentation/decimer_segmentation.py +++ b/decimer_segmentation/decimer_segmentation.py @@ -205,7 +205,7 @@ def load_model() -> modellib.MaskRCNN: # Download trained weights if needed if not os.path.exists(model_path): print("Downloading model weights...") - url = "https://zenodo.org/records/10142866/files/mask_rcnn_molecule.h5?download=1" + url = "https://zenodo.org/record/10663579/files/mask_rcnn_molecule.h5?download=1" req = requests.get(url, allow_redirects=True) with open(model_path, "wb") as model_file: model_file.write(req.content) diff --git a/tests/test_mask_expansion.py b/tests/test_mask_expansion.py index 3c8b64a..02f6e85 100644 --- a/tests/test_mask_expansion.py +++ b/tests/test_mask_expansion.py @@ -1,4 +1,5 @@ import numpy as np + from decimer_segmentation.complete_structure import ( binarize_image, get_seeds, @@ -7,7 +8,6 @@ detect_horizontal_and_vertical_lines, ) - def test_binarize_image(): test_image_array = np.array([[255, 255, 255],[0, 0, 0],[255, 255, 255]]) test_threshold = "otsu" @@ -15,7 +15,6 @@ def test_binarize_image(): actual_result = binarize_image(test_image_array, test_threshold) assert np.array_equal(expected_result, actual_result) - def test_get_seeds(): test_image_array = np.array([[0, 1, 0],[1, 0, 1],[0, 1, 0]]) test_mask_array = np.ones(test_image_array.shape) @@ -25,7 +24,6 @@ def test_get_seeds(): for index in range(len(expected_result)): assert expected_result[index] == actual_result[index] - def test_expand_masks(): test_image_array = np.array([(False, False, True, True, True)]) test_seed_pixels = [(2, 0)]