Skip to content

Commit

Permalink
Add sampling date
Browse files Browse the repository at this point in the history
  • Loading branch information
tanghaibao committed May 14, 2024
1 parent 255fbc1 commit 2160b24
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion jcvi/graphics/grabseeds.py
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,7 @@
import sys

from collections import Counter
from datetime import date
from math import cos, pi, sin
from typing import Any, List, Optional, Tuple

Expand Down Expand Up @@ -91,7 +92,7 @@ def __init__(
self.circularity = 4 * pi * props.area / props.perimeter**2
self.rgb = rgb
self.colorname = closest_color(rgb)
self.datetime = exif.get("exif:DateTimeOriginal", "none")
self.datetime = exif.get("exif:DateTimeOriginal", date.today())
self.rgbtag = triplet_to_rgb(rgb)
self.pixeltag = f"length={self.length} width={self.width} area={self.area}"
self.hashtag = " ".join((self.rgbtag, self.colorname))
Expand Down

0 comments on commit 2160b24

Please sign in to comment.