Commit 7e64f720 authored by Peter Eastman's avatar Peter Eastman
Browse files

Bug fixes

parent dd81dbfe
Loading
Loading
Loading
Loading
+2 −2
Original line number Diff line number Diff line
@@ -97,7 +97,7 @@
    "    dc.metrics.roc_auc_score, np.mean, mode=\"classification\")\n",
    "\n",
    "nb_epoch = 10\n",
    "model = dc.models.tensorgraph.fcnet.MultitaskClassifier(\n",
    "model = dc.models.MultitaskClassifier(\n",
    "    len(tox21_tasks),\n",
    "    train_dataset.get_data_shape()[0])\n",
    "\n",
@@ -168,7 +168,7 @@
    "# We need a function which takes a 2d numpy array (samples, features) and returns predictions (samples,)\n",
    "def eval_model(my_model, transformers):\n",
    "    def eval_closure(x):\n",
    "        ds = dc.data.NumpyDataset(x, None, None, None, n_tasks=n_tasks)\n",
    "        ds = dc.data.NumpyDataset(x, None, None, None, n_tasks=len(tox21_tasks))\n",
    "        # The 0th task is NR-AR\n",
    "        predictions = model.predict(ds)[:,0]\n",
    "        return predictions\n",