sync cont. learner

This commit is contained in:
Jonas Weinz 2018-07-20 13:41:13 +02:00
parent d0999a2fc9
commit 3f5b5fe3f3

View File

@ -145,7 +145,7 @@
{
"data": {
"application/vnd.jupyter.widget-view+json": {
"model_id": "31e69854333f4c599b037b6c27f30f20",
"model_id": "ef207b9276fc4a84b46053e7d979f2a2",
"version_major": 2,
"version_minor": 0
},
@ -692,6 +692,36 @@
"sdm"
]
},
{
"cell_type": "code",
"execution_count": 12,
"metadata": {},
"outputs": [
{
"ename": "AttributeError",
"evalue": "'NoneType' object has no attribute 'pipeline'",
"output_type": "error",
"traceback": [
"\u001b[0;31m---------------------------------------------------------------------------\u001b[0m",
"\u001b[0;31mAttributeError\u001b[0m Traceback (most recent call last)",
"\u001b[0;32m<ipython-input-12-beaf1df9153b>\u001b[0m in \u001b[0;36m<module>\u001b[0;34m()\u001b[0m\n\u001b[0;32m----> 1\u001b[0;31m \u001b[0mv\u001b[0m \u001b[0;34m=\u001b[0m \u001b[0mpm\u001b[0m\u001b[0;34m.\u001b[0m\u001b[0mpipeline\u001b[0m\u001b[0;34m.\u001b[0m\u001b[0mnamed_steps\u001b[0m\u001b[0;34m[\u001b[0m\u001b[0;34m'vectorizer'\u001b[0m\u001b[0;34m]\u001b[0m\u001b[0;34m.\u001b[0m\u001b[0mtransform\u001b[0m\u001b[0;34m(\u001b[0m\u001b[0;34m[\u001b[0m\u001b[0;34m\"I am sad\"\u001b[0m\u001b[0;34m]\u001b[0m\u001b[0;34m)\u001b[0m\u001b[0;34m\u001b[0m\u001b[0m\n\u001b[0m",
"\u001b[0;31mAttributeError\u001b[0m: 'NoneType' object has no attribute 'pipeline'"
]
}
],
"source": [
"v = pm.pipeline.named_steps['vectorizer'].transform([\"I am sad\"])"
]
},
{
"cell_type": "code",
"execution_count": null,
"metadata": {},
"outputs": [],
"source": [
"pm.pipeline.named_steps['keras_model'].predict([v])"
]
},
{
"cell_type": "code",
"execution_count": null,