Functions that are used to markup up files with a learner
Imports¶
# def
# def create_probs_df(fnames: List, ) -> DataFrame:
# """
# create a data frame of prob from a `fname` list
# - param fnames:
# - return: `DataFrame`
# """
# list_filedata = [None] * len(fnames)
# for i, fn in enumerate(fnames):
# # img = PIL.Image.open(fn)
# # img_w, img_h = img.size
# list_filedata[i] = {'Name': fn.name, 'Background': '', 'Fluke Liver': '', 'Fluke Rumen': '', 'Other': '', 'Pstr': ''}
#
# df = pd.DataFrame(list_filedata)
# df = df[['Name', 'Background', 'Fluke Liver', 'Fluke Rumen', 'Other', 'Pstr']]
# df.set_index("Name", inplace=True)
# return df
Predictions on tiles¶
Predictions on whole images¶
Dataframe functions¶
Drawing functions¶
Draw text and graphics on an matplotlib image