This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#%% | |
from fastai.tabular import * | |
from fastai.vision import * | |
from fastai.metrics import * | |
def _maybe_add_crop_pad(tfms): | |
assert is_listy(tfms) and len(tfms) == 2, "Please pass a list of two lists of transforms (train and valid)." | |
tfm_names = [[tfm.__name__ for tfm in o] for o in tfms] | |
return [([crop_pad()] + o if 'crop_pad' not in n else o) for o,n in zip(tfms, tfm_names)] |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
using System; | |
using System.Collections.Generic; | |
using System.Linq; | |
using System.Text; | |
namespace System.Linq | |
{ | |
public class KeyEqualityComparer<T> : IEqualityComparer<T> | |
{ | |
private readonly Func<T, T, bool> comparer; |