Browse Source

pincelate works

master
nglk 2 years ago
parent
commit
eec507971a
  1. 1
      .gitignore
  2. 95
      .ipynb_checkpoints/failed_attempt_install_tensorflow-checkpoint.ipynb
  3. 294
      .ipynb_checkpoints/picelate-checkpoint.ipynb
  4. 9
      any_one_day_this_dictionary_has_died.json
  5. 95
      failed_attempt_install_tensorflow.ipynb
  6. 195
      picelate.ipynb
  7. 248
      pincelate.ipynb

1
.gitignore

@ -0,0 +1 @@
pocket/

95
.ipynb_checkpoints/failed_attempt_install_tensorflow-checkpoint.ipynb

@ -0,0 +1,95 @@
{
"cells": [
{
"cell_type": "code",
"execution_count": 1,
"id": "877811c4",
"metadata": {},
"outputs": [
{
"name": "stdout",
"output_type": "stream",
"text": [
"Defaulting to user installation because normal site-packages is not writeable\n",
"Collecting tensorflow==1.15.0\n",
" Using cached tensorflow-1.15.0-cp36-cp36m-manylinux2010_x86_64.whl (412.3 MB)\n",
"Collecting keras==2.2.5\n",
" Using cached Keras-2.2.5-py2.py3-none-any.whl (336 kB)\n",
"Requirement already satisfied: astor>=0.6.0 in /home/angeliki/.local/lib/python3.6/site-packages (from tensorflow==1.15.0) (0.8.1)\n",
"Requirement already satisfied: keras-applications>=1.0.8 in /home/angeliki/.local/lib/python3.6/site-packages (from tensorflow==1.15.0) (1.0.8)\n",
"Requirement already satisfied: keras-preprocessing>=1.0.5 in /home/angeliki/.local/lib/python3.6/site-packages (from tensorflow==1.15.0) (1.1.2)\n",
"Requirement already satisfied: google-pasta>=0.1.6 in /home/angeliki/.local/lib/python3.6/site-packages (from tensorflow==1.15.0) (0.2.0)\n",
"Requirement already satisfied: grpcio>=1.8.6 in /home/angeliki/.local/lib/python3.6/site-packages (from tensorflow==1.15.0) (1.48.2)\n",
"Requirement already satisfied: gast==0.2.2 in /home/angeliki/.local/lib/python3.6/site-packages (from tensorflow==1.15.0) (0.2.2)\n",
"Requirement already satisfied: tensorboard<1.16.0,>=1.15.0 in /home/angeliki/.local/lib/python3.6/site-packages (from tensorflow==1.15.0) (1.15.0)\n",
"Requirement already satisfied: tensorflow-estimator==1.15.1 in /home/angeliki/.local/lib/python3.6/site-packages (from tensorflow==1.15.0) (1.15.1)\n",
"Requirement already satisfied: absl-py>=0.7.0 in /home/angeliki/.local/lib/python3.6/site-packages (from tensorflow==1.15.0) (1.3.0)\n",
"Requirement already satisfied: termcolor>=1.1.0 in /home/angeliki/.local/lib/python3.6/site-packages (from tensorflow==1.15.0) (1.1.0)\n",
"Requirement already satisfied: wrapt>=1.11.1 in /home/angeliki/.local/lib/python3.6/site-packages (from tensorflow==1.15.0) (1.14.1)\n",
"Requirement already satisfied: protobuf>=3.6.1 in /home/angeliki/.local/lib/python3.6/site-packages (from tensorflow==1.15.0) (3.19.6)\n",
"Requirement already satisfied: opt-einsum>=2.3.2 in /home/angeliki/.local/lib/python3.6/site-packages (from tensorflow==1.15.0) (3.3.0)\n",
"Requirement already satisfied: numpy<2.0,>=1.16.0 in /usr/local/lib/python3.6/dist-packages (from tensorflow==1.15.0) (1.16.2)\n",
"Requirement already satisfied: wheel>=0.26 in /usr/lib/python3/dist-packages (from tensorflow==1.15.0) (0.30.0)\n",
"Requirement already satisfied: six>=1.10.0 in /usr/lib/python3/dist-packages (from tensorflow==1.15.0) (1.11.0)\n",
"Requirement already satisfied: pyyaml in /usr/lib/python3/dist-packages (from keras==2.2.5) (3.12)\n",
"Requirement already satisfied: h5py in /home/angeliki/.local/lib/python3.6/site-packages (from keras==2.2.5) (3.1.0)\n",
"Requirement already satisfied: scipy>=0.14 in /usr/local/lib/python3.6/dist-packages (from keras==2.2.5) (1.2.1)\n",
"Requirement already satisfied: markdown>=2.6.8 in /home/angeliki/.local/lib/python3.6/site-packages (from tensorboard<1.16.0,>=1.15.0->tensorflow==1.15.0) (3.3.7)\n",
"Requirement already satisfied: setuptools>=41.0.0 in /home/angeliki/.local/lib/python3.6/site-packages (from tensorboard<1.16.0,>=1.15.0->tensorflow==1.15.0) (59.6.0)\n",
"Requirement already satisfied: werkzeug>=0.11.15 in /home/angeliki/.local/lib/python3.6/site-packages (from tensorboard<1.16.0,>=1.15.0->tensorflow==1.15.0) (1.0.1)\n",
"Requirement already satisfied: cached-property; python_version < \"3.8\" in /home/angeliki/.local/lib/python3.6/site-packages (from h5py->keras==2.2.5) (1.5.2)\n",
"Requirement already satisfied: importlib-metadata>=4.4; python_version < \"3.10\" in /home/angeliki/.local/lib/python3.6/site-packages (from markdown>=2.6.8->tensorboard<1.16.0,>=1.15.0->tensorflow==1.15.0) (4.8.3)\n",
"Requirement already satisfied: zipp>=0.5 in /home/angeliki/.local/lib/python3.6/site-packages (from importlib-metadata>=4.4; python_version < \"3.10\"->markdown>=2.6.8->tensorboard<1.16.0,>=1.15.0->tensorflow==1.15.0) (3.5.0)\n",
"Requirement already satisfied: typing-extensions>=3.6.4; python_version < \"3.8\" in /home/angeliki/.local/lib/python3.6/site-packages (from importlib-metadata>=4.4; python_version < \"3.10\"->markdown>=2.6.8->tensorboard<1.16.0,>=1.15.0->tensorflow==1.15.0) (4.1.1)\n",
"Installing collected packages: tensorflow, keras\n",
"\u001b[31mERROR: Could not install packages due to an EnvironmentError: [Errno 28] No space left on device\n",
"\u001b[0m\n",
"\u001b[33mWARNING: You are using pip version 20.0.2; however, version 21.3.1 is available.\n",
"You should consider upgrading via the '/usr/bin/python3 -m pip install --upgrade pip' command.\u001b[0m\n"
]
}
],
"source": [
"import sys\n",
"!{sys.executable} -m pip install tensorflow==1.15.0 keras==2.2.5\n"
]
},
{
"cell_type": "code",
"execution_count": null,
"id": "31e0fc42",
"metadata": {},
"outputs": [],
"source": []
},
{
"cell_type": "code",
"execution_count": null,
"id": "618fb0f8",
"metadata": {},
"outputs": [],
"source": []
}
],
"metadata": {
"kernelspec": {
"display_name": "Python 3",
"language": "python",
"name": "python3"
},
"language_info": {
"codemirror_mode": {
"name": "ipython",
"version": 3
},
"file_extension": ".py",
"mimetype": "text/x-python",
"name": "python",
"nbconvert_exporter": "python",
"pygments_lexer": "ipython3",
"version": "3.6.9"
}
},
"nbformat": 4,
"nbformat_minor": 5
}

294
.ipynb_checkpoints/picelate-checkpoint.ipynb

@ -0,0 +1,294 @@
{
"cells": [
{
"cell_type": "code",
"execution_count": 1,
"id": "north-steering",
"metadata": {},
"outputs": [
{
"name": "stdout",
"output_type": "stream",
"text": [
"pip 20.3.4 from /usr/lib/python3/dist-packages/pip (python 3.9)\n",
"Note: you may need to restart the kernel to use updated packages.\n"
]
}
],
"source": [
"pip -V"
]
},
{
"cell_type": "code",
"execution_count": 1,
"id": "ranking-bottom",
"metadata": {},
"outputs": [
{
"name": "stdout",
"output_type": "stream",
"text": [
"Collecting tensorflow==1.15.5\n",
" Using cached tensorflow-1.15.5-cp36-cp36m-manylinux2010_x86_64.whl (110.5 MB)\n",
"Collecting gast==0.2.2\n",
" Using cached gast-0.2.2-py3-none-any.whl\n",
"Collecting keras-preprocessing>=1.0.5\n",
" Using cached Keras_Preprocessing-1.1.2-py2.py3-none-any.whl (42 kB)\n",
"Collecting h5py<=2.10.0\n",
" Using cached h5py-2.10.0-cp36-cp36m-manylinux1_x86_64.whl (2.9 MB)\n",
"Collecting opt-einsum>=2.3.2\n",
" Using cached opt_einsum-3.3.0-py3-none-any.whl (65 kB)\n",
"Collecting protobuf>=3.6.1\n",
" Using cached protobuf-3.19.6-cp36-cp36m-manylinux_2_17_x86_64.manylinux2014_x86_64.whl (1.1 MB)\n",
"Collecting tensorboard<1.16.0,>=1.15.0\n",
" Using cached tensorboard-1.15.0-py3-none-any.whl (3.8 MB)\n",
"Collecting tensorflow-estimator==1.15.1\n",
" Using cached tensorflow_estimator-1.15.1-py2.py3-none-any.whl (503 kB)\n",
"Collecting astor>=0.6.0\n",
" Using cached astor-0.8.1-py2.py3-none-any.whl (27 kB)\n",
"Collecting absl-py>=0.7.0\n",
" Using cached absl_py-1.3.0-py3-none-any.whl (124 kB)\n",
"Collecting termcolor>=1.1.0\n",
" Using cached termcolor-1.1.0.tar.gz (3.9 kB)\n",
" Preparing metadata (setup.py) ... \u001b[?25ldone\n",
"\u001b[?25hCollecting wheel>=0.26\n",
" Downloading wheel-0.37.1-py2.py3-none-any.whl (35 kB)\n",
"Requirement already satisfied: six>=1.10.0 in ./pocket/lib/python3.6/site-packages (from tensorflow==1.15.5) (1.16.0)\n",
"Collecting grpcio>=1.8.6\n",
" Using cached grpcio-1.48.2-cp36-cp36m-manylinux_2_17_x86_64.manylinux2014_x86_64.whl (4.6 MB)\n",
"Collecting keras-applications>=1.0.8\n",
" Using cached Keras_Applications-1.0.8-py3-none-any.whl (50 kB)\n",
"Collecting numpy<1.19.0,>=1.16.0\n",
" Downloading numpy-1.18.5-cp36-cp36m-manylinux1_x86_64.whl (20.1 MB)\n",
" |████████████████████████████████| 20.1 MB 14.0 MB/s \n",
"\u001b[?25hCollecting google-pasta>=0.1.6\n",
" Using cached google_pasta-0.2.0-py3-none-any.whl (57 kB)\n",
"Collecting wrapt>=1.11.1\n",
" Using cached wrapt-1.14.1-cp36-cp36m-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_17_x86_64.manylinux2014_x86_64.whl (74 kB)\n",
"Collecting markdown>=2.6.8\n",
" Using cached Markdown-3.3.7-py3-none-any.whl (97 kB)\n",
"Collecting setuptools>=41.0.0\n",
" Using cached setuptools-59.6.0-py3-none-any.whl (952 kB)\n",
"Collecting werkzeug>=0.11.15\n",
" Downloading Werkzeug-2.0.3-py3-none-any.whl (289 kB)\n",
" |████████████████████████████████| 289 kB 14.3 MB/s \n",
"\u001b[?25hRequirement already satisfied: importlib-metadata>=4.4 in ./pocket/lib/python3.6/site-packages (from markdown>=2.6.8->tensorboard<1.16.0,>=1.15.0->tensorflow==1.15.5) (4.8.3)\n",
"Requirement already satisfied: dataclasses in ./pocket/lib/python3.6/site-packages (from werkzeug>=0.11.15->tensorboard<1.16.0,>=1.15.0->tensorflow==1.15.5) (0.8)\n",
"Requirement already satisfied: typing-extensions>=3.6.4 in ./pocket/lib/python3.6/site-packages (from importlib-metadata>=4.4->markdown>=2.6.8->tensorboard<1.16.0,>=1.15.0->tensorflow==1.15.5) (4.1.1)\n",
"Requirement already satisfied: zipp>=0.5 in ./pocket/lib/python3.6/site-packages (from importlib-metadata>=4.4->markdown>=2.6.8->tensorboard<1.16.0,>=1.15.0->tensorflow==1.15.5) (3.6.0)\n",
"Using legacy 'setup.py install' for termcolor, since package 'wheel' is not installed.\n",
"Installing collected packages: numpy, wheel, werkzeug, setuptools, protobuf, markdown, h5py, grpcio, absl-py, wrapt, termcolor, tensorflow-estimator, tensorboard, opt-einsum, keras-preprocessing, keras-applications, google-pasta, gast, astor, tensorflow\n",
" Attempting uninstall: setuptools\n",
" Found existing installation: setuptools 39.0.1\n",
" Uninstalling setuptools-39.0.1:\n",
" Successfully uninstalled setuptools-39.0.1\n",
" Running setup.py install for termcolor ... \u001b[?25ldone\n",
"\u001b[?25hSuccessfully installed absl-py-1.3.0 astor-0.8.1 gast-0.2.2 google-pasta-0.2.0 grpcio-1.48.2 h5py-2.10.0 keras-applications-1.0.8 keras-preprocessing-1.1.2 markdown-3.3.7 numpy-1.18.5 opt-einsum-3.3.0 protobuf-3.19.6 setuptools-59.6.0 tensorboard-1.15.0 tensorflow-1.15.5 tensorflow-estimator-1.15.1 termcolor-1.1.0 werkzeug-2.0.3 wheel-0.37.1 wrapt-1.14.1\n",
"Collecting keras==2.2.5\n",
" Using cached Keras-2.2.5-py2.py3-none-any.whl (336 kB)\n",
"Requirement already satisfied: six>=1.9.0 in ./pocket/lib/python3.6/site-packages (from keras==2.2.5) (1.16.0)\n",
"Requirement already satisfied: h5py in ./pocket/lib/python3.6/site-packages (from keras==2.2.5) (2.10.0)\n",
"Requirement already satisfied: keras-applications>=1.0.8 in ./pocket/lib/python3.6/site-packages (from keras==2.2.5) (1.0.8)\n",
"Collecting pyyaml\n",
" Downloading PyYAML-6.0-cp36-cp36m-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_12_x86_64.manylinux2010_x86_64.whl (603 kB)\n",
" |████████████████████████████████| 603 kB 3.3 MB/s \n",
"\u001b[?25hRequirement already satisfied: keras-preprocessing>=1.1.0 in ./pocket/lib/python3.6/site-packages (from keras==2.2.5) (1.1.2)\n",
"Collecting scipy>=0.14\n",
" Downloading scipy-1.5.4-cp36-cp36m-manylinux1_x86_64.whl (25.9 MB)\n",
" |████████████████████████████████| 25.9 MB 854 kB/s \n",
"\u001b[?25hRequirement already satisfied: numpy>=1.9.1 in ./pocket/lib/python3.6/site-packages (from keras==2.2.5) (1.18.5)\n",
"Installing collected packages: scipy, pyyaml, keras\n",
"Successfully installed keras-2.2.5 pyyaml-6.0 scipy-1.5.4\n",
"Collecting pincelate\n",
" Using cached pincelate-0.0.1-py3-none-any.whl (12.0 MB)\n",
"Collecting pronouncing>=0.2.0\n",
" Using cached pronouncing-0.2.0-py2.py3-none-any.whl\n",
"Requirement already satisfied: Keras>=2.2.0 in ./pocket/lib/python3.6/site-packages (from pincelate) (2.2.5)\n",
"Collecting scikit-learn>=0.20.0\n",
" Using cached scikit_learn-0.24.2-cp36-cp36m-manylinux2010_x86_64.whl (22.2 MB)\n",
"Requirement already satisfied: numpy>=1.9.1 in ./pocket/lib/python3.6/site-packages (from Keras>=2.2.0->pincelate) (1.18.5)\n",
"Requirement already satisfied: pyyaml in ./pocket/lib/python3.6/site-packages (from Keras>=2.2.0->pincelate) (6.0)\n",
"Requirement already satisfied: six>=1.9.0 in ./pocket/lib/python3.6/site-packages (from Keras>=2.2.0->pincelate) (1.16.0)\n",
"Requirement already satisfied: h5py in ./pocket/lib/python3.6/site-packages (from Keras>=2.2.0->pincelate) (2.10.0)\n",
"Requirement already satisfied: keras-preprocessing>=1.1.0 in ./pocket/lib/python3.6/site-packages (from Keras>=2.2.0->pincelate) (1.1.2)\n",
"Requirement already satisfied: keras-applications>=1.0.8 in ./pocket/lib/python3.6/site-packages (from Keras>=2.2.0->pincelate) (1.0.8)\n",
"Requirement already satisfied: scipy>=0.14 in ./pocket/lib/python3.6/site-packages (from Keras>=2.2.0->pincelate) (1.5.4)\n",
"Collecting cmudict>=0.4.0\n",
" Using cached cmudict-1.0.2-py2.py3-none-any.whl (939 kB)\n",
"Collecting joblib>=0.11\n",
" Using cached joblib-1.1.1-py2.py3-none-any.whl (309 kB)\n",
"Collecting threadpoolctl>=2.0.0\n",
" Using cached threadpoolctl-3.1.0-py3-none-any.whl (14 kB)\n",
"Installing collected packages: threadpoolctl, joblib, cmudict, scikit-learn, pronouncing, pincelate\n",
"Successfully installed cmudict-1.0.2 joblib-1.1.1 pincelate-0.0.1 pronouncing-0.2.0 scikit-learn-0.24.2 threadpoolctl-3.1.0\n"
]
}
],
"source": [
"import sys\n",
"!{sys.executable} -m pip install tensorflow==1.15.5\n",
"!{sys.executable} -m pip install keras==2.2.5\n",
"!{sys.executable} -m pip install pincelate"
]
},
{
"cell_type": "code",
"execution_count": 2,
"id": "polar-modeling",
"metadata": {},
"outputs": [
{
"name": "stderr",
"output_type": "stream",
"text": [
"Using TensorFlow backend.\n"
]
}
],
"source": [
"from pincelate import Pincelate"
]
},
{
"cell_type": "code",
"execution_count": 8,
"id": "9d01f6ee",
"metadata": {},
"outputs": [],
"source": [
"import ipywidgets as widgets\n",
"from IPython.display import display,HTML\n",
"from ipywidgets import interact,interactive_output,Layout,HBox,VBox"
]
},
{
"cell_type": "code",
"execution_count": 3,
"id": "muslim-labor",
"metadata": {},
"outputs": [
{
"name": "stdout",
"output_type": "stream",
"text": [
"WARNING:tensorflow:From /home/angeliki/Documents/Any_One_day_future/A_tune_in/pocket/lib/python3.6/site-packages/keras/backend/tensorflow_backend.py:541: The name tf.placeholder is deprecated. Please use tf.compat.v1.placeholder instead.\n",
"\n",
"WARNING:tensorflow:From /home/angeliki/Documents/Any_One_day_future/A_tune_in/pocket/lib/python3.6/site-packages/keras/backend/tensorflow_backend.py:66: The name tf.get_default_graph is deprecated. Please use tf.compat.v1.get_default_graph instead.\n",
"\n",
"WARNING:tensorflow:From /home/angeliki/Documents/Any_One_day_future/A_tune_in/pocket/lib/python3.6/site-packages/keras/backend/tensorflow_backend.py:4432: The name tf.random_uniform is deprecated. Please use tf.random.uniform instead.\n",
"\n",
"WARNING:tensorflow:From /home/angeliki/Documents/Any_One_day_future/A_tune_in/pocket/lib/python3.6/site-packages/keras/backend/tensorflow_backend.py:148: The name tf.placeholder_with_default is deprecated. Please use tf.compat.v1.placeholder_with_default instead.\n",
"\n",
"WARNING:tensorflow:From /home/angeliki/Documents/Any_One_day_future/A_tune_in/pocket/lib/python3.6/site-packages/keras/backend/tensorflow_backend.py:3733: calling dropout (from tensorflow.python.ops.nn_ops) with keep_prob is deprecated and will be removed in a future version.\n",
"Instructions for updating:\n",
"Please use `rate` instead of `keep_prob`. Rate should be set to `rate = 1 - keep_prob`.\n",
"WARNING:tensorflow:From /home/angeliki/Documents/Any_One_day_future/A_tune_in/pocket/lib/python3.6/site-packages/keras/backend/tensorflow_backend.py:3239: where (from tensorflow.python.ops.array_ops) is deprecated and will be removed in a future version.\n",
"Instructions for updating:\n",
"Use tf.where in 2.0, which has the same broadcast rule as np.where\n",
"WARNING:tensorflow:From /home/angeliki/Documents/Any_One_day_future/A_tune_in/pocket/lib/python3.6/site-packages/keras/backend/tensorflow_backend.py:190: The name tf.get_default_session is deprecated. Please use tf.compat.v1.get_default_session instead.\n",
"\n",
"WARNING:tensorflow:From /home/angeliki/Documents/Any_One_day_future/A_tune_in/pocket/lib/python3.6/site-packages/keras/backend/tensorflow_backend.py:197: The name tf.ConfigProto is deprecated. Please use tf.compat.v1.ConfigProto instead.\n",
"\n",
"WARNING:tensorflow:From /home/angeliki/Documents/Any_One_day_future/A_tune_in/pocket/lib/python3.6/site-packages/keras/backend/tensorflow_backend.py:203: The name tf.Session is deprecated. Please use tf.compat.v1.Session instead.\n",
"\n",
"WARNING:tensorflow:From /home/angeliki/Documents/Any_One_day_future/A_tune_in/pocket/lib/python3.6/site-packages/keras/backend/tensorflow_backend.py:207: The name tf.global_variables is deprecated. Please use tf.compat.v1.global_variables instead.\n",
"\n",
"WARNING:tensorflow:From /home/angeliki/Documents/Any_One_day_future/A_tune_in/pocket/lib/python3.6/site-packages/keras/backend/tensorflow_backend.py:216: The name tf.is_variable_initialized is deprecated. Please use tf.compat.v1.is_variable_initialized instead.\n",
"\n",
"WARNING:tensorflow:From /home/angeliki/Documents/Any_One_day_future/A_tune_in/pocket/lib/python3.6/site-packages/keras/backend/tensorflow_backend.py:223: The name tf.variables_initializer is deprecated. Please use tf.compat.v1.variables_initializer instead.\n",
"\n"
]
}
],
"source": [
"pin = Pincelate()\n"
]
},
{
"cell_type": "code",
"execution_count": 6,
"id": "graphic-appearance",
"metadata": {},
"outputs": [
{
"data": {
"text/plain": [
"'espelling'"
]
},
"execution_count": 6,
"metadata": {},
"output_type": "execute_result"
}
],
"source": [
"pin.manipulate(\"spelling\",temperature=1.5)"
]
},
{
"cell_type": "code",
"execution_count": null,
"id": "361fe610",
"metadata": {},
"outputs": [],
"source": []
},
{
"cell_type": "code",
"execution_count": 9,
"id": "b648b5ae",
"metadata": {},
"outputs": [
{
"data": {
"application/vnd.jupyter.widget-view+json": {
"model_id": "a85a8a310b3c41f6be00aa3231989b5f",
"version_major": 2,
"version_minor": 0
},
"text/plain": [
"interactive(children=(Text(value='any one future died', description='s'), FloatSlider(value=1.2500000000000002…"
]
},
"metadata": {},
"output_type": "display_data"
}
],
"source": [
"@interact(s=\"any one future died\",temp=(0.05,2.5,0.05))\n",
"def tempadjust(s,temp):\n",
" return ' '.join([pin.manipulate(w.lower(),temperature=temp) for w in s.split()])"
]
},
{
"cell_type": "code",
"execution_count": null,
"id": "e4717967",
"metadata": {},
"outputs": [],
"source": []
}
],
"metadata": {
"kernelspec": {
"display_name": "Python 3",
"language": "python",
"name": "python3"
},
"language_info": {
"codemirror_mode": {
"name": "ipython",
"version": 3
},
"file_extension": ".py",
"mimetype": "text/x-python",
"name": "python",
"nbconvert_exporter": "python",
"pygments_lexer": "ipython3",
"version": "3.6.9"
}
},
"nbformat": 4,
"nbformat_minor": 5
}

9
any_one_day_this_dictionary_has_died.json

@ -0,0 +1,9 @@
{
'death':
{
'paramyms': ['murder', 'killing', 'φόνος', 'φονός', 'φώνος', 'φωνή', 'διακοπή', 'depth', 'debt', 'θα είναι αυτός', 'θα νάτος'],
'parameanings': ['telos', 'kako', 'symfora', 'tragodia', 'καλά του κάνανε'],
'paradoxes': ['most', 'horismos', 'siopi', 'έφυγε', 'την χάσαμε', 'ταξίδεψε', 'θάνατος']
}
}

95
failed_attempt_install_tensorflow.ipynb

@ -2,7 +2,7 @@
"cells": [ "cells": [
{ {
"cell_type": "code", "cell_type": "code",
"execution_count": 1, "execution_count": 2,
"id": "877811c4", "id": "877811c4",
"metadata": {}, "metadata": {},
"outputs": [ "outputs": [
@ -11,78 +11,37 @@
"output_type": "stream", "output_type": "stream",
"text": [ "text": [
"Defaulting to user installation because normal site-packages is not writeable\n", "Defaulting to user installation because normal site-packages is not writeable\n",
"Collecting tensorflow==1.15.0\n", "Requirement already satisfied: tensorflow==1.15.0 in /home/angeliki/.local/lib/python3.6/site-packages (1.15.0)\n",
" Downloading tensorflow-1.15.0-cp36-cp36m-manylinux2010_x86_64.whl (412.3 MB)\n", "Collecting keras==2.2.5\n",
"\u001b[K |████████████████████████████████| 412.3 MB 25 kB/s eta 0:00:0165 |██ | 24.8 MB 102 kB/s eta 1:03:11 |███▋ | 46.6 MB 3.5 MB/s eta 0:01:45 |████▌ | 57.8 MB 7.2 MB/s eta 0:00:49 |███████████▏ | 143.7 MB 1.7 MB/s eta 0:02:42 |█████████████████▋ | 227.2 MB 1.2 MB/s eta 0:02:34 |███████████████████████▍ | 300.8 MB 502 kB/s eta 0:03:42 |████████████████████████▋ | 317.0 MB 2.8 MB/s eta 0:00:35 |█████████████████████████ | 323.2 MB 2.8 MB/s eta 0:00:32 |█████████████████████████████▍ | 378.4 MB 93 kB/s eta 0:06:05 |█████████████████████████████▌ | 379.4 MB 24 kB/s eta 0:22:15ta 0:12:52�██▍| 404.4 MB 29 kB/s eta 0:04:34\n", " Using cached Keras-2.2.5-py2.py3-none-any.whl (336 kB)\n",
"\u001b[33mWARNING: Retrying (Retry(total=4, connect=None, read=None, redirect=None, status=None)) after connection broken by 'ReadTimeoutError(\"HTTPSConnectionPool(host='pypi.org', port=443): Read timed out. (read timeout=15)\",)': /simple/keras/\u001b[0m\n", "Requirement already satisfied: keras-applications>=1.0.8 in /home/angeliki/.local/lib/python3.6/site-packages (from tensorflow==1.15.0) (1.0.8)\n",
"\u001b[?25hCollecting keras==2.2.5\n", "Requirement already satisfied: wrapt>=1.11.1 in /home/angeliki/.local/lib/python3.6/site-packages (from tensorflow==1.15.0) (1.14.1)\n",
" Downloading Keras-2.2.5-py2.py3-none-any.whl (336 kB)\n", "Requirement already satisfied: google-pasta>=0.1.6 in /home/angeliki/.local/lib/python3.6/site-packages (from tensorflow==1.15.0) (0.2.0)\n",
"\u001b[K |████████████████████████████████| 336 kB 124 kB/s eta 0:00:01\n", "Requirement already satisfied: six>=1.10.0 in /usr/lib/python3/dist-packages (from tensorflow==1.15.0) (1.11.0)\n",
"\u001b[?25hRequirement already satisfied: wheel>=0.26 in /usr/lib/python3/dist-packages (from tensorflow==1.15.0) (0.30.0)\n", "Requirement already satisfied: gast==0.2.2 in /home/angeliki/.local/lib/python3.6/site-packages (from tensorflow==1.15.0) (0.2.2)\n",
"Collecting absl-py>=0.7.0\n", "Requirement already satisfied: wheel>=0.26 in /usr/lib/python3/dist-packages (from tensorflow==1.15.0) (0.30.0)\n",
" Downloading absl_py-1.3.0-py3-none-any.whl (124 kB)\n", "Requirement already satisfied: opt-einsum>=2.3.2 in /home/angeliki/.local/lib/python3.6/site-packages (from tensorflow==1.15.0) (3.3.0)\n",
"\u001b[K |████████████████████████████████| 124 kB 109 kB/s eta 0:00:01\n", "Requirement already satisfied: numpy<2.0,>=1.16.0 in /usr/local/lib/python3.6/dist-packages (from tensorflow==1.15.0) (1.16.2)\n",
"\u001b[?25hRequirement already satisfied: numpy<2.0,>=1.16.0 in /usr/local/lib/python3.6/dist-packages (from tensorflow==1.15.0) (1.16.2)\n", "Requirement already satisfied: protobuf>=3.6.1 in /home/angeliki/.local/lib/python3.6/site-packages (from tensorflow==1.15.0) (3.19.6)\n",
"Collecting opt-einsum>=2.3.2\n", "Requirement already satisfied: tensorboard<1.16.0,>=1.15.0 in /home/angeliki/.local/lib/python3.6/site-packages (from tensorflow==1.15.0) (1.15.0)\n",
" Downloading opt_einsum-3.3.0-py3-none-any.whl (65 kB)\n", "Requirement already satisfied: tensorflow-estimator==1.15.1 in /home/angeliki/.local/lib/python3.6/site-packages (from tensorflow==1.15.0) (1.15.1)\n",
"\u001b[K |████████████████████████████████| 65 kB 119 kB/s eta 0:00:01\n", "Requirement already satisfied: grpcio>=1.8.6 in /home/angeliki/.local/lib/python3.6/site-packages (from tensorflow==1.15.0) (1.48.2)\n",
"\u001b[?25hProcessing /home/angeliki/.cache/pip/wheels/7c/06/54/bc84598ba1daf8f970247f550b175aaaee85f68b4b0c5ab2c6/termcolor-1.1.0-cp36-none-any.whl\n", "Requirement already satisfied: astor>=0.6.0 in /home/angeliki/.local/lib/python3.6/site-packages (from tensorflow==1.15.0) (0.8.1)\n",
"Collecting gast==0.2.2\n", "Requirement already satisfied: keras-preprocessing>=1.0.5 in /home/angeliki/.local/lib/python3.6/site-packages (from tensorflow==1.15.0) (1.1.2)\n",
" Downloading gast-0.2.2.tar.gz (10 kB)\n", "Requirement already satisfied: absl-py>=0.7.0 in /home/angeliki/.local/lib/python3.6/site-packages (from tensorflow==1.15.0) (1.3.0)\n",
"Collecting astor>=0.6.0\n", "Requirement already satisfied: termcolor>=1.1.0 in /home/angeliki/.local/lib/python3.6/site-packages (from tensorflow==1.15.0) (1.1.0)\n",
" Downloading astor-0.8.1-py2.py3-none-any.whl (27 kB)\n", "Requirement already satisfied: h5py in /home/angeliki/.local/lib/python3.6/site-packages (from keras==2.2.5) (3.1.0)\n",
"Collecting keras-preprocessing>=1.0.5\n", "Requirement already satisfied: scipy>=0.14 in /usr/local/lib/python3.6/dist-packages (from keras==2.2.5) (1.2.1)\n",
" Downloading Keras_Preprocessing-1.1.2-py2.py3-none-any.whl (42 kB)\n",
"\u001b[K |████████████████████████████████| 42 kB 123 kB/s eta 0:00:01\n",
"\u001b[?25hRequirement already satisfied: six>=1.10.0 in /usr/lib/python3/dist-packages (from tensorflow==1.15.0) (1.11.0)\n",
"Collecting google-pasta>=0.1.6\n",
" Downloading google_pasta-0.2.0-py3-none-any.whl (57 kB)\n",
"\u001b[K |████████████████████████████████| 57 kB 119 kB/s eta 0:00:01\n",
"\u001b[?25hCollecting tensorboard<1.16.0,>=1.15.0\n",
" Downloading tensorboard-1.15.0-py3-none-any.whl (3.8 MB)\n",
"\u001b[K |████████████████████████████████| 3.8 MB 123 kB/s eta 0:00:01\n",
"\u001b[?25hCollecting tensorflow-estimator==1.15.1\n",
" Downloading tensorflow_estimator-1.15.1-py2.py3-none-any.whl (503 kB)\n",
"\u001b[K |████████████████████████████████| 503 kB 129 kB/s eta 0:00:01\n",
"\u001b[?25hCollecting grpcio>=1.8.6\n",
" Downloading grpcio-1.48.2-cp36-cp36m-manylinux_2_17_x86_64.manylinux2014_x86_64.whl (4.6 MB)\n",
"\u001b[K |████████████████████████████████| 4.6 MB 104 kB/s eta 0:00:01\n",
"\u001b[?25hCollecting protobuf>=3.6.1\n",
" Downloading protobuf-3.19.6-cp36-cp36m-manylinux_2_17_x86_64.manylinux2014_x86_64.whl (1.1 MB)\n",
"\u001b[K |████████████████████████████████| 1.1 MB 106 kB/s eta 0:00:01\n",
"\u001b[?25hCollecting keras-applications>=1.0.8\n",
" Downloading Keras_Applications-1.0.8-py3-none-any.whl (50 kB)\n",
"\u001b[K |████████████████████████████████| 50 kB 104 kB/s ta 0:00:01\n",
"\u001b[?25hCollecting wrapt>=1.11.1\n",
" Downloading wrapt-1.14.1-cp36-cp36m-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_17_x86_64.manylinux2014_x86_64.whl (74 kB)\n",
"\u001b[K |████████████████████████████████| 74 kB 123 kB/s eta 0:00:01\n",
"\u001b[?25hCollecting h5py\n",
" Downloading h5py-3.1.0-cp36-cp36m-manylinux1_x86_64.whl (4.0 MB)\n",
"\u001b[K |████████████████████████████████| 4.0 MB 122 kB/s eta 0:00:01\n",
"\u001b[?25hRequirement already satisfied: scipy>=0.14 in /usr/local/lib/python3.6/dist-packages (from keras==2.2.5) (1.2.1)\n",
"Requirement already satisfied: pyyaml in /usr/lib/python3/dist-packages (from keras==2.2.5) (3.12)\n", "Requirement already satisfied: pyyaml in /usr/lib/python3/dist-packages (from keras==2.2.5) (3.12)\n",
"Collecting setuptools>=41.0.0\n",
" Using cached setuptools-59.6.0-py3-none-any.whl (952 kB)\n",
"Requirement already satisfied: markdown>=2.6.8 in /home/angeliki/.local/lib/python3.6/site-packages (from tensorboard<1.16.0,>=1.15.0->tensorflow==1.15.0) (3.3.7)\n",
"Requirement already satisfied: werkzeug>=0.11.15 in /home/angeliki/.local/lib/python3.6/site-packages (from tensorboard<1.16.0,>=1.15.0->tensorflow==1.15.0) (1.0.1)\n", "Requirement already satisfied: werkzeug>=0.11.15 in /home/angeliki/.local/lib/python3.6/site-packages (from tensorboard<1.16.0,>=1.15.0->tensorflow==1.15.0) (1.0.1)\n",
"Collecting cached-property; python_version < \"3.8\"\n", "Requirement already satisfied: setuptools>=41.0.0 in /home/angeliki/.local/lib/python3.6/site-packages (from tensorboard<1.16.0,>=1.15.0->tensorflow==1.15.0) (59.6.0)\n",
" Downloading cached_property-1.5.2-py2.py3-none-any.whl (7.6 kB)\n", "Requirement already satisfied: markdown>=2.6.8 in /home/angeliki/.local/lib/python3.6/site-packages (from tensorboard<1.16.0,>=1.15.0->tensorflow==1.15.0) (3.3.7)\n",
"Requirement already satisfied: cached-property; python_version < \"3.8\" in /home/angeliki/.local/lib/python3.6/site-packages (from h5py->keras==2.2.5) (1.5.2)\n",
"Requirement already satisfied: importlib-metadata>=4.4; python_version < \"3.10\" in /home/angeliki/.local/lib/python3.6/site-packages (from markdown>=2.6.8->tensorboard<1.16.0,>=1.15.0->tensorflow==1.15.0) (4.8.3)\n", "Requirement already satisfied: importlib-metadata>=4.4; python_version < \"3.10\" in /home/angeliki/.local/lib/python3.6/site-packages (from markdown>=2.6.8->tensorboard<1.16.0,>=1.15.0->tensorflow==1.15.0) (4.8.3)\n",
"Requirement already satisfied: typing-extensions>=3.6.4; python_version < \"3.8\" in /home/angeliki/.local/lib/python3.6/site-packages (from importlib-metadata>=4.4; python_version < \"3.10\"->markdown>=2.6.8->tensorboard<1.16.0,>=1.15.0->tensorflow==1.15.0) (4.1.1)\n", "Requirement already satisfied: typing-extensions>=3.6.4; python_version < \"3.8\" in /home/angeliki/.local/lib/python3.6/site-packages (from importlib-metadata>=4.4; python_version < \"3.10\"->markdown>=2.6.8->tensorboard<1.16.0,>=1.15.0->tensorflow==1.15.0) (4.1.1)\n",
"Requirement already satisfied: zipp>=0.5 in /home/angeliki/.local/lib/python3.6/site-packages (from importlib-metadata>=4.4; python_version < \"3.10\"->markdown>=2.6.8->tensorboard<1.16.0,>=1.15.0->tensorflow==1.15.0) (3.5.0)\n", "Requirement already satisfied: zipp>=0.5 in /home/angeliki/.local/lib/python3.6/site-packages (from importlib-metadata>=4.4; python_version < \"3.10\"->markdown>=2.6.8->tensorboard<1.16.0,>=1.15.0->tensorflow==1.15.0) (3.5.0)\n",
"Building wheels for collected packages: gast\n", "Installing collected packages: keras\n",
" Building wheel for gast (setup.py) ... \u001b[?25ldone\n", "Successfully installed keras-2.2.5\n",
"\u001b[?25h Created wheel for gast: filename=gast-0.2.2-py3-none-any.whl size=7635 sha256=0fbcf07e73f4b08cdded16a5d95b5a9cc41515bd16f54b33e6e3e40311867af4\n",
" Stored in directory: /home/angeliki/.cache/pip/wheels/19/a7/b9/0740c7a3a7d1d348f04823339274b90de25fbcd217b2ee1fbe\n",
"Successfully built gast\n",
"\u001b[31mERROR: launchpadlib 1.10.6 requires testresources, which is not installed.\u001b[0m\n",
"Installing collected packages: absl-py, opt-einsum, termcolor, gast, astor, keras-preprocessing, google-pasta, grpcio, setuptools, protobuf, tensorboard, tensorflow-estimator, cached-property, h5py, keras-applications, wrapt, tensorflow, keras\n",
" Attempting uninstall: setuptools\n",
" Found existing installation: setuptools 40.8.0\n",
" Uninstalling setuptools-40.8.0:\n",
" Successfully uninstalled setuptools-40.8.0\n",
"\u001b[31mERROR: Could not install packages due to an EnvironmentError: [Errno 28] No space left on device\n",
"\u001b[0m\n",
"\u001b[33mWARNING: You are using pip version 20.0.2; however, version 21.3.1 is available.\n", "\u001b[33mWARNING: You are using pip version 20.0.2; however, version 21.3.1 is available.\n",
"You should consider upgrading via the '/usr/bin/python3 -m pip install --upgrade pip' command.\u001b[0m\n" "You should consider upgrading via the '/usr/bin/python3 -m pip install --upgrade pip' command.\u001b[0m\n"
] ]

195
picelate.ipynb

@ -1,195 +0,0 @@
{
"cells": [
{
"cell_type": "code",
"execution_count": 1,
"id": "north-steering",
"metadata": {},
"outputs": [
{
"name": "stdout",
"output_type": "stream",
"text": [
"pip 20.3.4 from /usr/lib/python3/dist-packages/pip (python 3.9)\n",
"Note: you may need to restart the kernel to use updated packages.\n"
]
}
],
"source": [
"pip -V"
]
},
{
"cell_type": "code",
"execution_count": 13,
"id": "ranking-bottom",
"metadata": {},
"outputs": [
{
"name": "stdout",
"output_type": "stream",
"text": [
"Requirement already satisfied: tensorflow in /home/ccl/.local/lib/python3.9/site-packages (2.10.0)\n",
"Requirement already satisfied: typing-extensions>=3.6.6 in /home/ccl/.local/lib/python3.9/site-packages (from tensorflow) (4.4.0)\n",
"Requirement already satisfied: h5py>=2.9.0 in /home/ccl/.local/lib/python3.9/site-packages (from tensorflow) (3.7.0)\n",
"Requirement already satisfied: tensorflow-io-gcs-filesystem>=0.23.1 in /home/ccl/.local/lib/python3.9/site-packages (from tensorflow) (0.27.0)\n",
"Requirement already satisfied: tensorflow-estimator<2.11,>=2.10.0 in /home/ccl/.local/lib/python3.9/site-packages (from tensorflow) (2.10.0)\n",
"Requirement already satisfied: libclang>=13.0.0 in /home/ccl/.local/lib/python3.9/site-packages (from tensorflow) (14.0.6)\n",
"Requirement already satisfied: wrapt>=1.11.0 in /home/ccl/.local/lib/python3.9/site-packages (from tensorflow) (1.14.1)\n",
"Requirement already satisfied: absl-py>=1.0.0 in /home/ccl/.local/lib/python3.9/site-packages (from tensorflow) (1.3.0)\n",
"Requirement already satisfied: google-pasta>=0.1.1 in /home/ccl/.local/lib/python3.9/site-packages (from tensorflow) (0.2.0)\n",
"Requirement already satisfied: grpcio<2.0,>=1.24.3 in /home/ccl/.local/lib/python3.9/site-packages (from tensorflow) (1.50.0)\n",
"Requirement already satisfied: opt-einsum>=2.3.2 in /home/ccl/.local/lib/python3.9/site-packages (from tensorflow) (3.3.0)\n",
"Requirement already satisfied: setuptools in /usr/lib/python3/dist-packages (from tensorflow) (52.0.0)\n",
"Requirement already satisfied: astunparse>=1.6.0 in /home/ccl/.local/lib/python3.9/site-packages (from tensorflow) (1.6.3)\n",
"Collecting keras<2.11,>=2.10.0\n",
" Using cached keras-2.10.0-py2.py3-none-any.whl (1.7 MB)\n",
"Requirement already satisfied: tensorboard<2.11,>=2.10 in /home/ccl/.local/lib/python3.9/site-packages (from tensorflow) (2.10.1)\n",
"Requirement already satisfied: gast<=0.4.0,>=0.2.1 in /home/ccl/.local/lib/python3.9/site-packages (from tensorflow) (0.4.0)\n",
"Requirement already satisfied: numpy>=1.20 in /home/ccl/.local/lib/python3.9/site-packages (from tensorflow) (1.23.4)\n",
"Requirement already satisfied: six>=1.12.0 in /home/ccl/.local/lib/python3.9/site-packages (from tensorflow) (1.16.0)\n",
"Requirement already satisfied: protobuf<3.20,>=3.9.2 in /home/ccl/.local/lib/python3.9/site-packages (from tensorflow) (3.19.6)\n",
"Requirement already satisfied: packaging in /home/ccl/.local/lib/python3.9/site-packages (from tensorflow) (21.3)\n",
"Requirement already satisfied: termcolor>=1.1.0 in /home/ccl/.local/lib/python3.9/site-packages (from tensorflow) (2.0.1)\n",
"Requirement already satisfied: keras-preprocessing>=1.1.1 in /home/ccl/.local/lib/python3.9/site-packages (from tensorflow) (1.1.2)\n",
"Requirement already satisfied: flatbuffers>=2.0 in /home/ccl/.local/lib/python3.9/site-packages (from tensorflow) (22.9.24)\n",
"Requirement already satisfied: wheel<1.0,>=0.23.0 in /usr/lib/python3/dist-packages (from astunparse>=1.6.0->tensorflow) (0.34.2)\n",
"Requirement already satisfied: requests<3,>=2.21.0 in /usr/lib/python3/dist-packages (from tensorboard<2.11,>=2.10->tensorflow) (2.25.1)\n",
"Requirement already satisfied: tensorboard-data-server<0.7.0,>=0.6.0 in /home/ccl/.local/lib/python3.9/site-packages (from tensorboard<2.11,>=2.10->tensorflow) (0.6.1)\n",
"Requirement already satisfied: werkzeug>=1.0.1 in /home/ccl/.local/lib/python3.9/site-packages (from tensorboard<2.11,>=2.10->tensorflow) (2.0.2)\n",
"Requirement already satisfied: markdown>=2.6.8 in /home/ccl/.local/lib/python3.9/site-packages (from tensorboard<2.11,>=2.10->tensorflow) (3.3.6)\n",
"Requirement already satisfied: google-auth-oauthlib<0.5,>=0.4.1 in /home/ccl/.local/lib/python3.9/site-packages (from tensorboard<2.11,>=2.10->tensorflow) (0.4.6)\n",
"Requirement already satisfied: tensorboard-plugin-wit>=1.6.0 in /home/ccl/.local/lib/python3.9/site-packages (from tensorboard<2.11,>=2.10->tensorflow) (1.8.1)\n",
"Requirement already satisfied: google-auth<3,>=1.6.3 in /home/ccl/.local/lib/python3.9/site-packages (from tensorboard<2.11,>=2.10->tensorflow) (2.13.0)\n",
"Requirement already satisfied: cachetools<6.0,>=2.0.0 in /home/ccl/.local/lib/python3.9/site-packages (from google-auth<3,>=1.6.3->tensorboard<2.11,>=2.10->tensorflow) (5.2.0)\n",
"Requirement already satisfied: pyasn1-modules>=0.2.1 in /usr/lib/python3/dist-packages (from google-auth<3,>=1.6.3->tensorboard<2.11,>=2.10->tensorflow) (0.2.1)\n",
"Requirement already satisfied: rsa<5,>=3.1.4 in /home/ccl/.local/lib/python3.9/site-packages (from google-auth<3,>=1.6.3->tensorboard<2.11,>=2.10->tensorflow) (4.9)\n",
"Requirement already satisfied: requests-oauthlib>=0.7.0 in /home/ccl/.local/lib/python3.9/site-packages (from google-auth-oauthlib<0.5,>=0.4.1->tensorboard<2.11,>=2.10->tensorflow) (1.3.1)\n",
"Requirement already satisfied: importlib-metadata>=4.4 in /home/ccl/.local/lib/python3.9/site-packages (from markdown>=2.6.8->tensorboard<2.11,>=2.10->tensorflow) (5.0.0)\n",
"Requirement already satisfied: zipp>=0.5 in /home/ccl/.local/lib/python3.9/site-packages (from importlib-metadata>=4.4->markdown>=2.6.8->tensorboard<2.11,>=2.10->tensorflow) (3.10.0)\n",
"Requirement already satisfied: oauthlib>=3.0.0 in /home/ccl/.local/lib/python3.9/site-packages (from requests-oauthlib>=0.7.0->google-auth-oauthlib<0.5,>=0.4.1->tensorboard<2.11,>=2.10->tensorflow) (3.2.2)\n",
"Requirement already satisfied: pyasn1>=0.1.3 in /usr/lib/python3/dist-packages (from rsa<5,>=3.1.4->google-auth<3,>=1.6.3->tensorboard<2.11,>=2.10->tensorflow) (0.4.8)\n",
"Requirement already satisfied: pyparsing!=3.0.5,>=2.0.2 in /home/ccl/.local/lib/python3.9/site-packages (from packaging->tensorflow) (3.0.9)\n",
"Installing collected packages: keras\n",
" Attempting uninstall: keras\n",
" Found existing installation: Keras 2.2.5\n",
" Uninstalling Keras-2.2.5:\n",
" Successfully uninstalled Keras-2.2.5\n",
"Successfully installed keras-2.10.0\n",
"Collecting keras==2.2.5\n",
" Using cached Keras-2.2.5-py2.py3-none-any.whl (336 kB)\n",
"Requirement already satisfied: keras-preprocessing>=1.1.0 in /home/ccl/.local/lib/python3.9/site-packages (from keras==2.2.5) (1.1.2)\n",
"Requirement already satisfied: keras-applications>=1.0.8 in /home/ccl/.local/lib/python3.9/site-packages (from keras==2.2.5) (1.0.8)\n",
"Requirement already satisfied: scipy>=0.14 in /home/ccl/.local/lib/python3.9/site-packages (from keras==2.2.5) (1.9.3)\n",
"Requirement already satisfied: h5py in /home/ccl/.local/lib/python3.9/site-packages (from keras==2.2.5) (3.7.0)\n",
"Requirement already satisfied: numpy>=1.9.1 in /home/ccl/.local/lib/python3.9/site-packages (from keras==2.2.5) (1.23.4)\n",
"Requirement already satisfied: pyyaml in /home/ccl/.local/lib/python3.9/site-packages (from keras==2.2.5) (6.0)\n",
"Requirement already satisfied: six>=1.9.0 in /home/ccl/.local/lib/python3.9/site-packages (from keras==2.2.5) (1.16.0)\n",
"Installing collected packages: keras\n",
" Attempting uninstall: keras\n",
" Found existing installation: keras 2.10.0\n",
" Uninstalling keras-2.10.0:\n",
" Successfully uninstalled keras-2.10.0\n",
"\u001b[31mERROR: pip's dependency resolver does not currently take into account all the packages that are installed. This behaviour is the source of the following dependency conflicts.\n",
"tensorflow 2.10.0 requires keras<2.11,>=2.10.0, but you have keras 2.2.5 which is incompatible.\u001b[0m\n",
"Successfully installed keras-2.2.5\n",
"Requirement already satisfied: pincelate in /home/ccl/.local/lib/python3.9/site-packages (0.0.1)\n",
"Requirement already satisfied: scikit-learn>=0.20.0 in /home/ccl/.local/lib/python3.9/site-packages (from pincelate) (1.1.3)\n",
"Requirement already satisfied: Keras>=2.2.0 in /home/ccl/.local/lib/python3.9/site-packages (from pincelate) (2.2.5)\n",
"Requirement already satisfied: pronouncing>=0.2.0 in /home/ccl/.local/lib/python3.9/site-packages (from pincelate) (0.2.0)\n",
"Requirement already satisfied: h5py in /home/ccl/.local/lib/python3.9/site-packages (from Keras>=2.2.0->pincelate) (3.7.0)\n",
"Requirement already satisfied: numpy>=1.9.1 in /home/ccl/.local/lib/python3.9/site-packages (from Keras>=2.2.0->pincelate) (1.23.4)\n",
"Requirement already satisfied: scipy>=0.14 in /home/ccl/.local/lib/python3.9/site-packages (from Keras>=2.2.0->pincelate) (1.9.3)\n",
"Requirement already satisfied: keras-preprocessing>=1.1.0 in /home/ccl/.local/lib/python3.9/site-packages (from Keras>=2.2.0->pincelate) (1.1.2)\n",
"Requirement already satisfied: six>=1.9.0 in /home/ccl/.local/lib/python3.9/site-packages (from Keras>=2.2.0->pincelate) (1.16.0)\n",
"Requirement already satisfied: pyyaml in /home/ccl/.local/lib/python3.9/site-packages (from Keras>=2.2.0->pincelate) (6.0)\n",
"Requirement already satisfied: keras-applications>=1.0.8 in /home/ccl/.local/lib/python3.9/site-packages (from Keras>=2.2.0->pincelate) (1.0.8)\n"
]
},
{
"name": "stdout",
"output_type": "stream",
"text": [
"Requirement already satisfied: cmudict>=0.4.0 in /home/ccl/.local/lib/python3.9/site-packages (from pronouncing>=0.2.0->pincelate) (1.0.2)\n",
"Requirement already satisfied: threadpoolctl>=2.0.0 in /home/ccl/.local/lib/python3.9/site-packages (from scikit-learn>=0.20.0->pincelate) (3.1.0)\n",
"Requirement already satisfied: joblib>=1.0.0 in /home/ccl/.local/lib/python3.9/site-packages (from scikit-learn>=0.20.0->pincelate) (1.1.0)\n"
]
}
],
"source": [
"import sys\n",
"!{sys.executable} -m pip install tensorflow==1.15.0\n",
"!{sys.executable} -m pip install keras==2.2.5\n",
"!{sys.executable} -m pip install pincelate"
]
},
{
"cell_type": "code",
"execution_count": 15,
"id": "polar-modeling",
"metadata": {},
"outputs": [],
"source": [
"from pincelate import Pincelate"
]
},
{
"cell_type": "code",
"execution_count": 22,
"id": "muslim-labor",
"metadata": {},
"outputs": [
{
"ename": "AttributeError",
"evalue": "module 'tensorflow' has no attribute 'placeholder'",
"output_type": "error",
"traceback": [
"\u001b[0;31m---------------------------------------------------------------------------\u001b[0m",
"\u001b[0;31mAttributeError\u001b[0m Traceback (most recent call last)",
"Cell \u001b[0;32mIn [22], line 1\u001b[0m\n\u001b[0;32m----> 1\u001b[0m pin \u001b[38;5;241m=\u001b[39m \u001b[43mPincelate\u001b[49m\u001b[43m(\u001b[49m\u001b[43m)\u001b[49m\n",
"File \u001b[0;32m~/.local/lib/python3.9/site-packages/pincelate/__init__.py:41\u001b[0m, in \u001b[0;36mPincelate.__init__\u001b[0;34m(self, model_path_prefixes)\u001b[0m\n\u001b[1;32m 38\u001b[0m \u001b[38;5;28mself\u001b[39m\u001b[38;5;241m.\u001b[39mphon2orth \u001b[38;5;241m=\u001b[39m Seq2Seq\u001b[38;5;241m.\u001b[39mload(model_path_prefixes[\u001b[38;5;241m1\u001b[39m])\n\u001b[1;32m 39\u001b[0m \u001b[38;5;66;03m# otherwise, use the models in the package\u001b[39;00m\n\u001b[1;32m 40\u001b[0m \u001b[38;5;28;01melse\u001b[39;00m:\n\u001b[0;32m---> 41\u001b[0m \u001b[38;5;28mself\u001b[39m\u001b[38;5;241m.\u001b[39morth2phon \u001b[38;5;241m=\u001b[39m \u001b[43mSeq2Seq\u001b[49m\u001b[38;5;241;43m.\u001b[39;49m\u001b[43mload_from_package\u001b[49m\u001b[43m(\u001b[49m\n\u001b[1;32m 42\u001b[0m \u001b[43m \u001b[49m\u001b[38;5;124;43m'\u001b[39;49m\u001b[38;5;124;43mmodels/orth-phon-enc256-dec256\u001b[39;49m\u001b[38;5;124;43m'\u001b[39;49m\u001b[43m)\u001b[49m\n\u001b[1;32m 43\u001b[0m \u001b[38;5;28mself\u001b[39m\u001b[38;5;241m.\u001b[39mphon2orth \u001b[38;5;241m=\u001b[39m Seq2Seq\u001b[38;5;241m.\u001b[39mload_from_package(\n\u001b[1;32m 44\u001b[0m \u001b[38;5;124m'\u001b[39m\u001b[38;5;124mmodels/phon-orth-enc256-dec256\u001b[39m\u001b[38;5;124m'\u001b[39m)\n\u001b[1;32m 46\u001b[0m \u001b[38;5;66;03m# looking up the closest arpabet phonemes when sounding out\u001b[39;00m\n",
"File \u001b[0;32m~/.local/lib/python3.9/site-packages/pincelate/seq2seq.py:183\u001b[0m, in \u001b[0;36mSeq2Seq.load_from_package\u001b[0;34m(cls, prefix)\u001b[0m\n\u001b[1;32m 181\u001b[0m obj_data \u001b[38;5;241m=\u001b[39m pickle\u001b[38;5;241m.\u001b[39mload(fh)\n\u001b[1;32m 182\u001b[0m obj \u001b[38;5;241m=\u001b[39m \u001b[38;5;28mcls\u001b[39m(\u001b[38;5;241m*\u001b[39m\u001b[38;5;241m*\u001b[39mobj_data)\n\u001b[0;32m--> 183\u001b[0m \u001b[43mobj\u001b[49m\u001b[38;5;241;43m.\u001b[39;49m\u001b[43mmake_models\u001b[49m\u001b[43m(\u001b[49m\u001b[43m)\u001b[49m\n\u001b[1;32m 184\u001b[0m \u001b[38;5;28;01mwith\u001b[39;00m rs(\u001b[38;5;18m__name__\u001b[39m, prefix \u001b[38;5;241m+\u001b[39m \u001b[38;5;124m\"\u001b[39m\u001b[38;5;124m-training.h5\u001b[39m\u001b[38;5;124m\"\u001b[39m) \u001b[38;5;28;01mas\u001b[39;00m fh:\n\u001b[1;32m 185\u001b[0m obj\u001b[38;5;241m.\u001b[39mtraining_model\u001b[38;5;241m.\u001b[39mload_weights(fh)\n",
"File \u001b[0;32m~/.local/lib/python3.9/site-packages/pincelate/seq2seq.py:40\u001b[0m, in \u001b[0;36mSeq2Seq.make_models\u001b[0;34m(self)\u001b[0m\n\u001b[1;32m 34\u001b[0m \u001b[38;5;28;01mdef\u001b[39;00m \u001b[38;5;21mmake_models\u001b[39m(\u001b[38;5;28mself\u001b[39m):\n\u001b[1;32m 35\u001b[0m \n\u001b[1;32m 36\u001b[0m \u001b[38;5;66;03m#\u001b[39;00m\n\u001b[1;32m 37\u001b[0m \u001b[38;5;66;03m# training models\u001b[39;00m\n\u001b[1;32m 38\u001b[0m \u001b[38;5;66;03m#\u001b[39;00m\n\u001b[0;32m---> 40\u001b[0m training_encoder_inputs \u001b[38;5;241m=\u001b[39m \u001b[43mInput\u001b[49m\u001b[43m(\u001b[49m\n\u001b[1;32m 41\u001b[0m \u001b[43m \u001b[49m\u001b[43mshape\u001b[49m\u001b[38;5;241;43m=\u001b[39;49m\u001b[43m(\u001b[49m\u001b[38;5;28;43;01mNone\u001b[39;49;00m\u001b[43m,\u001b[49m\u001b[43m \u001b[49m\u001b[38;5;28;43mlen\u001b[39;49m\u001b[43m(\u001b[49m\u001b[38;5;28;43mself\u001b[39;49m\u001b[38;5;241;43m.\u001b[39;49m\u001b[43msrc_vocab\u001b[49m\u001b[43m)\u001b[49m\u001b[43m)\u001b[49m\u001b[43m,\u001b[49m\n\u001b[1;32m 42\u001b[0m \u001b[43m \u001b[49m\u001b[43mname\u001b[49m\u001b[38;5;241;43m=\u001b[39;49m\u001b[38;5;124;43m'\u001b[39;49m\u001b[38;5;124;43mtraining_encoder_inputs\u001b[39;49m\u001b[38;5;124;43m'\u001b[39;49m\n\u001b[1;32m 43\u001b[0m \u001b[43m \u001b[49m\u001b[43m)\u001b[49m\n\u001b[1;32m 45\u001b[0m \u001b[38;5;66;03m# masking to exclude zero-padding in loss/accuracy calculation\u001b[39;00m\n\u001b[1;32m 46\u001b[0m training_encoder_mask \u001b[38;5;241m=\u001b[39m Masking(\n\u001b[1;32m 47\u001b[0m \u001b[38;5;241m0.0\u001b[39m,\n\u001b[1;32m 48\u001b[0m name\u001b[38;5;241m=\u001b[39m\u001b[38;5;124m'\u001b[39m\u001b[38;5;124mtraining_encoder_mask\u001b[39m\u001b[38;5;124m'\u001b[39m)(training_encoder_inputs)\n",
"File \u001b[0;32m~/.local/lib/python3.9/site-packages/keras/engine/input_layer.py:175\u001b[0m, in \u001b[0;36mInput\u001b[0;34m(shape, batch_shape, name, dtype, sparse, tensor)\u001b[0m\n\u001b[1;32m 173\u001b[0m \u001b[38;5;28;01mif\u001b[39;00m \u001b[38;5;129;01mnot\u001b[39;00m dtype:\n\u001b[1;32m 174\u001b[0m dtype \u001b[38;5;241m=\u001b[39m K\u001b[38;5;241m.\u001b[39mfloatx()\n\u001b[0;32m--> 175\u001b[0m input_layer \u001b[38;5;241m=\u001b[39m \u001b[43mInputLayer\u001b[49m\u001b[43m(\u001b[49m\u001b[43mbatch_input_shape\u001b[49m\u001b[38;5;241;43m=\u001b[39;49m\u001b[43mbatch_shape\u001b[49m\u001b[43m,\u001b[49m\n\u001b[1;32m 176\u001b[0m \u001b[43m \u001b[49m\u001b[43mname\u001b[49m\u001b[38;5;241;43m=\u001b[39;49m\u001b[43mname\u001b[49m\u001b[43m,\u001b[49m\u001b[43m \u001b[49m\u001b[43mdtype\u001b[49m\u001b[38;5;241;43m=\u001b[39;49m\u001b[43mdtype\u001b[49m\u001b[43m,\u001b[49m\n\u001b[1;32m 177\u001b[0m \u001b[43m \u001b[49m\u001b[43msparse\u001b[49m\u001b[38;5;241;43m=\u001b[39;49m\u001b[43msparse\u001b[49m\u001b[43m,\u001b[49m\n\u001b[1;32m 178\u001b[0m \u001b[43m \u001b[49m\u001b[43minput_tensor\u001b[49m\u001b[38;5;241;43m=\u001b[39;49m\u001b[43mtensor\u001b[49m\u001b[43m)\u001b[49m\n\u001b[1;32m 179\u001b[0m \u001b[38;5;66;03m# Return tensor including _keras_shape and _keras_history.\u001b[39;00m\n\u001b[1;32m 180\u001b[0m \u001b[38;5;66;03m# Note that in this case train_output and test_output are the same pointer.\u001b[39;00m\n\u001b[1;32m 181\u001b[0m outputs \u001b[38;5;241m=\u001b[39m input_layer\u001b[38;5;241m.\u001b[39m_inbound_nodes[\u001b[38;5;241m0\u001b[39m]\u001b[38;5;241m.\u001b[39moutput_tensors\n",
"File \u001b[0;32m~/.local/lib/python3.9/site-packages/keras/legacy/interfaces.py:91\u001b[0m, in \u001b[0;36mgenerate_legacy_interface.<locals>.legacy_support.<locals>.wrapper\u001b[0;34m(*args, **kwargs)\u001b[0m\n\u001b[1;32m 88\u001b[0m signature \u001b[38;5;241m+\u001b[39m\u001b[38;5;241m=\u001b[39m \u001b[38;5;124m'\u001b[39m\u001b[38;5;124m)`\u001b[39m\u001b[38;5;124m'\u001b[39m\n\u001b[1;32m 89\u001b[0m warnings\u001b[38;5;241m.\u001b[39mwarn(\u001b[38;5;124m'\u001b[39m\u001b[38;5;124mUpdate your `\u001b[39m\u001b[38;5;124m'\u001b[39m \u001b[38;5;241m+\u001b[39m object_name \u001b[38;5;241m+\u001b[39m \u001b[38;5;124m'\u001b[39m\u001b[38;5;124m` call to the \u001b[39m\u001b[38;5;124m'\u001b[39m \u001b[38;5;241m+\u001b[39m\n\u001b[1;32m 90\u001b[0m \u001b[38;5;124m'\u001b[39m\u001b[38;5;124mKeras 2 API: \u001b[39m\u001b[38;5;124m'\u001b[39m \u001b[38;5;241m+\u001b[39m signature, stacklevel\u001b[38;5;241m=\u001b[39m\u001b[38;5;241m2\u001b[39m)\n\u001b[0;32m---> 91\u001b[0m \u001b[38;5;28;01mreturn\u001b[39;00m \u001b[43mfunc\u001b[49m\u001b[43m(\u001b[49m\u001b[38;5;241;43m*\u001b[39;49m\u001b[43margs\u001b[49m\u001b[43m,\u001b[49m\u001b[43m \u001b[49m\u001b[38;5;241;43m*\u001b[39;49m\u001b[38;5;241;43m*\u001b[39;49m\u001b[43mkwargs\u001b[49m\u001b[43m)\u001b[49m\n",
"File \u001b[0;32m~/.local/lib/python3.9/site-packages/keras/engine/input_layer.py:84\u001b[0m, in \u001b[0;36mInputLayer.__init__\u001b[0;34m(self, input_shape, batch_size, batch_input_shape, dtype, input_tensor, sparse, name)\u001b[0m\n\u001b[1;32m 82\u001b[0m \u001b[38;5;28;01mif\u001b[39;00m input_tensor \u001b[38;5;129;01mis\u001b[39;00m \u001b[38;5;28;01mNone\u001b[39;00m:\n\u001b[1;32m 83\u001b[0m \u001b[38;5;28mself\u001b[39m\u001b[38;5;241m.\u001b[39mis_placeholder \u001b[38;5;241m=\u001b[39m \u001b[38;5;28;01mTrue\u001b[39;00m\n\u001b[0;32m---> 84\u001b[0m input_tensor \u001b[38;5;241m=\u001b[39m \u001b[43mK\u001b[49m\u001b[38;5;241;43m.\u001b[39;49m\u001b[43mplaceholder\u001b[49m\u001b[43m(\u001b[49m\u001b[43mshape\u001b[49m\u001b[38;5;241;43m=\u001b[39;49m\u001b[43mbatch_input_shape\u001b[49m\u001b[43m,\u001b[49m\n\u001b[1;32m 85\u001b[0m \u001b[43m \u001b[49m\u001b[43mdtype\u001b[49m\u001b[38;5;241;43m=\u001b[39;49m\u001b[43mdtype\u001b[49m\u001b[43m,\u001b[49m\n\u001b[1;32m 86\u001b[0m \u001b[43m \u001b[49m\u001b[43msparse\u001b[49m\u001b[38;5;241;43m=\u001b[39;49m\u001b[38;5;28;43mself\u001b[39;49m\u001b[38;5;241;43m.\u001b[39;49m\u001b[43msparse\u001b[49m\u001b[43m,\u001b[49m\n\u001b[1;32m 87\u001b[0m \u001b[43m \u001b[49m\u001b[43mname\u001b[49m\u001b[38;5;241;43m=\u001b[39;49m\u001b[38;5;28;43mself\u001b[39;49m\u001b[38;5;241;43m.\u001b[39;49m\u001b[43mname\u001b[49m\u001b[43m)\u001b[49m\n\u001b[1;32m 88\u001b[0m \u001b[38;5;28;01melse\u001b[39;00m:\n\u001b[1;32m 89\u001b[0m \u001b[38;5;28mself\u001b[39m\u001b[38;5;241m.\u001b[39mis_placeholder \u001b[38;5;241m=\u001b[39m \u001b[38;5;28;01mFalse\u001b[39;00m\n",
"File \u001b[0;32m~/.local/lib/python3.9/site-packages/keras/backend/tensorflow_backend.py:541\u001b[0m, in \u001b[0;36mplaceholder\u001b[0;34m(shape, ndim, dtype, sparse, name)\u001b[0m\n\u001b[1;32m 539\u001b[0m x \u001b[38;5;241m=\u001b[39m tf\u001b[38;5;241m.\u001b[39msparse_placeholder(dtype, shape\u001b[38;5;241m=\u001b[39mshape, name\u001b[38;5;241m=\u001b[39mname)\n\u001b[1;32m 540\u001b[0m \u001b[38;5;28;01melse\u001b[39;00m:\n\u001b[0;32m--> 541\u001b[0m x \u001b[38;5;241m=\u001b[39m \u001b[43mtf\u001b[49m\u001b[38;5;241;43m.\u001b[39;49m\u001b[43mplaceholder\u001b[49m(dtype, shape\u001b[38;5;241m=\u001b[39mshape, name\u001b[38;5;241m=\u001b[39mname)\n\u001b[1;32m 542\u001b[0m x\u001b[38;5;241m.\u001b[39m_keras_shape \u001b[38;5;241m=\u001b[39m shape\n\u001b[1;32m 543\u001b[0m x\u001b[38;5;241m.\u001b[39m_uses_learning_phase \u001b[38;5;241m=\u001b[39m \u001b[38;5;28;01mFalse\u001b[39;00m\n",
"\u001b[0;31mAttributeError\u001b[0m: module 'tensorflow' has no attribute 'placeholder'"
]
}
],
"source": [
"pin = Pincelate()\n"
]
},
{
"cell_type": "code",
"execution_count": null,
"id": "graphic-appearance",
"metadata": {},
"outputs": [],
"source": []
}
],
"metadata": {
"kernelspec": {
"display_name": "Python 3 (ipykernel)",
"language": "python",
"name": "python3"
},
"language_info": {
"codemirror_mode": {
"name": "ipython",
"version": 3
},
"file_extension": ".py",
"mimetype": "text/x-python",
"name": "python",
"nbconvert_exporter": "python",
"pygments_lexer": "ipython3",
"version": "3.9.2"
}
},
"nbformat": 4,
"nbformat_minor": 5
}

248
pincelate.ipynb

@ -0,0 +1,248 @@
{
"cells": [
{
"cell_type": "code",
"execution_count": 1,
"id": "north-steering",
"metadata": {},
"outputs": [
{
"name": "stdout",
"output_type": "stream",
"text": [
"pip 20.3.4 from /usr/lib/python3/dist-packages/pip (python 3.9)\n",
"Note: you may need to restart the kernel to use updated packages.\n"
]
}
],
"source": [
"pip -V"
]
},
{
"cell_type": "code",
"execution_count": 2,
"id": "ranking-bottom",
"metadata": {},
"outputs": [
{
"name": "stdout",
"output_type": "stream",
"text": [
"Requirement already satisfied: tensorflow==1.15.5 in ./pocket/lib/python3.6/site-packages (1.15.5)\n",
"Requirement already satisfied: opt-einsum>=2.3.2 in ./pocket/lib/python3.6/site-packages (from tensorflow==1.15.5) (3.3.0)\n",
"Requirement already satisfied: protobuf>=3.6.1 in ./pocket/lib/python3.6/site-packages (from tensorflow==1.15.5) (3.19.6)\n",
"Requirement already satisfied: wrapt>=1.11.1 in ./pocket/lib/python3.6/site-packages (from tensorflow==1.15.5) (1.14.1)\n",
"Requirement already satisfied: tensorflow-estimator==1.15.1 in ./pocket/lib/python3.6/site-packages (from tensorflow==1.15.5) (1.15.1)\n",
"Requirement already satisfied: six>=1.10.0 in ./pocket/lib/python3.6/site-packages (from tensorflow==1.15.5) (1.16.0)\n",
"Requirement already satisfied: gast==0.2.2 in ./pocket/lib/python3.6/site-packages (from tensorflow==1.15.5) (0.2.2)\n",
"Requirement already satisfied: keras-preprocessing>=1.0.5 in ./pocket/lib/python3.6/site-packages (from tensorflow==1.15.5) (1.1.2)\n",
"Requirement already satisfied: wheel>=0.26 in ./pocket/lib/python3.6/site-packages (from tensorflow==1.15.5) (0.37.1)\n",
"Requirement already satisfied: tensorboard<1.16.0,>=1.15.0 in ./pocket/lib/python3.6/site-packages (from tensorflow==1.15.5) (1.15.0)\n",
"Requirement already satisfied: keras-applications>=1.0.8 in ./pocket/lib/python3.6/site-packages (from tensorflow==1.15.5) (1.0.8)\n",
"Requirement already satisfied: h5py<=2.10.0 in ./pocket/lib/python3.6/site-packages (from tensorflow==1.15.5) (2.10.0)\n",
"Requirement already satisfied: numpy<1.19.0,>=1.16.0 in ./pocket/lib/python3.6/site-packages (from tensorflow==1.15.5) (1.18.5)\n",
"Requirement already satisfied: google-pasta>=0.1.6 in ./pocket/lib/python3.6/site-packages (from tensorflow==1.15.5) (0.2.0)\n",
"Requirement already satisfied: absl-py>=0.7.0 in ./pocket/lib/python3.6/site-packages (from tensorflow==1.15.5) (1.3.0)\n",
"Requirement already satisfied: termcolor>=1.1.0 in ./pocket/lib/python3.6/site-packages (from tensorflow==1.15.5) (1.1.0)\n",
"Requirement already satisfied: astor>=0.6.0 in ./pocket/lib/python3.6/site-packages (from tensorflow==1.15.5) (0.8.1)\n",
"Requirement already satisfied: grpcio>=1.8.6 in ./pocket/lib/python3.6/site-packages (from tensorflow==1.15.5) (1.48.2)\n",
"Requirement already satisfied: werkzeug>=0.11.15 in ./pocket/lib/python3.6/site-packages (from tensorboard<1.16.0,>=1.15.0->tensorflow==1.15.5) (2.0.3)\n",
"Requirement already satisfied: markdown>=2.6.8 in ./pocket/lib/python3.6/site-packages (from tensorboard<1.16.0,>=1.15.0->tensorflow==1.15.5) (3.3.7)\n",
"Requirement already satisfied: setuptools>=41.0.0 in ./pocket/lib/python3.6/site-packages (from tensorboard<1.16.0,>=1.15.0->tensorflow==1.15.5) (59.6.0)\n",
"Requirement already satisfied: importlib-metadata>=4.4 in ./pocket/lib/python3.6/site-packages (from markdown>=2.6.8->tensorboard<1.16.0,>=1.15.0->tensorflow==1.15.5) (4.8.3)\n",
"Requirement already satisfied: dataclasses in ./pocket/lib/python3.6/site-packages (from werkzeug>=0.11.15->tensorboard<1.16.0,>=1.15.0->tensorflow==1.15.5) (0.8)\n",
"Requirement already satisfied: zipp>=0.5 in ./pocket/lib/python3.6/site-packages (from importlib-metadata>=4.4->markdown>=2.6.8->tensorboard<1.16.0,>=1.15.0->tensorflow==1.15.5) (3.6.0)\n",
"Requirement already satisfied: typing-extensions>=3.6.4 in ./pocket/lib/python3.6/site-packages (from importlib-metadata>=4.4->markdown>=2.6.8->tensorboard<1.16.0,>=1.15.0->tensorflow==1.15.5) (4.1.1)\n",
"Requirement already satisfied: keras==2.2.5 in ./pocket/lib/python3.6/site-packages (2.2.5)\n",
"Requirement already satisfied: six>=1.9.0 in ./pocket/lib/python3.6/site-packages (from keras==2.2.5) (1.16.0)\n",
"Requirement already satisfied: pyyaml in ./pocket/lib/python3.6/site-packages (from keras==2.2.5) (6.0)\n",
"Requirement already satisfied: numpy>=1.9.1 in ./pocket/lib/python3.6/site-packages (from keras==2.2.5) (1.18.5)\n",
"Requirement already satisfied: scipy>=0.14 in ./pocket/lib/python3.6/site-packages (from keras==2.2.5) (1.5.4)\n",
"Requirement already satisfied: h5py in ./pocket/lib/python3.6/site-packages (from keras==2.2.5) (2.10.0)\n",
"Requirement already satisfied: keras-applications>=1.0.8 in ./pocket/lib/python3.6/site-packages (from keras==2.2.5) (1.0.8)\n",
"Requirement already satisfied: keras-preprocessing>=1.1.0 in ./pocket/lib/python3.6/site-packages (from keras==2.2.5) (1.1.2)\n",
"Requirement already satisfied: pincelate in ./pocket/lib/python3.6/site-packages (0.0.1)\n",
"Requirement already satisfied: Keras>=2.2.0 in ./pocket/lib/python3.6/site-packages (from pincelate) (2.2.5)\n",
"Requirement already satisfied: pronouncing>=0.2.0 in ./pocket/lib/python3.6/site-packages (from pincelate) (0.2.0)\n",
"Requirement already satisfied: scikit-learn>=0.20.0 in ./pocket/lib/python3.6/site-packages (from pincelate) (0.24.2)\n",
"Requirement already satisfied: scipy>=0.14 in ./pocket/lib/python3.6/site-packages (from Keras>=2.2.0->pincelate) (1.5.4)\n",
"Requirement already satisfied: h5py in ./pocket/lib/python3.6/site-packages (from Keras>=2.2.0->pincelate) (2.10.0)\n",
"Requirement already satisfied: six>=1.9.0 in ./pocket/lib/python3.6/site-packages (from Keras>=2.2.0->pincelate) (1.16.0)\n",
"Requirement already satisfied: pyyaml in ./pocket/lib/python3.6/site-packages (from Keras>=2.2.0->pincelate) (6.0)\n",
"Requirement already satisfied: keras-applications>=1.0.8 in ./pocket/lib/python3.6/site-packages (from Keras>=2.2.0->pincelate) (1.0.8)\n",
"Requirement already satisfied: numpy>=1.9.1 in ./pocket/lib/python3.6/site-packages (from Keras>=2.2.0->pincelate) (1.18.5)\n",
"Requirement already satisfied: keras-preprocessing>=1.1.0 in ./pocket/lib/python3.6/site-packages (from Keras>=2.2.0->pincelate) (1.1.2)\n",
"Requirement already satisfied: cmudict>=0.4.0 in ./pocket/lib/python3.6/site-packages (from pronouncing>=0.2.0->pincelate) (1.0.2)\n",
"Requirement already satisfied: threadpoolctl>=2.0.0 in ./pocket/lib/python3.6/site-packages (from scikit-learn>=0.20.0->pincelate) (3.1.0)\n",
"Requirement already satisfied: joblib>=0.11 in ./pocket/lib/python3.6/site-packages (from scikit-learn>=0.20.0->pincelate) (1.1.1)\n"
]
}
],
"source": [
"import sys\n",
"!{sys.executable} -m pip install tensorflow==1.15.5\n",
"!{sys.executable} -m pip install keras==2.2.5\n",
"!{sys.executable} -m pip install pincelate"
]
},
{
"cell_type": "code",
"execution_count": 3,
"id": "polar-modeling",
"metadata": {},
"outputs": [
{
"name": "stderr",
"output_type": "stream",
"text": [
"Using TensorFlow backend.\n"
]
}
],
"source": [
"from pincelate import Pincelate"
]
},
{
"cell_type": "code",
"execution_count": 4,
"id": "9d01f6ee",
"metadata": {},
"outputs": [],
"source": [
"import ipywidgets as widgets\n",
"from IPython.display import display,HTML\n",
"from ipywidgets import interact,interactive_output,Layout,HBox,VBox"
]
},
{
"cell_type": "code",
"execution_count": 5,
"id": "muslim-labor",
"metadata": {},
"outputs": [
{
"name": "stdout",
"output_type": "stream",
"text": [
"WARNING:tensorflow:From /home/angeliki/Documents/Any_One_day_future/A_tune_in/pocket/lib/python3.6/site-packages/keras/backend/tensorflow_backend.py:541: The name tf.placeholder is deprecated. Please use tf.compat.v1.placeholder instead.\n",
"\n",
"WARNING:tensorflow:From /home/angeliki/Documents/Any_One_day_future/A_tune_in/pocket/lib/python3.6/site-packages/keras/backend/tensorflow_backend.py:66: The name tf.get_default_graph is deprecated. Please use tf.compat.v1.get_default_graph instead.\n",
"\n",
"WARNING:tensorflow:From /home/angeliki/Documents/Any_One_day_future/A_tune_in/pocket/lib/python3.6/site-packages/keras/backend/tensorflow_backend.py:4432: The name tf.random_uniform is deprecated. Please use tf.random.uniform instead.\n",
"\n",
"WARNING:tensorflow:From /home/angeliki/Documents/Any_One_day_future/A_tune_in/pocket/lib/python3.6/site-packages/keras/backend/tensorflow_backend.py:148: The name tf.placeholder_with_default is deprecated. Please use tf.compat.v1.placeholder_with_default instead.\n",
"\n",
"WARNING:tensorflow:From /home/angeliki/Documents/Any_One_day_future/A_tune_in/pocket/lib/python3.6/site-packages/keras/backend/tensorflow_backend.py:3733: calling dropout (from tensorflow.python.ops.nn_ops) with keep_prob is deprecated and will be removed in a future version.\n",
"Instructions for updating:\n",
"Please use `rate` instead of `keep_prob`. Rate should be set to `rate = 1 - keep_prob`.\n",
"WARNING:tensorflow:From /home/angeliki/Documents/Any_One_day_future/A_tune_in/pocket/lib/python3.6/site-packages/keras/backend/tensorflow_backend.py:3239: where (from tensorflow.python.ops.array_ops) is deprecated and will be removed in a future version.\n",
"Instructions for updating:\n",
"Use tf.where in 2.0, which has the same broadcast rule as np.where\n",
"WARNING:tensorflow:From /home/angeliki/Documents/Any_One_day_future/A_tune_in/pocket/lib/python3.6/site-packages/keras/backend/tensorflow_backend.py:190: The name tf.get_default_session is deprecated. Please use tf.compat.v1.get_default_session instead.\n",
"\n",
"WARNING:tensorflow:From /home/angeliki/Documents/Any_One_day_future/A_tune_in/pocket/lib/python3.6/site-packages/keras/backend/tensorflow_backend.py:197: The name tf.ConfigProto is deprecated. Please use tf.compat.v1.ConfigProto instead.\n",
"\n",
"WARNING:tensorflow:From /home/angeliki/Documents/Any_One_day_future/A_tune_in/pocket/lib/python3.6/site-packages/keras/backend/tensorflow_backend.py:203: The name tf.Session is deprecated. Please use tf.compat.v1.Session instead.\n",
"\n",
"WARNING:tensorflow:From /home/angeliki/Documents/Any_One_day_future/A_tune_in/pocket/lib/python3.6/site-packages/keras/backend/tensorflow_backend.py:207: The name tf.global_variables is deprecated. Please use tf.compat.v1.global_variables instead.\n",
"\n",
"WARNING:tensorflow:From /home/angeliki/Documents/Any_One_day_future/A_tune_in/pocket/lib/python3.6/site-packages/keras/backend/tensorflow_backend.py:216: The name tf.is_variable_initialized is deprecated. Please use tf.compat.v1.is_variable_initialized instead.\n",
"\n",
"WARNING:tensorflow:From /home/angeliki/Documents/Any_One_day_future/A_tune_in/pocket/lib/python3.6/site-packages/keras/backend/tensorflow_backend.py:223: The name tf.variables_initializer is deprecated. Please use tf.compat.v1.variables_initializer instead.\n",
"\n"
]
}
],
"source": [
"pin = Pincelate()\n"
]
},
{
"cell_type": "code",
"execution_count": 7,
"id": "graphic-appearance",
"metadata": {},
"outputs": [
{
"data": {
"text/plain": [
"'speblingue'"
]
},
"execution_count": 7,
"metadata": {},
"output_type": "execute_result"
}
],
"source": [
"pin.manipulate(\"spelling\",temperature=1.5)"
]
},
{
"cell_type": "code",
"execution_count": null,
"id": "361fe610",
"metadata": {},
"outputs": [],
"source": []
},
{
"cell_type": "code",
"execution_count": 8,
"id": "b648b5ae",
"metadata": {},
"outputs": [
{
"data": {
"application/vnd.jupyter.widget-view+json": {
"model_id": "0940444627934c01ba4c2252a25b8568",
"version_major": 2,
"version_minor": 0
},
"text/plain": [
"interactive(children=(Text(value='any one future died', description='s'), FloatSlider(value=1.2500000000000002…"
]
},
"metadata": {},
"output_type": "display_data"
}
],
"source": [
"@interact(s=\"any one future died\",temp=(0.05,2.5,0.05))\n",
"def tempadjust(s,temp):\n",
" return ' '.join([pin.manipulate(w.lower(),temperature=temp) for w in s.split()])"
]
},
{
"cell_type": "code",
"execution_count": null,
"id": "e4717967",
"metadata": {},
"outputs": [],
"source": []
}
],
"metadata": {
"kernelspec": {
"display_name": "Python 3",
"language": "python",
"name": "python3"
},
"language_info": {
"codemirror_mode": {
"name": "ipython",
"version": 3
},
"file_extension": ".py",
"mimetype": "text/x-python",
"name": "python",
"nbconvert_exporter": "python",
"pygments_lexer": "ipython3",
"version": "3.6.9"
}
},
"nbformat": 4,
"nbformat_minor": 5
}
Loading…
Cancel
Save