Randomised battery.

This commit is contained in:
Casper 2019-04-07 03:39:16 +02:00
parent 7d1b4d4537
commit 62e549015e
No known key found for this signature in database
GPG Key ID: 289CA03790535054

View File

@ -1,4 +1,5 @@
import base64
import random
from dataclasses import dataclass, field
from pathlib import Path
from typing import List, Dict
@ -9,7 +10,7 @@ import numpy as np
@dataclass
class Context:
battery: int = 55
battery: int = field(default_factory=lambda: random.randint(0, 100))
position: Dict[str, float] = field(default_factory=lambda: {'latitude': 53.0, 'longitude': 9.0}) # Denmark somewhere
image: np.ndarray = None