提交 9c2a4b23 编写于 作者: P Pavol Mulinka

LDS tested - working

上级 e5116ff2
......@@ -73,7 +73,6 @@ class WideDeepDataset(Dataset):
]
else:
self.transforms_names = []
self.weights = self._prepare_weights(reweight=reweight, lds=lds, lds_kernel=lds_kernel, lds_ks=lds_ks, lds_sigma=lds_sigma)
self.Y = target
if self.Y is not None:
if Ymax is None:
......@@ -124,7 +123,6 @@ class WideDeepDataset(Dataset):
# fill the Bunch
X.deepimage = xdi
if self.Y is not None:
weight = np.asarray([self.weights[idx]]).astype("float32") if self.weights is not None else self.weights
y = self.Y[idx]
if self.reweight != None:
weight = np.asarray([self.weights[idx]]).astype("float32")
......
......@@ -636,7 +636,7 @@ class Trainer:
self.callback_container.on_eval_begin()
self.valid_running_loss = 0.0
with trange(eval_steps, disable=self.verbose != 1) as v:
for i, (data, targett, weight) in zip(v, eval_loader):
for i, (data, targett) in zip(v, eval_loader):
v.set_description("valid")
val_score, val_loss = self._eval_step(data, targett, i)
print_loss_and_metric(v, val_loss, val_score)
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册