Skip to content

Instantly share code, notes, and snippets.

@riven314
riven314 / lesson1-test-m1.py
Last active October 24, 2022 10:59
sample run lesson1-pets.ipynb to test M1 mac
from fastai.vision.all import *
#from nbdev.showdoc import *
set_seed(2)
bs = 64
path = untar_data(URLs.PETS);
Path.BASE_PATH = path # display all paths relative to dataset root
@riven314
riven314 / process_manager_function.py
Created September 4, 2023 02:27
process_manager_function.py
def process_manager(
self,
trading_pair: str,
timestamp: float,
manager: Union[helper.ShiftOrderManager, helper.OffsetShiftOrderManager],
pending_offset_jobs: helper.PendingOffsetJobs,
) -> None:
manager_name = manager.__class__.__name__
maker_exchange = self.maker_exchange
# skip condition applicable to both manager