Monday, September 19, 2022

Installing Rasa 3.2.8 on Ubuntu using Conda

Contents of env.yml

name: rasa_py38 channels: - conda-forge dependencies: - python=3.8 - pip - spacy (base) ashish@ashish-Lenovo-ideapad-130-15IKB:~/Desktop$ conda env create -f env.yml Collecting package metadata (repodata.json): done Solving environment: done ==> WARNING: A newer version of conda exists. <== current version: 4.12.0 latest version: 4.14.0 Please update conda by running $ conda update -n base -c defaults conda Downloading and Extracting Packages libsqlite-3.39.3 | 789 KB | ### | 100% numpy-1.23.3 | 7.1 MB | ### | 100% dataclasses-0.8 | 10 KB | ### | 100% pathy-0.6.2 | 38 KB | ### | 100% srsly-2.4.4 | 540 KB | ### | 100% sqlite-3.39.3 | 789 KB | ### | 100% python-3.8.13 | 25.1 MB | ### | 100% markupsafe-2.1.1 | 22 KB | ### | 100% spacy-loggers-1.0.3 | 13 KB | ### | 100% cython-blis-0.7.8 | 9.0 MB | ### | 100% cymem-2.0.6 | 42 KB | ### | 100% cffi-1.15.1 | 229 KB | ### | 100% click-8.1.3 | 146 KB | ### | 100% langcodes-3.3.0 | 156 KB | ### | 100% cryptography-37.0.4 | 1.5 MB | ### | 100% tqdm-4.64.1 | 82 KB | ### | 100% shellingham-1.5.0 | 12 KB | ### | 100% brotlipy-0.7.0 | 342 KB | ### | 100% spacy-3.4.1 | 6.4 MB | ### | 100% preshed-3.0.7 | 122 KB | ### | 100% wasabi-0.10.0 | 26 KB | ### | 100% python_abi-3.8 | 4 KB | ### | 100% libzlib-1.2.12 | 65 KB | ### | 100% smart_open-5.2.1 | 43 KB | ### | 100% thinc-8.1.0 | 904 KB | ### | 100% typer-0.4.2 | 45 KB | ### | 100% pydantic-1.9.2 | 2.4 MB | ### | 100% spacy-legacy-3.0.10 | 20 KB | ### | 100% catalogue-2.0.8 | 32 KB | ### | 100% murmurhash-1.0.8 | 27 KB | ### | 100% libopenblas-0.3.21 | 10.1 MB | ### | 100% Preparing transaction: done Verifying transaction: done Executing transaction: done # # To activate this environment, use # # $ conda activate rasa_py38 # # To deactivate an active environment, use # # $ conda deactivate (base) ashish@ashish-Lenovo-ideapad-130-15IKB:~/Desktop$ (base) ashish@ashish-Lenovo-ideapad-130-15IKB:~/Desktop$ conda activate rasa_py38 (rasa_py38) ashish@ashish-Lenovo-ideapad-130-15IKB:~/Desktop$ conda install ipykernel jupyterlab -c conda-forge Collecting package metadata (current_repodata.json): done Solving environment: done ==> WARNING: A newer version of conda exists. <== current version: 4.12.0 latest version: 4.14.0 Please update conda by running $ conda update -n base -c defaults conda ## Package Plan ## environment location: /home/ashish/anaconda3/envs/rasa_py38 added / updated specs: - ipykernel - jupyterlab The following packages will be downloaded: package | build ---------------------------|----------------- argon2-cffi-bindings-21.2.0| py38h0a891b7_2 34 KB conda-forge debugpy-1.6.3 | py38hfa26641_0 2.0 MB conda-forge importlib-metadata-4.11.4 | py38h578d9bd_0 33 KB conda-forge ipykernel-6.15.3 | pyh210e3f2_0 99 KB conda-forge ipython-8.5.0 | pyh41d4057_1 552 KB conda-forge jsonschema-4.16.0 | pyhd8ed1ab_0 65 KB conda-forge jupyter_core-4.11.1 | py38h578d9bd_0 81 KB conda-forge jupyterlab-3.4.7 | pyhd8ed1ab_0 5.9 MB conda-forge lxml-4.9.1 | py38h0a891b7_0 1.4 MB conda-forge nbclient-0.6.8 | pyhd8ed1ab_0 65 KB conda-forge nbformat-5.5.0 | pyhd8ed1ab_0 105 KB conda-forge prompt-toolkit-3.0.31 | pyha770c72_0 254 KB conda-forge psutil-5.9.2 | py38h0a891b7_0 346 KB conda-forge pyrsistent-0.18.1 | py38h0a891b7_1 92 KB conda-forge pyzmq-24.0.0 | py38hfc09fa9_0 499 KB conda-forge terminado-0.15.0 | py38h578d9bd_0 28 KB conda-forge tomli-2.0.1 | pyhd8ed1ab_0 16 KB conda-forge tornado-6.2 | py38h0a891b7_0 653 KB conda-forge traitlets-5.4.0 | pyhd8ed1ab_0 85 KB conda-forge ------------------------------------------------------------ Total: 12.3 MB The following NEW packages will be INSTALLED: anyio conda-forge/noarch::anyio-3.6.1-pyhd8ed1ab_1 argon2-cffi conda-forge/noarch::argon2-cffi-21.3.0-pyhd8ed1ab_0 argon2-cffi-bindi~ conda-forge/linux-64::argon2-cffi-bindings-21.2.0-py38h0a891b7_2 asttokens conda-forge/noarch::asttokens-2.0.8-pyhd8ed1ab_0 attrs conda-forge/noarch::attrs-22.1.0-pyh71513ae_1 babel conda-forge/noarch::babel-2.10.3-pyhd8ed1ab_0 backcall conda-forge/noarch::backcall-0.2.0-pyh9f0ad1d_0 backports conda-forge/noarch::backports-1.0-py_2 backports.functoo~ conda-forge/noarch::backports.functools_lru_cache-1.6.4-pyhd8ed1ab_0 beautifulsoup4 conda-forge/noarch::beautifulsoup4-4.11.1-pyha770c72_0 bleach conda-forge/noarch::bleach-5.0.1-pyhd8ed1ab_0 debugpy conda-forge/linux-64::debugpy-1.6.3-py38hfa26641_0 decorator conda-forge/noarch::decorator-5.1.1-pyhd8ed1ab_0 defusedxml conda-forge/noarch::defusedxml-0.7.1-pyhd8ed1ab_0 entrypoints conda-forge/noarch::entrypoints-0.4-pyhd8ed1ab_0 executing conda-forge/noarch::executing-1.0.0-pyhd8ed1ab_0 flit-core conda-forge/noarch::flit-core-3.7.1-pyhd8ed1ab_0 icu conda-forge/linux-64::icu-70.1-h27087fc_0 importlib-metadata conda-forge/linux-64::importlib-metadata-4.11.4-py38h578d9bd_0 importlib_metadata conda-forge/noarch::importlib_metadata-4.11.4-hd8ed1ab_0 importlib_resourc~ conda-forge/noarch::importlib_resources-5.9.0-pyhd8ed1ab_0 ipykernel conda-forge/noarch::ipykernel-6.15.3-pyh210e3f2_0 ipython conda-forge/noarch::ipython-8.5.0-pyh41d4057_1 ipython_genutils conda-forge/noarch::ipython_genutils-0.2.0-py_1 jedi conda-forge/noarch::jedi-0.18.1-pyhd8ed1ab_2 json5 conda-forge/noarch::json5-0.9.5-pyh9f0ad1d_0 jsonschema conda-forge/noarch::jsonschema-4.16.0-pyhd8ed1ab_0 jupyter_client conda-forge/noarch::jupyter_client-7.3.5-pyhd8ed1ab_0 jupyter_core conda-forge/linux-64::jupyter_core-4.11.1-py38h578d9bd_0 jupyter_server conda-forge/noarch::jupyter_server-1.18.1-pyhd8ed1ab_0 jupyterlab conda-forge/noarch::jupyterlab-3.4.7-pyhd8ed1ab_0 jupyterlab_pygmen~ conda-forge/noarch::jupyterlab_pygments-0.2.2-pyhd8ed1ab_0 jupyterlab_server conda-forge/noarch::jupyterlab_server-2.15.1-pyhd8ed1ab_0 libiconv conda-forge/linux-64::libiconv-1.16-h516909a_0 libsodium conda-forge/linux-64::libsodium-1.0.18-h36c2ea0_1 libxml2 conda-forge/linux-64::libxml2-2.9.14-h22db469_4 libxslt conda-forge/linux-64::libxslt-1.1.35-h8affb1d_0 lxml conda-forge/linux-64::lxml-4.9.1-py38h0a891b7_0 matplotlib-inline conda-forge/noarch::matplotlib-inline-0.1.6-pyhd8ed1ab_0 mistune conda-forge/noarch::mistune-2.0.4-pyhd8ed1ab_0 nbclassic conda-forge/noarch::nbclassic-0.4.3-pyhd8ed1ab_0 nbclient conda-forge/noarch::nbclient-0.6.8-pyhd8ed1ab_0 nbconvert conda-forge/noarch::nbconvert-7.0.0-pyhd8ed1ab_0 nbconvert-core conda-forge/noarch::nbconvert-core-7.0.0-pyhd8ed1ab_0 nbconvert-pandoc conda-forge/noarch::nbconvert-pandoc-7.0.0-pyhd8ed1ab_0 nbformat conda-forge/noarch::nbformat-5.5.0-pyhd8ed1ab_0 nest-asyncio conda-forge/noarch::nest-asyncio-1.5.5-pyhd8ed1ab_0 notebook conda-forge/noarch::notebook-6.4.12-pyha770c72_0 notebook-shim conda-forge/noarch::notebook-shim-0.1.0-pyhd8ed1ab_0 pandoc conda-forge/linux-64::pandoc-2.19.2-ha770c72_0 pandocfilters conda-forge/noarch::pandocfilters-1.5.0-pyhd8ed1ab_0 parso conda-forge/noarch::parso-0.8.3-pyhd8ed1ab_0 pexpect conda-forge/noarch::pexpect-4.8.0-pyh9f0ad1d_2 pickleshare conda-forge/noarch::pickleshare-0.7.5-py_1003 pkgutil-resolve-n~ conda-forge/noarch::pkgutil-resolve-name-1.3.10-pyhd8ed1ab_0 prometheus_client conda-forge/noarch::prometheus_client-0.14.1-pyhd8ed1ab_0 prompt-toolkit conda-forge/noarch::prompt-toolkit-3.0.31-pyha770c72_0 psutil conda-forge/linux-64::psutil-5.9.2-py38h0a891b7_0 ptyprocess conda-forge/noarch::ptyprocess-0.7.0-pyhd3deb0d_0 pure_eval conda-forge/noarch::pure_eval-0.2.2-pyhd8ed1ab_0 pygments conda-forge/noarch::pygments-2.13.0-pyhd8ed1ab_0 pyrsistent conda-forge/linux-64::pyrsistent-0.18.1-py38h0a891b7_1 python-dateutil conda-forge/noarch::python-dateutil-2.8.2-pyhd8ed1ab_0 python-fastjsonsc~ conda-forge/noarch::python-fastjsonschema-2.16.1-pyhd8ed1ab_0 pytz conda-forge/noarch::pytz-2022.2.1-pyhd8ed1ab_0 pyzmq conda-forge/linux-64::pyzmq-24.0.0-py38hfc09fa9_0 send2trash conda-forge/noarch::send2trash-1.8.0-pyhd8ed1ab_0 six conda-forge/noarch::six-1.16.0-pyh6c4a22f_0 sniffio conda-forge/noarch::sniffio-1.3.0-pyhd8ed1ab_0 soupsieve conda-forge/noarch::soupsieve-2.3.2.post1-pyhd8ed1ab_0 stack_data conda-forge/noarch::stack_data-0.5.0-pyhd8ed1ab_0 terminado conda-forge/linux-64::terminado-0.15.0-py38h578d9bd_0 tinycss2 conda-forge/noarch::tinycss2-1.1.1-pyhd8ed1ab_0 tomli conda-forge/noarch::tomli-2.0.1-pyhd8ed1ab_0 tornado conda-forge/linux-64::tornado-6.2-py38h0a891b7_0 traitlets conda-forge/noarch::traitlets-5.4.0-pyhd8ed1ab_0 wcwidth conda-forge/noarch::wcwidth-0.2.5-pyh9f0ad1d_2 webencodings conda-forge/noarch::webencodings-0.5.1-py_1 websocket-client conda-forge/noarch::websocket-client-1.4.1-pyhd8ed1ab_0 zeromq conda-forge/linux-64::zeromq-4.3.4-h9c3ff4c_1 zipp conda-forge/noarch::zipp-3.8.1-pyhd8ed1ab_0 Proceed ([y]/n)? y Downloading and Extracting Packages traitlets-5.4.0 | 85 KB | ### | 100% nbclient-0.6.8 | 65 KB | ### | 100% ipykernel-6.15.3 | 99 KB | ### | 100% tomli-2.0.1 | 16 KB | ### | 100% ipython-8.5.0 | 552 KB | ### | 100% jsonschema-4.16.0 | 65 KB | ### | 100% jupyter_core-4.11.1 | 81 KB | ### | 100% psutil-5.9.2 | 346 KB | ### | 100% lxml-4.9.1 | 1.4 MB | ### | 100% jupyterlab-3.4.7 | 5.9 MB | ### | 100% terminado-0.15.0 | 28 KB | ### | 100% nbformat-5.5.0 | 105 KB | ### | 100% argon2-cffi-bindings | 34 KB | ### | 100% debugpy-1.6.3 | 2.0 MB | ### | 100% pyrsistent-0.18.1 | 92 KB | ### | 100% importlib-metadata-4 | 33 KB | ### | 100% pyzmq-24.0.0 | 499 KB | ### | 100% tornado-6.2 | 653 KB | ### | 100% prompt-toolkit-3.0.3 | 254 KB | ### | 100% Preparing transaction: done Verifying transaction: done Executing transaction: done (rasa_py38) ashish@ashish-Lenovo-ideapad-130-15IKB:~/Desktop$ (rasa_py38) ashish@ashish-Lenovo-ideapad-130-15IKB:~/Desktop$ python -m ipykernel install --user --name rasa_py38 Installed kernelspec rasa_py38 in /home/ashish/.local/share/jupyter/kernels/rasa_py38 (rasa_py38) ashish@ashish-Lenovo-ideapad-130-15IKB:~/Desktop$ pip3 install rasa --user Collecting rasa Downloading rasa-3.2.8-py3-none-any.whl (819 kB) ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ 819.2/819.2 kB 320.6 kB/s eta 0:00:00 Collecting coloredlogs<16,>=10 Downloading coloredlogs-15.0.1-py2.py3-none-any.whl (46 kB) ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ 46.0/46.0 kB 209.8 kB/s eta 0:00:00 Collecting pykwalify<1.9,>=1.7 Downloading pykwalify-1.8.0-py2.py3-none-any.whl (24 kB) Collecting python-socketio<6,>=4.4 Downloading python_socketio-5.7.1-py3-none-any.whl (56 kB) ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ 56.6/56.6 kB 234.4 kB/s eta 0:00:00 Collecting dask==2022.2.0 Downloading dask-2022.2.0-py3-none-any.whl (1.1 MB) ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ 1.1/1.1 MB 287.9 kB/s eta 0:00:00 Collecting questionary<1.11.0,>=1.5.1 Downloading questionary-1.10.0-py3-none-any.whl (31 kB) Collecting colorclass<2.3,>=2.2 Downloading colorclass-2.2.2-py2.py3-none-any.whl (18 kB) Collecting twilio<6.51,>=6.26 Downloading twilio-6.50.1.tar.gz (457 kB) ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ 457.9/457.9 kB 272.9 kB/s eta 0:00:00 Preparing metadata (setup.py) ... done Collecting regex<2022.5,>=2020.6 Downloading regex-2022.4.24-cp38-cp38-manylinux_2_17_x86_64.manylinux2014_x86_64.whl (764 kB) ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ 764.9/764.9 kB 324.5 kB/s eta 0:00:00 Collecting slackclient<3.0.0,>=2.0.0 Downloading slackclient-2.9.4-py2.py3-none-any.whl (97 kB) ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ 97.1/97.1 kB 196.5 kB/s eta 0:00:00 Collecting aio-pika<9.0.0,>=6.7.1 Downloading aio-pika-8.2.1.tar.gz (42 kB) ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ 42.3/42.3 kB 218.7 kB/s eta 0:00:00 Preparing metadata (setup.py) ... done Collecting python-engineio!=5.0.0,<6,>=4 Downloading python_engineio-4.3.4-py3-none-any.whl (52 kB) ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ 52.9/52.9 kB 281.0 kB/s eta 0:00:00 Collecting typing-extensions<4.0.0,>=3.7.4 Downloading typing_extensions-3.10.0.2-py3-none-any.whl (26 kB) Collecting apscheduler<3.8,>=3.6 Downloading APScheduler-3.7.0-py2.py3-none-any.whl (59 kB) ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ 59.3/59.3 kB 246.7 kB/s eta 0:00:00 Requirement already satisfied: requests<3.0,>=2.23 in /home/ashish/anaconda3/envs/rasa_py38/lib/python3.8/site-packages (from rasa) (2.28.1) Collecting rasa-sdk<3.3.0,>=3.2.0 Downloading rasa_sdk-3.2.1-py3-none-any.whl (41 kB) ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ 41.0/41.0 kB 290.6 kB/s eta 0:00:00 Collecting numpy<1.20.0,>=1.19.2 Downloading numpy-1.19.5-cp38-cp38-manylinux2010_x86_64.whl (14.9 MB) ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ 14.9/14.9 MB 308.9 kB/s eta 0:00:00 Collecting pytz<2022.0,>=2019.1 Downloading pytz-2021.3-py2.py3-none-any.whl (503 kB) ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ 503.5/503.5 kB 323.7 kB/s eta 0:00:00 Requirement already satisfied: setuptools>=41.0.0 in /home/ashish/anaconda3/envs/rasa_py38/lib/python3.8/site-packages (from rasa) (65.3.0) Collecting google-auth<2 Downloading google_auth-1.35.0-py2.py3-none-any.whl (152 kB) ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ 152.9/152.9 kB 247.8 kB/s eta 0:00:00 Requirement already satisfied: tqdm<5.0,>=4.31 in /home/ashish/anaconda3/envs/rasa_py38/lib/python3.8/site-packages (from rasa) (4.64.1) Collecting CacheControl<0.13.0,>=0.12.9 Downloading CacheControl-0.12.11-py2.py3-none-any.whl (21 kB) Collecting scikit-learn<0.25,>=0.22 Downloading scikit_learn-0.24.2-cp38-cp38-manylinux2010_x86_64.whl (24.9 MB) ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ 24.9/24.9 MB 288.4 kB/s eta 0:00:00 Collecting tensorflow-addons<0.16.0,>=0.15.0 Downloading tensorflow_addons-0.15.0-cp38-cp38-manylinux_2_12_x86_64.manylinux2010_x86_64.whl (1.1 MB) ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ 1.1/1.1 MB 323.8 kB/s eta 0:00:00 Collecting joblib<1.1.0,>=0.15.1 Downloading joblib-1.0.1-py3-none-any.whl (303 kB) ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ 303.1/303.1 kB 310.5 kB/s eta 0:00:00 Collecting attrs<21.3,>=19.3 Downloading attrs-21.2.0-py2.py3-none-any.whl (53 kB) ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ 53.7/53.7 kB 292.9 kB/s eta 0:00:00 Collecting pymongo[srv,tls]<3.11,>=3.8 Downloading pymongo-3.10.1-cp38-cp38-manylinux2014_x86_64.whl (480 kB) ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ 480.1/480.1 kB 314.2 kB/s eta 0:00:00 Collecting sentry-sdk<1.4.0,>=0.17.0 Downloading sentry_sdk-1.3.1-py2.py3-none-any.whl (133 kB) ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ 133.6/133.6 kB 247.9 kB/s eta 0:00:00 Collecting networkx<2.7,>=2.4 Downloading networkx-2.6.3-py3-none-any.whl (1.9 MB) ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ 1.9/1.9 MB 338.2 kB/s eta 0:00:00 Collecting tensorflow-text<2.8.0,>=2.7.0 Downloading tensorflow_text-2.7.3-cp38-cp38-manylinux2010_x86_64.whl (4.9 MB) ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ 4.9/4.9 MB 343.2 kB/s eta 0:00:00 Collecting kafka-python<3.0,>=1.4 Downloading kafka_python-2.0.2-py2.py3-none-any.whl (246 kB) ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ 246.5/246.5 kB 335.8 kB/s eta 0:00:00 Collecting absl-py<0.14,>=0.9 Downloading absl_py-0.13.0-py3-none-any.whl (132 kB) ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ 132.1/132.1 kB 241.4 kB/s eta 0:00:00 Collecting scipy<1.8.0,>=1.4.1 Downloading scipy-1.7.3-cp38-cp38-manylinux_2_17_x86_64.manylinux2014_x86_64.whl (39.3 MB) ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ 39.3/39.3 MB 297.4 kB/s eta 0:00:00 Collecting terminaltables<3.2.0,>=3.1.0 Downloading terminaltables-3.1.10-py2.py3-none-any.whl (15 kB) Collecting SQLAlchemy<1.5.0,>=1.4.0 Downloading SQLAlchemy-1.4.41-cp38-cp38-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_17_x86_64.manylinux2014_x86_64.whl (1.6 MB) ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ 1.6/1.6 MB 294.6 kB/s eta 0:00:00 Collecting packaging<21.0,>=20.0 Downloading packaging-20.9-py2.py3-none-any.whl (40 kB) ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ 40.9/40.9 kB 157.0 kB/s eta 0:00:00 Collecting webexteamssdk<1.7.0,>=1.1.1 Downloading webexteamssdk-1.6.1-py3-none-any.whl (113 kB) ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ 113.5/113.5 kB 259.2 kB/s eta 0:00:00 Requirement already satisfied: python-dateutil<2.9,>=2.8 in /home/ashish/anaconda3/envs/rasa_py38/lib/python3.8/site-packages (from rasa) (2.8.2) Collecting rocketchat_API<1.26.0,>=0.6.31 Downloading rocketchat_API-1.25.0-py3-none-any.whl (19 kB) Collecting fbmessenger<6.1.0,>=6.0.0 Downloading fbmessenger-6.0.0-py2.py3-none-any.whl (11 kB) Collecting ruamel.yaml<0.17.0,>=0.16.5 Downloading ruamel.yaml-0.16.13-py2.py3-none-any.whl (111 kB) ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ 111.9/111.9 kB 339.1 kB/s eta 0:00:00 Collecting randomname<0.2.0,>=0.1.5 Downloading randomname-0.1.5.tar.gz (36 kB) Preparing metadata (setup.py) ... done Collecting colorhash<1.1.0,>=1.0.2 Downloading colorhash-1.0.4-py3-none-any.whl (5.5 kB) Collecting cloudpickle<1.7,>=1.2 Downloading cloudpickle-1.6.0-py3-none-any.whl (23 kB) Collecting matplotlib<3.4,>=3.1 Downloading matplotlib-3.3.4-cp38-cp38-manylinux1_x86_64.whl (11.6 MB) ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ 11.6/11.6 MB 288.3 kB/s eta 0:00:00 Collecting prompt-toolkit<3.0.29,>=3.0 Downloading prompt_toolkit-3.0.28-py3-none-any.whl (380 kB) ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ 380.2/380.2 kB 255.8 kB/s eta 0:00:00 Collecting pydot<1.5,>=1.4 Downloading pydot-1.4.2-py2.py3-none-any.whl (21 kB) Collecting boto3<2.0,>=1.12 Downloading boto3-1.24.75-py3-none-any.whl (132 kB) ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ 132.5/132.5 kB 250.2 kB/s eta 0:00:00 Collecting redis<4.0,>=3.4 Downloading redis-3.5.3-py2.py3-none-any.whl (72 kB) ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ 72.1/72.1 kB 267.3 kB/s eta 0:00:00 Collecting sanic<21.13,>=21.12 Downloading sanic-21.12.2-py3-none-any.whl (156 kB) ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ 156.5/156.5 kB 276.9 kB/s eta 0:00:00 Collecting aiohttp!=3.7.4.post0,<3.8,>=3.6 Downloading aiohttp-3.7.4-cp38-cp38-manylinux2014_x86_64.whl (1.5 MB) ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ 1.5/1.5 MB 331.6 kB/s eta 0:00:00 Collecting sanic-routing<0.8.0,>=0.7.2 Downloading sanic_routing-0.7.2-py3-none-any.whl (23 kB) Collecting ujson<6.0,>=1.35 Downloading ujson-5.5.0-cp38-cp38-manylinux_2_17_x86_64.manylinux2014_x86_64.whl (46 kB) ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ 46.1/46.1 kB 178.6 kB/s eta 0:00:00 Collecting PyJWT[crypto]<3.0.0,>=2.0.0 Downloading PyJWT-2.5.0-py3-none-any.whl (20 kB) Collecting sanic-cors<2.1.0,>=2.0.0 Downloading Sanic_Cors-2.0.1-py2.py3-none-any.whl (17 kB) Collecting tensorflow<2.8.0,>=2.7.0 Downloading tensorflow-2.7.4-cp38-cp38-manylinux2010_x86_64.whl (496.0 MB) ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ 496.0/496.0 MB 206.4 kB/s eta 0:00:00 Collecting pyTelegramBotAPI<5.0.0,>=3.7.3 Downloading pyTelegramBotAPI-4.7.0.tar.gz (210 kB) ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ 210.7/210.7 kB 229.1 kB/s eta 0:00:00 Preparing metadata (setup.py) ... done Collecting jsonpickle<2.1,>=1.3 Downloading jsonpickle-2.0.0-py2.py3-none-any.whl (37 kB) Collecting sanic-jwt<2.0.0,>=1.6.0 Downloading sanic_jwt-1.8.0-py3-none-any.whl (23 kB) Collecting typing-utils<0.2.0,>=0.1.0 Downloading typing_utils-0.1.0-py3-none-any.whl (10 kB) Collecting mattermostwrapper<2.3,>=2.2 Downloading mattermostwrapper-2.2.tar.gz (2.5 kB) Preparing metadata (setup.py) ... done Collecting tarsafe<0.0.4,>=0.0.3 Downloading tarsafe-0.0.3-py3-none-any.whl (5.0 kB) Collecting jsonschema<4.5,>=3.2 Downloading jsonschema-4.4.0-py3-none-any.whl (72 kB) ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ 72.7/72.7 kB 240.9 kB/s eta 0:00:00 Collecting psycopg2-binary<2.10.0,>=2.8.2 Downloading psycopg2_binary-2.9.3-cp38-cp38-manylinux_2_17_x86_64.manylinux2014_x86_64.whl (3.0 MB) ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ 3.0/3.0 MB 259.8 kB/s eta 0:00:00 Collecting tensorflow_hub<0.13.0,>=0.12.0 Downloading tensorflow_hub-0.12.0-py2.py3-none-any.whl (108 kB) ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ 108.8/108.8 kB 232.1 kB/s eta 0:00:00 Collecting sklearn-crfsuite<0.4,>=0.3 Downloading sklearn_crfsuite-0.3.6-py2.py3-none-any.whl (12 kB) Collecting partd>=0.3.10 Downloading partd-1.3.0-py3-none-any.whl (18 kB) Collecting pyyaml>=5.3.1 Downloading PyYAML-6.0-cp38-cp38-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_12_x86_64.manylinux2010_x86_64.whl (701 kB) ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ 701.2/701.2 kB 304.6 kB/s eta 0:00:00 Collecting toolz>=0.8.2 Downloading toolz-0.12.0-py3-none-any.whl (55 kB) ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ 55.8/55.8 kB 243.2 kB/s eta 0:00:00 Collecting fsspec>=0.6.0 Downloading fsspec-2022.8.2-py3-none-any.whl (140 kB) ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ 140.8/140.8 kB 278.9 kB/s eta 0:00:00 Requirement already satisfied: six in /home/ashish/anaconda3/envs/rasa_py38/lib/python3.8/site-packages (from absl-py<0.14,>=0.9->rasa) (1.16.0) Collecting aiormq~=6.4.0 Downloading aiormq-6.4.2-py3-none-any.whl (34 kB) Collecting yarl Downloading yarl-1.8.1-cp38-cp38-manylinux_2_17_x86_64.manylinux2014_x86_64.whl (262 kB) ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ 262.1/262.1 kB 299.1 kB/s eta 0:00:00 Collecting chardet<4.0,>=2.0 Downloading chardet-3.0.4-py2.py3-none-any.whl (133 kB) ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ 133.4/133.4 kB 308.3 kB/s eta 0:00:00 Collecting async-timeout<4.0,>=3.0 Downloading async_timeout-3.0.1-py3-none-any.whl (8.2 kB) Collecting multidict<7.0,>=4.5 Downloading multidict-6.0.2-cp38-cp38-manylinux_2_17_x86_64.manylinux2014_x86_64.whl (121 kB) ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ 121.3/121.3 kB 345.9 kB/s eta 0:00:00 Collecting tzlocal~=2.0 Downloading tzlocal-2.1-py2.py3-none-any.whl (16 kB) Collecting jmespath<2.0.0,>=0.7.1 Downloading jmespath-1.0.1-py3-none-any.whl (20 kB) Collecting botocore<1.28.0,>=1.27.75 Downloading botocore-1.27.75-py3-none-any.whl (9.1 MB) ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ 9.1/9.1 MB 278.2 kB/s eta 0:00:00 Collecting s3transfer<0.7.0,>=0.6.0 Downloading s3transfer-0.6.0-py3-none-any.whl (79 kB) ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ 79.6/79.6 kB 276.0 kB/s eta 0:00:00 Collecting msgpack>=0.5.2 Downloading msgpack-1.0.4-cp38-cp38-manylinux_2_17_x86_64.manylinux2014_x86_64.whl (322 kB) ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ 322.5/322.5 kB 266.5 kB/s eta 0:00:00 Collecting humanfriendly>=9.1 Downloading humanfriendly-10.0-py2.py3-none-any.whl (86 kB) ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ 86.8/86.8 kB 254.5 kB/s eta 0:00:00 Collecting cachetools<5.0,>=2.0.0 Downloading cachetools-4.2.4-py3-none-any.whl (10 kB) Collecting pyasn1-modules>=0.2.1 Downloading pyasn1_modules-0.2.8-py2.py3-none-any.whl (155 kB) ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ 155.3/155.3 kB 261.2 kB/s eta 0:00:00 Collecting rsa<5,>=3.1.4 Downloading rsa-4.9-py3-none-any.whl (34 kB) Requirement already satisfied: pyrsistent!=0.17.0,!=0.17.1,!=0.17.2,>=0.14.0 in /home/ashish/anaconda3/envs/rasa_py38/lib/python3.8/site-packages (from jsonschema<4.5,>=3.2->rasa) (0.18.1) Requirement already satisfied: importlib-resources>=1.4.0 in /home/ashish/anaconda3/envs/rasa_py38/lib/python3.8/site-packages (from jsonschema<4.5,>=3.2->rasa) (5.9.0) Collecting pillow>=6.2.0 Downloading Pillow-9.2.0-cp38-cp38-manylinux_2_28_x86_64.whl (3.2 MB) ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ 3.2/3.2 MB 283.6 kB/s eta 0:00:00 Collecting kiwisolver>=1.0.1 Downloading kiwisolver-1.4.4-cp38-cp38-manylinux_2_5_x86_64.manylinux1_x86_64.whl (1.2 MB) ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ 1.2/1.2 MB 247.8 kB/s eta 0:00:00 Collecting cycler>=0.10 Downloading cycler-0.11.0-py3-none-any.whl (6.4 kB) Requirement already satisfied: pyparsing!=2.0.4,!=2.1.2,!=2.1.6,>=2.0.3 in /home/ashish/anaconda3/envs/rasa_py38/lib/python3.8/site-packages (from matplotlib<3.4,>=3.1->rasa) (3.0.9) Requirement already satisfied: wcwidth in /home/ashish/anaconda3/envs/rasa_py38/lib/python3.8/site-packages (from prompt-toolkit<3.0.29,>=3.0->rasa) (0.2.5) Collecting types-cryptography>=3.3.21 Downloading types_cryptography-3.3.23-py3-none-any.whl (30 kB) Requirement already satisfied: cryptography>=3.3.1 in /home/ashish/anaconda3/envs/rasa_py38/lib/python3.8/site-packages (from PyJWT[crypto]<3.0.0,>=2.0.0->rasa) (37.0.4) Collecting docopt>=0.6.2 Downloading docopt-0.6.2.tar.gz (25 kB) Preparing metadata (setup.py) ... done Collecting dnspython<2.0.0,>=1.16.0 Downloading dnspython-1.16.0-py2.py3-none-any.whl (188 kB) ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ 188.4/188.4 kB 204.2 kB/s eta 0:00:00 Collecting bidict>=0.21.0 Downloading bidict-0.22.0-py3-none-any.whl (36 kB) Collecting fire Downloading fire-0.4.0.tar.gz (87 kB) ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ 87.7/87.7 kB 207.5 kB/s eta 0:00:00 Preparing metadata (setup.py) ... done Requirement already satisfied: urllib3<2.0.0,>=1.26.5 in /home/ashish/anaconda3/envs/rasa_py38/lib/python3.8/site-packages (from rasa-sdk<3.3.0,>=3.2.0->rasa) (1.26.11) Requirement already satisfied: charset-normalizer<3,>=2 in /home/ashish/anaconda3/envs/rasa_py38/lib/python3.8/site-packages (from requests<3.0,>=2.23->rasa) (2.1.1) Requirement already satisfied: certifi>=2017.4.17 in /home/ashish/anaconda3/envs/rasa_py38/lib/python3.8/site-packages (from requests<3.0,>=2.23->rasa) (2022.9.14) Requirement already satisfied: idna<4,>=2.5 in /home/ashish/anaconda3/envs/rasa_py38/lib/python3.8/site-packages (from requests<3.0,>=2.23->rasa) (3.3) Collecting ruamel.yaml.clib>=0.1.2 Downloading ruamel.yaml.clib-0.2.6-cp38-cp38-manylinux1_x86_64.whl (570 kB) ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ 570.4/570.4 kB 335.9 kB/s eta 0:00:00 Collecting aiofiles>=0.6.0 Downloading aiofiles-22.1.0-py3-none-any.whl (14 kB) Collecting uvloop>=0.5.3 Downloading uvloop-0.17.0-cp38-cp38-manylinux_2_17_x86_64.manylinux2014_x86_64.whl (4.6 MB) ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ 4.6/4.6 MB 302.9 kB/s eta 0:00:00 Collecting httptools>=0.0.10 Downloading httptools-0.5.0-cp38-cp38-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_17_x86_64.manylinux2014_x86_64.whl (427 kB) ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ 427.8/427.8 kB 290.8 kB/s eta 0:00:00 Collecting websockets>=10.0 Downloading websockets-10.3-cp38-cp38-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_12_x86_64.manylinux2010_x86_64.whl (111 kB) ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ 111.3/111.3 kB 334.3 kB/s eta 0:00:00 Collecting multidict<7.0,>=4.5 Downloading multidict-5.2.0-cp38-cp38-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_12_x86_64.manylinux2010_x86_64.whl (187 kB) ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ 187.4/187.4 kB 326.6 kB/s eta 0:00:00 Collecting threadpoolctl>=2.0.0 Downloading threadpoolctl-3.1.0-py3-none-any.whl (14 kB) Collecting python-crfsuite>=0.8.3 Downloading python_crfsuite-0.9.8-cp38-cp38-manylinux_2_17_x86_64.manylinux2014_x86_64.whl (1.0 MB) ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ 1.0/1.0 MB 326.0 kB/s eta 0:00:00 Collecting tabulate Downloading tabulate-0.8.10-py3-none-any.whl (29 kB) Collecting greenlet!=0.4.17 Downloading greenlet-1.1.3-cp38-cp38-manylinux_2_17_x86_64.manylinux2014_x86_64.whl (157 kB) ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ 157.1/157.1 kB 356.2 kB/s eta 0:00:00 Collecting opt-einsum>=2.3.2 Downloading opt_einsum-3.3.0-py3-none-any.whl (65 kB) ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ 65.5/65.5 kB 318.3 kB/s eta 0:00:00 Collecting gast<0.5.0,>=0.2.1 Downloading gast-0.4.0-py3-none-any.whl (9.8 kB) Collecting google-pasta>=0.1.1 Downloading google_pasta-0.2.0-py3-none-any.whl (57 kB) ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ 57.5/57.5 kB 221.1 kB/s eta 0:00:00 Collecting keras-preprocessing>=1.1.1 Downloading Keras_Preprocessing-1.1.2-py2.py3-none-any.whl (42 kB) ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ 42.6/42.6 kB 278.5 kB/s eta 0:00:00 Collecting astunparse>=1.6.0 Downloading astunparse-1.6.3-py2.py3-none-any.whl (12 kB) Collecting flatbuffers<3.0,>=1.12 Downloading flatbuffers-2.0.7-py2.py3-none-any.whl (26 kB) Collecting libclang>=9.0.1 Downloading libclang-14.0.6-py2.py3-none-manylinux2010_x86_64.whl (14.1 MB) ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ 14.1/14.1 MB 276.7 kB/s eta 0:00:00 Collecting wrapt>=1.11.0 Downloading wrapt-1.14.1-cp38-cp38-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_17_x86_64.manylinux2014_x86_64.whl (81 kB) ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ 81.0/81.0 kB 400.8 kB/s eta 0:00:00 Collecting tensorboard~=2.6 Downloading tensorboard-2.10.0-py3-none-any.whl (5.9 MB) ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ 5.9/5.9 MB 339.5 kB/s eta 0:00:00 Collecting tensorflow-estimator<2.8,~=2.7.0rc0 Downloading tensorflow_estimator-2.7.0-py2.py3-none-any.whl (463 kB) ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ 463.1/463.1 kB 202.3 kB/s eta 0:00:00 Collecting termcolor>=1.1.0 Downloading termcolor-2.0.1-py3-none-any.whl (5.4 kB) Requirement already satisfied: wheel<1.0,>=0.32.0 in /home/ashish/anaconda3/envs/rasa_py38/lib/python3.8/site-packages (from tensorflow<2.8.0,>=2.7.0->rasa) (0.37.1) Collecting protobuf<3.20,>=3.9.2 Downloading protobuf-3.19.5-cp38-cp38-manylinux_2_17_x86_64.manylinux2014_x86_64.whl (1.1 MB) ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ 1.1/1.1 MB 208.1 kB/s eta 0:00:00 Collecting keras<2.8,>=2.7.0rc0 Downloading keras-2.7.0-py2.py3-none-any.whl (1.3 MB) ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ 1.3/1.3 MB 323.8 kB/s eta 0:00:00 Collecting grpcio<2.0,>=1.24.3 Downloading grpcio-1.49.0-cp38-cp38-manylinux_2_17_x86_64.manylinux2014_x86_64.whl (4.7 MB) ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ 4.7/4.7 MB 265.6 kB/s eta 0:00:00 Collecting tensorflow-io-gcs-filesystem>=0.21.0 Downloading tensorflow_io_gcs_filesystem-0.27.0-cp38-cp38-manylinux_2_12_x86_64.manylinux2010_x86_64.whl (2.4 MB) ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ 2.4/2.4 MB 198.4 kB/s eta 0:00:00 Collecting h5py>=2.9.0 Downloading h5py-3.7.0-cp38-cp38-manylinux_2_12_x86_64.manylinux2010_x86_64.whl (4.5 MB) ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ 4.5/4.5 MB 192.7 kB/s eta 0:00:00 Collecting typeguard>=2.7 Downloading typeguard-2.13.3-py3-none-any.whl (17 kB) Collecting requests-toolbelt Downloading requests_toolbelt-0.9.1-py2.py3-none-any.whl (54 kB) ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ 54.3/54.3 kB 288.5 kB/s eta 0:00:00 Collecting future Downloading future-0.18.2.tar.gz (829 kB) ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ 829.2/829.2 kB 297.7 kB/s eta 0:00:00 Preparing metadata (setup.py) ... done Collecting pamqp==3.2.1 Downloading pamqp-3.2.1-py2.py3-none-any.whl (33 kB) Requirement already satisfied: cffi>=1.12 in /home/ashish/anaconda3/envs/rasa_py38/lib/python3.8/site-packages (from cryptography>=3.3.1->PyJWT[crypto]<3.0.0,>=2.0.0->rasa) (1.15.1) Requirement already satisfied: zipp>=3.1.0 in /home/ashish/anaconda3/envs/rasa_py38/lib/python3.8/site-packages (from importlib-resources>=1.4.0->jsonschema<4.5,>=3.2->rasa) (3.8.1) Collecting locket Downloading locket-1.0.0-py2.py3-none-any.whl (4.4 kB) Collecting pyasn1<0.5.0,>=0.4.6 Downloading pyasn1-0.4.8-py2.py3-none-any.whl (77 kB) ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ 77.1/77.1 kB 306.6 kB/s eta 0:00:00 Collecting tensorboard-data-server<0.7.0,>=0.6.0 Downloading tensorboard_data_server-0.6.1-py3-none-manylinux2010_x86_64.whl (4.9 MB) ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ 4.9/4.9 MB 304.1 kB/s eta 0:00:00 Collecting markdown>=2.6.8 Downloading Markdown-3.4.1-py3-none-any.whl (93 kB) ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ 93.3/93.3 kB 325.5 kB/s eta 0:00:00 Collecting werkzeug>=1.0.1 Downloading Werkzeug-2.2.2-py3-none-any.whl (232 kB) ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ 232.7/232.7 kB 296.1 kB/s eta 0:00:00 Collecting google-auth-oauthlib<0.5,>=0.4.1 Downloading google_auth_oauthlib-0.4.6-py2.py3-none-any.whl (18 kB) Collecting tensorboard-plugin-wit>=1.6.0 Downloading tensorboard_plugin_wit-1.8.1-py3-none-any.whl (781 kB) ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ 781.3/781.3 kB 286.4 kB/s eta 0:00:00 Requirement already satisfied: pycparser in /home/ashish/anaconda3/envs/rasa_py38/lib/python3.8/site-packages (from cffi>=1.12->cryptography>=3.3.1->PyJWT[crypto]<3.0.0,>=2.0.0->rasa) (2.21) Collecting requests-oauthlib>=0.7.0 Downloading requests_oauthlib-1.3.1-py2.py3-none-any.whl (23 kB) Requirement already satisfied: importlib-metadata>=4.4 in /home/ashish/anaconda3/envs/rasa_py38/lib/python3.8/site-packages (from markdown>=2.6.8->tensorboard~=2.6->tensorflow<2.8.0,>=2.7.0->rasa) (4.11.4) Requirement already satisfied: MarkupSafe>=2.1.1 in /home/ashish/anaconda3/envs/rasa_py38/lib/python3.8/site-packages (from werkzeug>=1.0.1->tensorboard~=2.6->tensorflow<2.8.0,>=2.7.0->rasa) (2.1.1) Collecting oauthlib>=3.0.0 Downloading oauthlib-3.2.1-py3-none-any.whl (151 kB) ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ 151.7/151.7 kB 301.9 kB/s eta 0:00:00 Building wheels for collected packages: aio-pika, mattermostwrapper, pyTelegramBotAPI, randomname, twilio, docopt, fire, future Building wheel for aio-pika (setup.py) ... done Created wheel for aio-pika: filename=aio_pika-8.2.1-py3-none-any.whl size=49595 sha256=61819ae86e93deb5d8f1f7c60f769d40e42ccf6de8af62f4af0a3bcb30a98499 Stored in directory: /home/ashish/.cache/pip/wheels/27/ab/59/a3f84ec019a2a87ad812a2dc15945f763e5684aecfb059d9ec Building wheel for mattermostwrapper (setup.py) ... done Created wheel for mattermostwrapper: filename=mattermostwrapper-2.2-py3-none-any.whl size=2448 sha256=671230d2ec1c13e72ee8b2f53cd09e8a800d5db87dc166a6c2eb6ac019a89a7c Stored in directory: /home/ashish/.cache/pip/wheels/1a/d3/89/63aef88b581e7acc2c48812e6160a2bae57b6ef180f6e1f293 Building wheel for pyTelegramBotAPI (setup.py) ... done Created wheel for pyTelegramBotAPI: filename=pyTelegramBotAPI-4.7.0-py3-none-any.whl size=192810 sha256=388f48b689f2b9f8f5ab4253a9a1a0c0caba6a9869dacffe2f60077cab1a69ea Stored in directory: /home/ashish/.cache/pip/wheels/f7/29/1d/113c046ac93c2896159bb2c33673efe140b3642f21a06c4ac5 Building wheel for randomname (setup.py) ... done Created wheel for randomname: filename=randomname-0.1.5-py3-none-any.whl size=58808 sha256=b4ef46a33c316f83d0947ae923af542f7963176dffcd821789ce9af5b5d6393e Stored in directory: /home/ashish/.cache/pip/wheels/46/0a/9d/32f2d10d4fae6ddfbdeb504d949ccd70d666382a277e7c1bd5 Building wheel for twilio (setup.py) ... done Created wheel for twilio: filename=twilio-6.50.1-py2.py3-none-any.whl size=1208682 sha256=bc11ed67ebb0cd32e27e90ea4db4232206f01c9c0ed5909773b04b4b9e20391d Stored in directory: /home/ashish/.cache/pip/wheels/85/db/cc/c5c9ef20439073ba2a5403f5ce292446d3a01547007927df87 Building wheel for docopt (setup.py) ... done Created wheel for docopt: filename=docopt-0.6.2-py2.py3-none-any.whl size=13706 sha256=659b1afa51fb6f8497374a399b9e1c36a423a1fead4fa7999ccd1440917d65c2 Stored in directory: /home/ashish/.cache/pip/wheels/56/ea/58/ead137b087d9e326852a851351d1debf4ada529b6ac0ec4e8c Building wheel for fire (setup.py) ... done Created wheel for fire: filename=fire-0.4.0-py2.py3-none-any.whl size=115926 sha256=ecb49e817db0442d3d91f76c263f923d22f9c308f2fb6b2f170a80b3ceef5ac0 Stored in directory: /home/ashish/.cache/pip/wheels/1f/10/06/2a990ee4d73a8479fe2922445e8a876d38cfbfed052284c6a1 Building wheel for future (setup.py) ... done Created wheel for future: filename=future-0.18.2-py3-none-any.whl size=491058 sha256=cca1f0c0a3dfd4ada8c1534891271c9122c30f91097627fc9495f64eed6ae3d1 Stored in directory: /home/ashish/.cache/pip/wheels/8e/70/28/3d6ccd6e315f65f245da085482a2e1c7d14b90b30f239e2cf4 Successfully built aio-pika mattermostwrapper pyTelegramBotAPI randomname twilio docopt fire future Installing collected packages: typing-extensions, types-cryptography, tensorflow-estimator, tensorboard-plugin-wit, sanic-routing, pytz, python-crfsuite, pyasn1, msgpack, libclang, keras, kafka-python, flatbuffers, docopt, chardet, wrapt, werkzeug, websockets, uvloop, ujson, tzlocal, typing-utils, typeguard, toolz, threadpoolctl, terminaltables, termcolor, tensorflow-io-gcs-filesystem, tensorboard-data-server, tarsafe, tabulate, sentry-sdk, ruamel.yaml.clib, rsa, regex, redis, pyyaml, python-engineio, pymongo, PyJWT, pydot, pyasn1-modules, psycopg2-binary, protobuf, prompt-toolkit, pillow, pamqp, packaging, oauthlib, numpy, networkx, multidict, locket, kiwisolver, jsonpickle, joblib, jmespath, humanfriendly, httptools, grpcio, greenlet, google-pasta, gast, future, fsspec, dnspython, cycler, colorhash, colorclass, cloudpickle, cachetools, bidict, attrs, async-timeout, astunparse, aiofiles, absl-py, yarl, twilio, tensorflow_hub, tensorflow-addons, SQLAlchemy, sklearn-crfsuite, scipy, sanic-jwt, sanic, ruamel.yaml, rocketchat_API, requests-toolbelt, requests-oauthlib, questionary, python-socketio, pyTelegramBotAPI, partd, opt-einsum, mattermostwrapper, matplotlib, markdown, keras-preprocessing, jsonschema, h5py, google-auth, fire, fbmessenger, coloredlogs, CacheControl, botocore, apscheduler, webexteamssdk, scikit-learn, sanic-cors, s3transfer, randomname, pykwalify, google-auth-oauthlib, dask, aiormq, aiohttp, tensorboard, slackclient, rasa-sdk, boto3, aio-pika, tensorflow, tensorflow-text, rasa WARNING: The script chardetect is installed in '/home/ashish/.local/bin' which is not on PATH. Consider adding this directory to PATH or, if you prefer to suppress this warning, use --no-warn-script-location. WARNING: The script tabulate is installed in '/home/ashish/.local/bin' which is not on PATH. Consider adding this directory to PATH or, if you prefer to suppress this warning, use --no-warn-script-location. WARNING: The scripts pyrsa-decrypt, pyrsa-encrypt, pyrsa-keygen, pyrsa-priv2pub, pyrsa-sign and pyrsa-verify are installed in '/home/ashish/.local/bin' which is not on PATH. Consider adding this directory to PATH or, if you prefer to suppress this warning, use --no-warn-script-location. WARNING: The scripts f2py, f2py3 and f2py3.8 are installed in '/home/ashish/.local/bin' which is not on PATH. Consider adding this directory to PATH or, if you prefer to suppress this warning, use --no-warn-script-location. WARNING: The script humanfriendly is installed in '/home/ashish/.local/bin' which is not on PATH. Consider adding this directory to PATH or, if you prefer to suppress this warning, use --no-warn-script-location. WARNING: The scripts futurize and pasteurize are installed in '/home/ashish/.local/bin' which is not on PATH. Consider adding this directory to PATH or, if you prefer to suppress this warning, use --no-warn-script-location. WARNING: The scripts make_image_classifier and make_nearest_neighbour_index are installed in '/home/ashish/.local/bin' which is not on PATH. Consider adding this directory to PATH or, if you prefer to suppress this warning, use --no-warn-script-location. WARNING: The script sanic is installed in '/home/ashish/.local/bin' which is not on PATH. Consider adding this directory to PATH or, if you prefer to suppress this warning, use --no-warn-script-location. WARNING: The script markdown_py is installed in '/home/ashish/.local/bin' which is not on PATH. Consider adding this directory to PATH or, if you prefer to suppress this warning, use --no-warn-script-location. WARNING: The script jsonschema is installed in '/home/ashish/.local/bin' which is not on PATH. Consider adding this directory to PATH or, if you prefer to suppress this warning, use --no-warn-script-location. WARNING: The script coloredlogs is installed in '/home/ashish/.local/bin' which is not on PATH. Consider adding this directory to PATH or, if you prefer to suppress this warning, use --no-warn-script-location. WARNING: The script doesitcache is installed in '/home/ashish/.local/bin' which is not on PATH. Consider adding this directory to PATH or, if you prefer to suppress this warning, use --no-warn-script-location. WARNING: The script randomname is installed in '/home/ashish/.local/bin' which is not on PATH. Consider adding this directory to PATH or, if you prefer to suppress this warning, use --no-warn-script-location. WARNING: The script pykwalify is installed in '/home/ashish/.local/bin' which is not on PATH. Consider adding this directory to PATH or, if you prefer to suppress this warning, use --no-warn-script-location. WARNING: The script google-oauthlib-tool is installed in '/home/ashish/.local/bin' which is not on PATH. Consider adding this directory to PATH or, if you prefer to suppress this warning, use --no-warn-script-location. WARNING: The script tensorboard is installed in '/home/ashish/.local/bin' which is not on PATH. Consider adding this directory to PATH or, if you prefer to suppress this warning, use --no-warn-script-location. WARNING: The scripts estimator_ckpt_converter, import_pb_to_tensorboard, saved_model_cli, tensorboard, tf_upgrade_v2, tflite_convert, toco and toco_from_protos are installed in '/home/ashish/.local/bin' which is not on PATH. Consider adding this directory to PATH or, if you prefer to suppress this warning, use --no-warn-script-location. WARNING: The script rasa is installed in '/home/ashish/.local/bin' which is not on PATH. Consider adding this directory to PATH or, if you prefer to suppress this warning, use --no-warn-script-location. Successfully installed CacheControl-0.12.11 PyJWT-2.5.0 SQLAlchemy-1.4.41 absl-py-0.13.0 aio-pika-8.2.1 aiofiles-22.1.0 aiohttp-3.7.4 aiormq-6.4.2 apscheduler-3.7.0 astunparse-1.6.3 async-timeout-3.0.1 attrs-21.2.0 bidict-0.22.0 boto3-1.24.75 botocore-1.27.75 cachetools-4.2.4 chardet-3.0.4 cloudpickle-1.6.0 colorclass-2.2.2 coloredlogs-15.0.1 colorhash-1.0.4 cycler-0.11.0 dask-2022.2.0 dnspython-1.16.0 docopt-0.6.2 fbmessenger-6.0.0 fire-0.4.0 flatbuffers-2.0.7 fsspec-2022.8.2 future-0.18.2 gast-0.4.0 google-auth-1.35.0 google-auth-oauthlib-0.4.6 google-pasta-0.2.0 greenlet-1.1.3 grpcio-1.49.0 h5py-3.7.0 httptools-0.5.0 humanfriendly-10.0 jmespath-1.0.1 joblib-1.0.1 jsonpickle-2.0.0 jsonschema-4.4.0 kafka-python-2.0.2 keras-2.7.0 keras-preprocessing-1.1.2 kiwisolver-1.4.4 libclang-14.0.6 locket-1.0.0 markdown-3.4.1 matplotlib-3.3.4 mattermostwrapper-2.2 msgpack-1.0.4 multidict-5.2.0 networkx-2.6.3 numpy-1.19.5 oauthlib-3.2.1 opt-einsum-3.3.0 packaging-20.9 pamqp-3.2.1 partd-1.3.0 pillow-9.2.0 prompt-toolkit-3.0.28 protobuf-3.19.5 psycopg2-binary-2.9.3 pyTelegramBotAPI-4.7.0 pyasn1-0.4.8 pyasn1-modules-0.2.8 pydot-1.4.2 pykwalify-1.8.0 pymongo-3.10.1 python-crfsuite-0.9.8 python-engineio-4.3.4 python-socketio-5.7.1 pytz-2021.3 pyyaml-6.0 questionary-1.10.0 randomname-0.1.5 rasa-3.2.8 rasa-sdk-3.2.1 redis-3.5.3 regex-2022.4.24 requests-oauthlib-1.3.1 requests-toolbelt-0.9.1 rocketchat_API-1.25.0 rsa-4.9 ruamel.yaml-0.16.13 ruamel.yaml.clib-0.2.6 s3transfer-0.6.0 sanic-21.12.2 sanic-cors-2.0.1 sanic-jwt-1.8.0 sanic-routing-0.7.2 scikit-learn-0.24.2 scipy-1.7.3 sentry-sdk-1.3.1 sklearn-crfsuite-0.3.6 slackclient-2.9.4 tabulate-0.8.10 tarsafe-0.0.3 tensorboard-2.10.0 tensorboard-data-server-0.6.1 tensorboard-plugin-wit-1.8.1 tensorflow-2.7.4 tensorflow-addons-0.15.0 tensorflow-estimator-2.7.0 tensorflow-io-gcs-filesystem-0.27.0 tensorflow-text-2.7.3 tensorflow_hub-0.12.0 termcolor-2.0.1 terminaltables-3.1.10 threadpoolctl-3.1.0 toolz-0.12.0 twilio-6.50.1 typeguard-2.13.3 types-cryptography-3.3.23 typing-extensions-3.10.0.2 typing-utils-0.1.0 tzlocal-2.1 ujson-5.5.0 uvloop-0.17.0 webexteamssdk-1.6.1 websockets-10.3 werkzeug-2.2.2 wrapt-1.14.1 yarl-1.8.1 (rasa_py38) ashish@ashish-Lenovo-ideapad-130-15IKB:~/Desktop$ (rasa_py38) ashish@ashish-Lenovo-ideapad-130-15IKB:~/Desktop$ pip show rasa Name: rasa Version: 3.2.8 Summary: Open source machine learning framework to automate text- and voice-based conversations: NLU, dialogue management, connect to Slack, Facebook, and more - Create chatbots and voice assistants Home-page: https://rasa.com Author: Rasa Technologies GmbH Author-email: hi@rasa.com License: Apache-2.0 Location: /home/ashish/.local/lib/python3.8/site-packages Requires: absl-py, aio-pika, aiohttp, apscheduler, attrs, boto3, CacheControl, cloudpickle, colorclass, coloredlogs, colorhash, dask, fbmessenger, google-auth, joblib, jsonpickle, jsonschema, kafka-python, matplotlib, mattermostwrapper, networkx, numpy, packaging, prompt-toolkit, psycopg2-binary, pydot, PyJWT, pykwalify, pymongo, pyTelegramBotAPI, python-dateutil, python-engineio, python-socketio, pytz, questionary, randomname, rasa-sdk, redis, regex, requests, rocketchat_API, ruamel.yaml, sanic, sanic-cors, sanic-jwt, sanic-routing, scikit-learn, scipy, sentry-sdk, setuptools, sklearn-crfsuite, slackclient, SQLAlchemy, tarsafe, tensorflow, tensorflow-addons, tensorflow-text, tensorflow_hub, terminaltables, tqdm, twilio, typing-extensions, typing-utils, ujson, webexteamssdk Required-by:

Fix the PATH variable to enable RASA CLI

(rasa_py38) ashish@ashish-Lenovo-ideapad-130-15IKB:~/Desktop$ rasa rasa: command not found (rasa_py38) ashish@ashish-Lenovo-ideapad-130-15IKB:~/Desktop$ (rasa_py38) ashish@ashish-Lenovo-ideapad-130-15IKB:~/Desktop$ sudo nano ~/.bashrc [sudo] password for ashish: (rasa_py38) ashish@ashish-Lenovo-ideapad-130-15IKB:~/Desktop$ (rasa_py38) ashish@ashish-Lenovo-ideapad-130-15IKB:~/Desktop$ (rasa_py38) ashish@ashish-Lenovo-ideapad-130-15IKB:~/Desktop$ source ~/.bashrc (base) ashish@ashish-Lenovo-ideapad-130-15IKB:~/Desktop$ conda activate rasa_py38 (rasa_py38) ashish@ashish-Lenovo-ideapad-130-15IKB:~/Desktop$ rasa usage: rasa [-h] [--version] {init,run,shell,train,interactive,telemetry,test,visualize,data,export,x,evaluate} ... Rasa command line interface. Rasa allows you to build your own conversational assistants 🤖. The 'rasa' command allows you to easily run most common commands like creating a new bot, training or evaluating models. positional arguments: {init,run,shell,train,interactive,telemetry,test,visualize,data,export,x,evaluate} Rasa commands init Creates a new project, with example training data, actions, and config files. run Starts a Rasa server with your trained model. shell Loads your trained model and lets you talk to your assistant on the command line. train Trains a Rasa model using your NLU data and stories. interactive Starts an interactive learning session to create new training data for a Rasa model by chatting. telemetry Configuration of Rasa Open Source telemetry reporting. test Tests Rasa models using your test NLU data and stories. visualize Visualize stories. data Utils for the Rasa training files. export Export conversations using an event broker. evaluate Tools for evaluating models. optional arguments: -h, --help show this help message and exit --version Print installed Rasa version

The Fix of PATH Variable

(rasa_py38) ashish@ashish-Lenovo-ideapad-130-15IKB:~/Desktop$ echo $PATH /home/ashish/.local/bin:/home/ashish/anaconda3/envs/rasa_py38/bin:/home/ashish/anaconda3/condabin:/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin:/usr/games:/usr/local/games:/snap/bin:/snap/bin (rasa_py38) ashish@ashish-Lenovo-ideapad-130-15IKB:~/Desktop$
Tags: Technology,Python,Anaconda,Rasa,Natural Language Processing

Performance testing of BERT based Sentence Transformers for sentence encoding

Download Code

import pandas as pd
from sentence_transformers import SentenceTransformer

sbert_model = SentenceTransformer('bert-base-nli-mean-tokens')

df = pd.read_csv('nytEditorialSnippets_GroundTruth.txt', sep = '\t')

df_10 = df[0:10]
df_100 = df[0:100]

# 1. Using Sentence Encoder in a function on every record

def get_embedding(input_sentence):
    return sbert_model.encode([input_sentence])[0]

%%timeit
df_out_1 = df_100['text'].apply(get_embedding)



9.15 s ± 317 ms per loop (mean ± std. dev. of 7 runs, 1 loop each)



%%time
df_out_1 = df_100['text'].apply(get_embedding)



CPU times: user 18.3 s, sys: 112 ms, total: 18.5 s
Wall time: 9.25 s



%%time
df_out_1 = df_10['text'].apply(get_embedding)



CPU times: user 1.97 s, sys: 7.88 ms, total: 1.98 s
Wall time: 997 ms



df_out_1



0     [-0.7970602, 0.47616163, 0.2621567, 0.38846374...
1     [-0.32450542, -0.10945253, 0.6443658, 0.212320...
2     [-0.2602994, -0.0036350375, 1.2917686, 0.12602...
3     [0.5173101, -0.86385506, 1.5003084, 0.76273316...
4     [-0.19630705, 1.611963, 0.8502133, 0.059544455...
                            ...                        
95    [-0.7843676, 0.70446295, -0.86373883, 0.096476...
96    [-0.047543377, -1.0461698, 0.9984542, 0.776394...
97    [-0.5863306, 0.38590172, -0.15509816, 0.275745...
98    [0.22616625, 0.33843663, 0.030288033, 0.191214...
99    [0.40268317, 1.1528935, 0.3597172, 0.16918863,...
Name: text, Length: 100, dtype: object



type(df_out_1)



pandas.core.series.Series



# 2. Using Sentence Encoder on entire array of sentences at once

%%timeit
df_out_2 = sbert_model.encode(df_100['text'].values)



9.25 s ± 275 ms per loop (mean ± std. dev. of 7 runs, 1 loop each)



%%time
df_out_2 = sbert_model.encode(df_100['text'].values)



CPU times: user 17.8 s, sys: 1 s, total: 18.8 s
Wall time: 9.41 s



df_out_2



array([[-0.7970604 ,  0.4761617 ,  0.262157  , ..., -0.2437577 ,
1.1380528 ,  0.28697717],
[-0.32450542, -0.10945235,  0.64436567, ...,  0.14436643,
-0.24656864, -0.18447737],
[-0.26029944, -0.00363465,  1.2917686 , ...,  1.1463983 ,
-1.0714562 , -0.09548129],
...,
[-0.5863306 ,  0.38590172, -0.15509816, ..., -0.2937488 ,
-0.3724223 ,  0.1826524 ],
[ 0.22616649,  0.33843663,  0.03028765, ...,  0.66338176,
-0.6620043 ,  0.09410357],
[ 0.40268335,  1.152894  ,  0.35971704, ..., -0.9203086 ,
0.17893644,  0.71039814]], dtype=float32)



type(df_out_2)


numpy.ndarray

df_out_2.shape

(100, 768)
Tags: Technology,Natural Language Processing,

Sunday, September 18, 2022

Sentiment Analysis Using RNN with BOW indexing of words

Download Data   Download Code

import numpy as np 
import pandas as pd 
from sklearn.metrics import classification_report

df = pd.read_csv('input/sentences_and_phrases_150k/train.csv')

test_df = pd.read_csv('input/sentences_and_phrases_150k/test.csv')

from numpy import random
ix = list(range(df.shape[0]))
ix = random.permutation(ix)
div = int(df.shape[0] * 0.7)
train_df = df.iloc[ix[0:div]]
validation_df = df.iloc[ix[div:]]

import seaborn as sns
sns.countplot(x ='Sentiment', data = train_df)

train_df['Sentiment'].value_counts() 2 55723 3 22917 1 19105 4 6492 0 5005 The below function is used to preprocess the train and test data. 1.fillna(0) -fills NaN values (if any )with zero 2.Regular expression is used to match only the text data from the phrase 3. The text is the split to get the sentence. 4. every sentence is appended to Corpus for next use Note: Stemming or leematization or stop word removal is not applied here. Practioners can consider doing it for better result. import nltk, re def func(X): X=X.fillna(0) messages = X.copy() messages.reset_index(inplace=True) corpus=[] for i in range(len(messages)): review = re.sub('[^a-zA-Z]',' ',str(messages['Phrase'][i])) review = review.split() review = ' '.join(review) corpus.append(review) return corpus corpus_train = func(train_df) corpus_validation = func(validation_df) corpus_test = func(test_df) def get_wordlist(corpus1): words = [] for phrase in corpus1: for word in phrase.split(): words.append(word) words.sort() return set(words) word_set_train = get_wordlist(corpus_train) word_set_validation = get_wordlist(corpus_validation) word_set_test = get_wordlist(corpus_test) def get_dicts(word_set): word_to_index = {} for i, word in enumerate(word_set): word_to_index[word] = i index_to_word = {index:word for (word, index) in word_to_index.items()} return word_to_index, index_to_word word_to_index_train, index_to_word_train = get_dicts(word_set_train) word_to_index_validation, index_to_word_validation = get_dicts(word_set_validation) word_to_index_test, index_to_word_test = get_dicts(word_set_test) def token(corpus, word_to_index): tokenized_list = [] for phrase in corpus: tokenized_format = [] for word in phrase.split(): index = word_to_index[word] tokenized_format.append(index) tokenized_list.append(tokenized_format) return np.array(tokenized_list, dtype='object') from tensorflow import keras X_train = token(corpus_train, word_to_index_train) X_validation = token(corpus_validation, word_to_index_validation) X_test = token(corpus_test, word_to_index_test) In order to train the RNN on the tokenized data, all text input must have the same length. We will limit the maximum review length to maxlen=30 by truncating longer reviews and padding shorter reviews with a null value (0). Keras pad_sequences() function is used to accomplish this. maxlen = 30 X_train_padded = keras.preprocessing.sequence.pad_sequences(X_train, maxlen=maxlen, padding='post') X_validation_padded = keras.preprocessing.sequence.pad_sequences(X_validation, maxlen=maxlen, padding='post') X_test_padded = keras.preprocessing.sequence.pad_sequences(X_test, maxlen=maxlen, padding='post') y_train = train_df.iloc[:,-1].values y_validation = validation_df.iloc[:,-1].values from sklearn.preprocessing import OneHotEncoder encoder = OneHotEncoder(sparse=False) y_train_encoded = encoder.fit_transform(y_train.reshape(-1, 1)) #import the Keras layers from tensorflow.keras.models import Sequential from tensorflow.keras.layers import Embedding,Dense, Dropout, LSTM, Dropout vocabulary_size = len(word_to_index_train) + 1 embedding_size=30 A simple RNN model is built with 1 embedding layer, 1 simple RNN layer, 1 dense layer as hidden layer and one dense layer as output layer. 1.A Sequential model is appropriate for a plain stack of layers where each layer has exactly one input tensor and one output tensor. 2.Keras Embedding Layer takes encoded text data as input. Embedding layer is used as the first hidden layer of a network. It takes 3 arguments.Embedding(input dimension, out_dimension=embedding_size, trainable=True).Embedding layer has weights that are learned. 3.Simple RNN () class is a complete RNN layer in Keras with input unit = 32 neurons. It is a Fully-connected RNN where the output is to be fed back to input. for more detials visit the website: https://keras.io/api/layers/recurrent_layers/simple_rnn/ 3.A dense layer which is deeply connected with its preceding layer. The dense layer’s neuron in a model receives output from every neuron of its preceding layer, where neurons of the dense layer perform matrix-vector multiplication. Row vector of the output from the preceding layers (RNN layer) is equal to the column vector of the dense layer. 4. Last dense layer is the Output layer with 5 nodes indicating the probabilities of sentiment calculated. import tensorflow as tf model = tf.keras.Sequential([ tf.keras.layers.Embedding(vocabulary_size, embedding_size, trainable=True), tf.keras.layers.SimpleRNN(32), tf.keras.layers.Dense(10, activation='relu'), tf.keras.layers.Dense(5, activation='sigmoid') ]) model.summary() Model: "sequential_2" _________________________________________________________________ Layer (type) Output Shape Param # ================================================================= embedding_2 (Embedding) (None, None, 30) 503430 simple_rnn_2 (SimpleRNN) (None, 32) 2016 dense_4 (Dense) (None, 10) 330 dense_5 (Dense) (None, 5) 55 ================================================================= Total params: 505,831 Trainable params: 505,831 Non-trainable params: 0 _________________________________________________________________ Hyper Parameter We first need to compile our model by specifying the loss function and optimizer we want to use while training, as well as any evaluation metrics we’d like to measure. Specify the appropriate parameters, including at least one metric ‘accuracy’. Optimizer used:Adam optimizer is used as it has the most beneficial nature of its adaptive learning rate. It can compute adaptive learning rates for different parameters. Loss Function: Since, the label is one-hot encoded, categorical_crossentropy is used as loss function. suppose, the label is not one hot enocded, one can use Sparse_categorical_crossentropy as loss function. model.compile(optimizer='adam',loss='categorical_crossentropy',metrics=['accuracy']) model.fit(X_train_padded, y_train_encoded, batch_size=256, epochs=5 ) Epoch 1/5 427/427 [==============================] - 9s 19ms/step - loss: 1.2401 - accuracy: 0.5143 Epoch 2/5 427/427 [==============================] - 8s 18ms/step - loss: 1.0842 - accuracy: 0.5567 Epoch 3/5 427/427 [==============================] - 8s 18ms/step - loss: 1.0129 - accuracy: 0.5849 Epoch 4/5 427/427 [==============================] - 8s 18ms/step - loss: 0.9300 - accuracy: 0.6288 Epoch 5/5 427/427 [==============================] - 8s 18ms/step - loss: 0.8159 - accuracy: 0.6783 pred_validation = model.predict(X_validation_padded) pred1_validation = (pred_validation > 0.5).astype(int) labels = [0, 1, 2, 3, 4] LABELS_validation = [labels[i] for i in model.predict(X_validation_padded).argmax(axis=-1)] print(classification_report(validation_df['Sentiment'], y_pred = LABELS_validation, labels = labels)) precision recall f1-score support 0 0.06 0.03 0.04 2067 1 0.21 0.14 0.17 8168 2 0.56 0.64 0.60 23859 3 0.22 0.22 0.22 10010 4 0.08 0.11 0.09 2714 accuracy 0.40 46818 macro avg 0.23 0.23 0.22 46818 weighted avg 0.38 0.40 0.39 46818 pred = model.predict(X_test_padded) pred1=(pred > 0.5).astype(int) labels = ['negative', 'somewhat negative', 'neutral','somewhat positive','positive'] LABELS=[labels[i] for i in model.predict(X_test_padded).argmax(axis=-1)] predicted = pd.DataFrame({'Phrase': test_df.iloc[:,0].values, 'Sentiment': LABELS}) print(predicted)
Tags: Technology,Natural Language Processing,

Thursday, September 15, 2022

You have divergent branches and need to specify out of three options (merge, rebase, fast-forward) how to reconcile them. What to do?

You have divergent branches and need to specify out of three options (merge, rebase, fast-forward) how to reconcile them. What to do?

Let's experiment and figure out what these three reconciling strategies do.

Clone a Server Copy

(base) ashish@ashish-Lenovo-ideapad-130-15IKB:~/Desktop/git_practical/server/repo_for_testing$ git pull Username for 'https://github.com': ashishjain1547@gmail.com Password for 'https://ashishjain1547@gmail.com@github.com': Already up to date. (base) ashish@ashish-Lenovo-ideapad-130-15IKB:~/Desktop/git_practical/server/repo_for_testing$ git log commit b20128a7b6148aa7ed668cfe2531a54418e61097 (HEAD -> main, origin/main, origin/HEAD) Author: Ashish Jain <ashishjain1547@gmail.com> Date: Thu Sep 15 23:21:37 2022 +0530 20220915

Clone Three Local Copies

Local Copy 1

(base) ashish@ashish-Lenovo-ideapad-130-15IKB:~/Desktop/git_practical/local 1$ git clone https://github.com/ashishjain1547/repo_for_testing.git Cloning into 'repo_for_testing'... Username for 'https://github.com': ashishjain1547@gmail.com Password for 'https://ashishjain1547@gmail.com@github.com': remote: Enumerating objects: 39, done. remote: Counting objects: 100% (39/39), done. remote: Compressing objects: 100% (24/24), done. remote: Total 39 (delta 13), reused 23 (delta 4), pack-reused 0 Receiving objects: 100% (39/39), 8.45 KiB | 4.23 MiB/s, done. Resolving deltas: 100% (13/13), done.

Local Copy 2

(base) ashish@ashish-Lenovo-ideapad-130-15IKB:~/Desktop/git_practical/local 2$ git clone https://github.com/ashishjain1547/repo_for_testing.git Cloning into 'repo_for_testing'... Username for 'https://github.com': ashishjain1547@gmail.com Password for 'https://ashishjain1547@gmail.com@github.com': remote: Enumerating objects: 39, done. remote: Counting objects: 100% (39/39), done. remote: Compressing objects: 100% (24/24), done. remote: Total 39 (delta 13), reused 23 (delta 4), pack-reused 0 Receiving objects: 100% (39/39), 8.45 KiB | 2.82 MiB/s, done. Resolving deltas: 100% (13/13), done.

Local Copy 3

(base) ashish@ashish-Lenovo-ideapad-130-15IKB:~/Desktop/git_practical/local 3$ git clone https://github.com/ashishjain1547/repo_for_testing.git Cloning into 'repo_for_testing'... Username for 'https://github.com': ashishjain1547@gmail.com Password for 'https://ashishjain1547@gmail.com@github.com': remote: Enumerating objects: 39, done. remote: Counting objects: 100% (39/39), done. remote: Compressing objects: 100% (24/24), done. remote: Total 39 (delta 13), reused 23 (delta 4), pack-reused 0 Receiving objects: 100% (39/39), 8.45 KiB | 2.82 MiB/s, done. Resolving deltas: 100% (13/13), done. (base) ashish@ashish-Lenovo-ideapad-130-15IKB:~/Desktop/git_practical/local 3$

Update the Server Copy

(base) ashish@ashish-Lenovo-ideapad-130-15IKB:~/Desktop/git_practical/server/repo_for_testing$ echo " " > 20220915_2336.html (base) ashish@ashish-Lenovo-ideapad-130-15IKB:~/Desktop/git_practical/server/repo_for_testing$ git add -A (base) ashish@ashish-Lenovo-ideapad-130-15IKB:~/Desktop/git_practical/server/repo_for_testing$ git commit -m "20220915 II" [main 80b40f5] 20220915 II 1 file changed, 1 insertion(+) create mode 100644 20220915_2336.html (base) ashish@ashish-Lenovo-ideapad-130-15IKB:~/Desktop/git_practical/server/repo_for_testing$ git push Username for 'https://github.com': ashishjain1547@gmail.com Password for 'https://ashishjain1547@gmail.com@github.com': Enumerating objects: 3, done. Counting objects: 100% (3/3), done. Delta compression using up to 4 threads Compressing objects: 100% (2/2), done. Writing objects: 100% (2/2), 248 bytes | 248.00 KiB/s, done. Total 2 (delta 1), reused 0 (delta 0), pack-reused 0 remote: Resolving deltas: 100% (1/1), completed with 1 local object. To https://github.com/ashishjain1547/repo_for_testing.git b20128a..80b40f5 main -> main

Run Git Push Command on Local Copies Without Doing a Git Pull First.

Local Copy 1

(base) ashish@ashish-Lenovo-ideapad-130-15IKB:~/Desktop/git_practical/local 1$ cd repo_for_testing/ (base) ashish@ashish-Lenovo-ideapad-130-15IKB:~/Desktop/git_practical/local 1/repo_for_testing$ echo " " > 20220915_2340.txt (base) ashish@ashish-Lenovo-ideapad-130-15IKB:~/Desktop/git_practical/local 1/repo_for_testing$ git add -A (base) ashish@ashish-Lenovo-ideapad-130-15IKB:~/Desktop/git_practical/local 1/repo_for_testing$ git commit -m "20220915 Update on local copy 1" [main a01092f] 20220915 Update on local copy 1 1 file changed, 1 insertion(+) create mode 100644 20220915_2340.txt (base) ashish@ashish-Lenovo-ideapad-130-15IKB:~/Desktop/git_practical/local 1/repo_for_testing$ git push Username for 'https://github.com': ashishjain1547@gmail.com Password for 'https://ashishjain1547@gmail.com@github.com': To https://github.com/ashishjain1547/repo_for_testing.git ! [rejected] main -> main (fetch first) error: failed to push some refs to 'https://github.com/ashishjain1547/repo_for_testing.git' hint: Updates were rejected because the remote contains work that you do hint: not have locally. This is usually caused by another repository pushing hint: to the same ref. You may want to first integrate the remote changes hint: (e.g., 'git pull ...') before pushing again. hint: See the 'Note about fast-forwards' in 'git push --help' for details. (base) ashish@ashish-Lenovo-ideapad-130-15IKB:~/Desktop/git_practical/local 1/repo_for_testing$ (base) ashish@ashish-Lenovo-ideapad-130-15IKB:~/Desktop/git_practical/local 1/repo_for_testing$ git status On branch main Your branch is ahead of 'origin/main' by 1 commit. (use "git push" to publish your local commits) nothing to commit, working tree clean (base) ashish@ashish-Lenovo-ideapad-130-15IKB:~/Desktop/git_practical/local 1/repo_for_testing$ git pull Username for 'https://github.com': ashishjain1547@gmail.com Password for 'https://ashishjain1547@gmail.com@github.com': remote: Enumerating objects: 3, done. remote: Counting objects: 100% (3/3), done. remote: Compressing objects: 100% (1/1), done. remote: Total 2 (delta 1), reused 2 (delta 1), pack-reused 0 Unpacking objects: 100% (2/2), 228 bytes | 228.00 KiB/s, done. From https://github.com/ashishjain1547/repo_for_testing b20128a..80b40f5 main -> origin/main hint: You have divergent branches and need to specify how to reconcile them. hint: You can do so by running one of the following commands sometime before hint: your next pull: hint: hint: git config pull.rebase false # merge (the default strategy) hint: git config pull.rebase true # rebase hint: git config pull.ff only # fast-forward only hint: hint: You can replace "git config" with "git config --global" to set a default hint: preference for all repositories. You can also pass --rebase, --no-rebase, hint: or --ff-only on the command line to override the configured default per hint: invocation. fatal: Need to specify how to reconcile divergent branches. (base) ashish@ashish-Lenovo-ideapad-130-15IKB:~/Desktop/git_practical/local 1/repo_for_testing$ (base) ashish@ashish-Lenovo-ideapad-130-15IKB:~/Desktop/git_practical/local 1/repo_for_testing$ git status On branch main Your branch and 'origin/main' have diverged, and have 1 and 1 different commits each, respectively. (use "git pull" to merge the remote branch into yours) nothing to commit, working tree clean (base) ashish@ashish-Lenovo-ideapad-130-15IKB:~/Desktop/git_practical/local 1/repo_for_testing$ (base) ashish@ashish-Lenovo-ideapad-130-15IKB:~/Desktop/git_practical/local 1/repo_for_testing$ git log commit a01092fe6048d236bb71b1ea95d80e6084a340aa (HEAD -> main) Author: Ashish Jain <ashishjain1547@gmail.com> Date: Thu Sep 15 23:41:11 2022 +0530 20220915 Update on local copy 1 commit b20128a7b6148aa7ed668cfe2531a54418e61097 Author: Ashish Jain <ashishjain1547@gmail.com> Date: Thu Sep 15 23:21:37 2022 +0530 20220915 (base) ashish@ashish-Lenovo-ideapad-130-15IKB:~/Desktop/git_practical/local 1/repo_for_testing$ git pull Username for 'https://github.com': ashishjain1547@gmail.com Password for 'https://ashishjain1547@gmail.com@github.com': hint: You have divergent branches and need to specify how to reconcile them. hint: You can do so by running one of the following commands sometime before hint: your next pull: hint: hint: git config pull.rebase false # merge (the default strategy) hint: git config pull.rebase true # rebase hint: git config pull.ff only # fast-forward only hint: hint: You can replace "git config" with "git config --global" to set a default hint: preference for all repositories. You can also pass --rebase, --no-rebase, hint: or --ff-only on the command line to override the configured default per hint: invocation. fatal: Need to specify how to reconcile divergent branches. (base) ashish@ashish-Lenovo-ideapad-130-15IKB:~/Desktop/git_practical/local 1/repo_for_testing$ git config pull.rebase false (base) ashish@ashish-Lenovo-ideapad-130-15IKB:~/Desktop/git_practical/local 1/repo_for_testing$ git pull Username for 'https://github.com': ashishjain1547@gmail.com Password for 'https://ashishjain1547@gmail.com@github.com': Merge made by the 'ort' strategy. 20220915_2336.html | 1 + 1 file changed, 1 insertion(+) create mode 100644 20220915_2336.html (base) ashish@ashish-Lenovo-ideapad-130-15IKB:~/Desktop/git_practical/local 1/repo_for_testing$ ls -l total 64 -rw-rw-r-- 1 ashish ashish 29 Sep 15 23:31 20210528_test_branch.txt -rw-rw-r-- 1 ashish ashish 16 Sep 15 23:31 202107141543.txt -rw-rw-r-- 1 ashish ashish 16 Sep 15 23:31 202107141608.txt -rw-rw-r-- 1 ashish ashish 16 Sep 15 23:31 202107211228.txt -rw-rw-r-- 1 ashish ashish 12 Sep 15 23:31 202110111920.txt -rw-rw-r-- 1 ashish ashish 2 Sep 15 23:47 20220915_2336.html -rw-rw-r-- 1 ashish ashish 2 Sep 15 23:40 20220915_2340.txt -rw-rw-r-- 1 ashish ashish 2 Sep 15 23:31 20220915.txt -rw-rw-r-- 1 ashish ashish 7 Sep 15 23:31 Archana.txt -rw-rw-r-- 1 ashish ashish 45 Sep 15 23:31 Ashish -rw-rw-r-- 1 ashish ashish 11357 Sep 15 23:31 LICENSE -rw-rw-r-- 1 ashish ashish 10 Sep 15 23:31 newFile.txt -rw-rw-r-- 1 ashish ashish 36 Sep 15 23:31 README.md -rw-rw-r-- 1 ashish ashish 22 Sep 15 23:31 test_file_20210528.txt (base) ashish@ashish-Lenovo-ideapad-130-15IKB:~/Desktop/git_practical/local 1/repo_for_testing$ git log commit a24385b836c5e877571693b5e15a5a44512c1053 (HEAD -> main) Merge: a01092f 80b40f5 Author: Ashish Jain <ashishjain1547@gmail.com> Date: Thu Sep 15 23:47:47 2022 +0530 Merge branch 'main' of https://github.com/ashishjain1547/repo_for_testing commit a01092fe6048d236bb71b1ea95d80e6084a340aa Author: Ashish Jain <ashishjain1547@gmail.com> Date: Thu Sep 15 23:41:11 2022 +0530 20220915 Update on local copy 1 commit 80b40f50dcfebbcc39766c30ae5cb5b253f6d0ba (origin/main, origin/HEAD) Author: Ashish Jain <ashishjain1547@gmail.com> Date: Thu Sep 15 23:37:45 2022 +0530 20220915 II

Local copy is ahead of server by two commits.

(base) ashish@ashish-Lenovo-ideapad-130-15IKB:~/Desktop/git_practical/local 1/repo_for_testing$ git status On branch main Your branch is ahead of 'origin/main' by 2 commits. (use "git push" to publish your local commits) nothing to commit, working tree clean (base) ashish@ashish-Lenovo-ideapad-130-15IKB:~/Desktop/git_practical/local 1/repo_for_testing$ (base) ashish@ashish-Lenovo-ideapad-130-15IKB:~/Desktop/git_practical/local 1/repo_for_testing$ git push Username for 'https://github.com': ashishjain1547@gmail.com Password for 'https://ashishjain1547@gmail.com@github.com': Enumerating objects: 6, done. Counting objects: 100% (6/6), done. Delta compression using up to 4 threads Compressing objects: 100% (4/4), done. Writing objects: 100% (4/4), 529 bytes | 529.00 KiB/s, done. Total 4 (delta 2), reused 0 (delta 0), pack-reused 0 remote: Resolving deltas: 100% (2/2), completed with 1 local object. To https://github.com/ashishjain1547/repo_for_testing.git 80b40f5..a24385b main -> main (base) ashish@ashish-Lenovo-ideapad-130-15IKB:~/Desktop/git_practical/local 1/repo_for_testing$ git status On branch main Your branch is up to date with 'origin/main'. nothing to commit, working tree clean

Local Copy 2

$ git config pull.rebase true # rebase

(base) ashish@ashish-Lenovo-ideapad-130-15IKB:~/Desktop/git_practical/local 2$ cd repo_for_testing/ (base) ashish@ashish-Lenovo-ideapad-130-15IKB:~/Desktop/git_practical/local 2/repo_for_testing$ ls -l total 56 -rw-rw-r-- 1 ashish ashish 29 Sep 15 23:33 20210528_test_branch.txt -rw-rw-r-- 1 ashish ashish 16 Sep 15 23:33 202107141543.txt -rw-rw-r-- 1 ashish ashish 16 Sep 15 23:33 202107141608.txt -rw-rw-r-- 1 ashish ashish 16 Sep 15 23:33 202107211228.txt -rw-rw-r-- 1 ashish ashish 12 Sep 15 23:33 202110111920.txt -rw-rw-r-- 1 ashish ashish 2 Sep 15 23:33 20220915.txt -rw-rw-r-- 1 ashish ashish 7 Sep 15 23:33 Archana.txt -rw-rw-r-- 1 ashish ashish 45 Sep 15 23:33 Ashish -rw-rw-r-- 1 ashish ashish 11357 Sep 15 23:33 LICENSE -rw-rw-r-- 1 ashish ashish 10 Sep 15 23:33 newFile.txt -rw-rw-r-- 1 ashish ashish 36 Sep 15 23:33 README.md -rw-rw-r-- 1 ashish ashish 22 Sep 15 23:33 test_file_20210528.txt (base) ashish@ashish-Lenovo-ideapad-130-15IKB:~/Desktop/git_practical/local 2/repo_for_testing$ (base) ashish@ashish-Lenovo-ideapad-130-15IKB:~/Desktop/git_practical/local 2/repo_for_testing$ git status On branch main Your branch is up to date with 'origin/main'. nothing to commit, working tree clean (base) ashish@ashish-Lenovo-ideapad-130-15IKB:~/Desktop/git_practical/local 2/repo_for_testing$ (base) ashish@ashish-Lenovo-ideapad-130-15IKB:~/Desktop/git_practical/local 2/repo_for_testing$ echo "local copy 2" > 20220915_local_copy_2.txt (base) ashish@ashish-Lenovo-ideapad-130-15IKB:~/Desktop/git_practical/local 2/repo_for_testing$ git add -A (base) ashish@ashish-Lenovo-ideapad-130-15IKB:~/Desktop/git_practical/local 2/repo_for_testing$ git commit -m "local copy 2" [main 824f879] local copy 2 1 file changed, 1 insertion(+) create mode 100644 20220915_local_copy_2.txt (base) ashish@ashish-Lenovo-ideapad-130-15IKB:~/Desktop/git_practical/local 2/repo_for_testing$ git push Username for 'https://github.com': ashishjain1547@gmail.com Password for 'https://ashishjain1547@gmail.com@github.com': To https://github.com/ashishjain1547/repo_for_testing.git ! [rejected] main -> main (fetch first) error: failed to push some refs to 'https://github.com/ashishjain1547/repo_for_testing.git' hint: Updates were rejected because the remote contains work that you do hint: not have locally. This is usually caused by another repository pushing hint: to the same ref. You may want to first integrate the remote changes hint: (e.g., 'git pull ...') before pushing again. hint: See the 'Note about fast-forwards' in 'git push --help' for details. (base) ashish@ashish-Lenovo-ideapad-130-15IKB:~/Desktop/git_practical/local 2/repo_for_testing$ (base) ashish@ashish-Lenovo-ideapad-130-15IKB:~/Desktop/git_practical/local 2/repo_for_testing$ git status On branch main Your branch is ahead of 'origin/main' by 1 commit. (use "git push" to publish your local commits) nothing to commit, working tree clean (base) ashish@ashish-Lenovo-ideapad-130-15IKB:~/Desktop/git_practical/local 2/repo_for_testing$ git pull Username for 'https://github.com': ashishjain1547@gmail.com Password for 'https://ashishjain1547@gmail.com@github.com': remote: Enumerating objects: 7, done. remote: Counting objects: 100% (7/7), done. remote: Compressing objects: 100% (4/4), done. remote: Total 6 (delta 4), reused 4 (delta 2), pack-reused 0 Unpacking objects: 100% (6/6), 623 bytes | 311.00 KiB/s, done. From https://github.com/ashishjain1547/repo_for_testing b20128a..a24385b main -> origin/main hint: You have divergent branches and need to specify how to reconcile them. hint: You can do so by running one of the following commands sometime before hint: your next pull: hint: hint: git config pull.rebase false # merge (the default strategy) hint: git config pull.rebase true # rebase hint: git config pull.ff only # fast-forward only hint: hint: You can replace "git config" with "git config --global" to set a default hint: preference for all repositories. You can also pass --rebase, --no-rebase, hint: or --ff-only on the command line to override the configured default per hint: invocation. fatal: Need to specify how to reconcile divergent branches. (base) ashish@ashish-Lenovo-ideapad-130-15IKB:~/Desktop/git_practical/local 2/repo_for_testing$ git status On branch main Your branch and 'origin/main' have diverged, and have 1 and 3 different commits each, respectively. (use "git pull" to merge the remote branch into yours) nothing to commit, working tree clean (base) ashish@ashish-Lenovo-ideapad-130-15IKB:~/Desktop/git_practical/local 2/repo_for_testing$ (base) ashish@ashish-Lenovo-ideapad-130-15IKB:~/Desktop/git_practical/local 2/repo_for_testing$ git config pull.rebase true (base) ashish@ashish-Lenovo-ideapad-130-15IKB:~/Desktop/git_practical/local 2/repo_for_testing$ git pull Username for 'https://github.com': ashishjain1547@gmail.com Password for 'https://ashishjain1547@gmail.com@github.com': Successfully rebased and updated refs/heads/main. (base) ashish@ashish-Lenovo-ideapad-130-15IKB:~/Desktop/git_practical/local 2/repo_for_testing$ (base) ashish@ashish-Lenovo-ideapad-130-15IKB:~/Desktop/git_practical/local 2/repo_for_testing$ ls -l total 68 -rw-rw-r-- 1 ashish ashish 29 Sep 15 23:33 20210528_test_branch.txt -rw-rw-r-- 1 ashish ashish 16 Sep 15 23:33 202107141543.txt -rw-rw-r-- 1 ashish ashish 16 Sep 15 23:33 202107141608.txt -rw-rw-r-- 1 ashish ashish 16 Sep 15 23:33 202107211228.txt -rw-rw-r-- 1 ashish ashish 12 Sep 15 23:33 202110111920.txt -rw-rw-r-- 1 ashish ashish 2 Sep 16 00:00 20220915_2336.html -rw-rw-r-- 1 ashish ashish 2 Sep 16 00:00 20220915_2340.txt -rw-rw-r-- 1 ashish ashish 13 Sep 16 00:00 20220915_local_copy_2.txt -rw-rw-r-- 1 ashish ashish 2 Sep 15 23:33 20220915.txt -rw-rw-r-- 1 ashish ashish 7 Sep 15 23:33 Archana.txt -rw-rw-r-- 1 ashish ashish 45 Sep 15 23:33 Ashish -rw-rw-r-- 1 ashish ashish 11357 Sep 15 23:33 LICENSE -rw-rw-r-- 1 ashish ashish 10 Sep 15 23:33 newFile.txt -rw-rw-r-- 1 ashish ashish 36 Sep 15 23:33 README.md -rw-rw-r-- 1 ashish ashish 22 Sep 15 23:33 test_file_20210528.txt (base) ashish@ashish-Lenovo-ideapad-130-15IKB:~/Desktop/git_practical/local 2/repo_for_testing$ git status On branch main Your branch is ahead of 'origin/main' by 1 commit. (use "git push" to publish your local commits) nothing to commit, working tree clean (base) ashish@ashish-Lenovo-ideapad-130-15IKB:~/Desktop/git_practical/local 2/repo_for_testing$ git log commit 858945ca963a48977eea5682e6dc54eb1f87eba1 (HEAD -> main) Author: Ashish Jain <ashishjain1547@gmail.com> Date: Thu Sep 15 23:58:20 2022 +0530 local copy 2 commit a24385b836c5e877571693b5e15a5a44512c1053 (origin/main, origin/HEAD) Merge: a01092f 80b40f5 Author: Ashish Jain <ashishjain1547@gmail.com> Date: Thu Sep 15 23:47:47 2022 +0530 Merge branch 'main' of https://github.com/ashishjain1547/repo_for_testing commit a01092fe6048d236bb71b1ea95d80e6084a340aa Author: Ashish Jain <ashishjain1547@gmail.com> Date: Thu Sep 15 23:41:11 2022 +0530 20220915 Update on local copy 1 commit 80b40f50dcfebbcc39766c30ae5cb5b253f6d0ba Author: Ashish Jain <ashishjain1547@gmail.com> Date: Thu Sep 15 23:37:45 2022 +0530 20220915 II commit b20128a7b6148aa7ed668cfe2531a54418e61097 Author: Ashish Jain <ashishjain1547@gmail.com> Date: Thu Sep 15 23:21:37 2022 +0530 20220915 (base) ashish@ashish-Lenovo-ideapad-130-15IKB:~/Desktop/git_practical/local 2/repo_for_testing$ (base) ashish@ashish-Lenovo-ideapad-130-15IKB:~/Desktop/git_practical/local 2/repo_for_testing$ git status On branch main Your branch is ahead of 'origin/main' by 1 commit. (use "git push" to publish your local commits) nothing to commit, working tree clean (base) ashish@ashish-Lenovo-ideapad-130-15IKB:~/Desktop/git_practical/local 2/repo_for_testing$ git push Username for 'https://github.com': ashishjain1547@gmail.com Password for 'https://ashishjain1547@gmail.com@github.com': Enumerating objects: 4, done. Counting objects: 100% (4/4), done. Delta compression using up to 4 threads Compressing objects: 100% (2/2), done. Writing objects: 100% (3/3), 305 bytes | 305.00 KiB/s, done. Total 3 (delta 1), reused 0 (delta 0), pack-reused 0 remote: Resolving deltas: 100% (1/1), completed with 1 local object. To https://github.com/ashishjain1547/repo_for_testing.git a24385b..858945c main -> main (base) ashish@ashish-Lenovo-ideapad-130-15IKB:~/Desktop/git_practical/local 2/repo_for_testing$ git status On branch main Your branch is up to date with 'origin/main'. nothing to commit, working tree clean (base) ashish@ashish-Lenovo-ideapad-130-15IKB:~/Desktop/git_practical/local 2/repo_for_testing$

Local Copy 3

$ git config pull.ff only # fast-forward only

(base) ashish@ashish-Lenovo-ideapad-130-15IKB:~/Desktop/git_practical/local 3$ cd repo_for_testing/ (base) ashish@ashish-Lenovo-ideapad-130-15IKB:~/Desktop/git_practical/local 3/repo_for_testing$ git status On branch main Your branch is up to date with 'origin/main'. nothing to commit, working tree clean (base) ashish@ashish-Lenovo-ideapad-130-15IKB:~/Desktop/git_practical/local 3/repo_for_testing$ ls -l total 56 -rw-rw-r-- 1 ashish ashish 29 Sep 15 23:34 20210528_test_branch.txt -rw-rw-r-- 1 ashish ashish 16 Sep 15 23:34 202107141543.txt -rw-rw-r-- 1 ashish ashish 16 Sep 15 23:34 202107141608.txt -rw-rw-r-- 1 ashish ashish 16 Sep 15 23:34 202107211228.txt -rw-rw-r-- 1 ashish ashish 12 Sep 15 23:34 202110111920.txt -rw-rw-r-- 1 ashish ashish 2 Sep 15 23:34 20220915.txt -rw-rw-r-- 1 ashish ashish 7 Sep 15 23:34 Archana.txt -rw-rw-r-- 1 ashish ashish 45 Sep 15 23:34 Ashish -rw-rw-r-- 1 ashish ashish 11357 Sep 15 23:34 LICENSE -rw-rw-r-- 1 ashish ashish 10 Sep 15 23:34 newFile.txt -rw-rw-r-- 1 ashish ashish 36 Sep 15 23:34 README.md -rw-rw-r-- 1 ashish ashish 22 Sep 15 23:34 test_file_20210528.txt (base) ashish@ashish-Lenovo-ideapad-130-15IKB:~/Desktop/git_practical/local 3/repo_for_testing$ (base) ashish@ashish-Lenovo-ideapad-130-15IKB:~/Desktop/git_practical/local 3/repo_for_testing$ echo "local copy 3" > 20220915_local_copy_3.txt (base) ashish@ashish-Lenovo-ideapad-130-15IKB:~/Desktop/git_practical/local 3/repo_for_testing$ git add -A (base) ashish@ashish-Lenovo-ideapad-130-15IKB:~/Desktop/git_practical/local 3/repo_for_testing$ git commit -m "#" [main 5c8d1ff] # 1 file changed, 1 insertion(+) create mode 100644 20220915_local_copy_3.txt (base) ashish@ashish-Lenovo-ideapad-130-15IKB:~/Desktop/git_practical/local 3/repo_for_testing$ git push Username for 'https://github.com': ashishjain1547@gmail.com Password for 'https://ashishjain1547@gmail.com@github.com': To https://github.com/ashishjain1547/repo_for_testing.git ! [rejected] main -> main (fetch first) error: failed to push some refs to 'https://github.com/ashishjain1547/repo_for_testing.git' hint: Updates were rejected because the remote contains work that you do hint: not have locally. This is usually caused by another repository pushing hint: to the same ref. You may want to first integrate the remote changes hint: (e.g., 'git pull ...') before pushing again. hint: See the 'Note about fast-forwards' in 'git push --help' for details. (base) ashish@ashish-Lenovo-ideapad-130-15IKB:~/Desktop/git_practical/local 3/repo_for_testing$ (base) ashish@ashish-Lenovo-ideapad-130-15IKB:~/Desktop/git_practical/local 3/repo_for_testing$ git status On branch main Your branch is ahead of 'origin/main' by 1 commit. (use "git push" to publish your local commits) nothing to commit, working tree clean (base) ashish@ashish-Lenovo-ideapad-130-15IKB:~/Desktop/git_practical/local 3/repo_for_testing$ git pull Username for 'https://github.com': ashishjain1547@gmail.com Password for 'https://ashishjain1547@gmail.com@github.com': remote: Enumerating objects: 10, done. remote: Counting objects: 100% (10/10), done. remote: Compressing objects: 100% (6/6), done. remote: Total 9 (delta 5), reused 6 (delta 2), pack-reused 0 Unpacking objects: 100% (9/9), 875 bytes | 437.00 KiB/s, done. From https://github.com/ashishjain1547/repo_for_testing b20128a..858945c main -> origin/main hint: You have divergent branches and need to specify how to reconcile them. hint: You can do so by running one of the following commands sometime before hint: your next pull: hint: hint: git config pull.rebase false # merge (the default strategy) hint: git config pull.rebase true # rebase hint: git config pull.ff only # fast-forward only hint: hint: You can replace "git config" with "git config --global" to set a default hint: preference for all repositories. You can also pass --rebase, --no-rebase, hint: or --ff-only on the command line to override the configured default per hint: invocation. fatal: Need to specify how to reconcile divergent branches. (base) ashish@ashish-Lenovo-ideapad-130-15IKB:~/Desktop/git_practical/local 3/repo_for_testing$ git status On branch main Your branch and 'origin/main' have diverged, and have 1 and 4 different commits each, respectively. (use "git pull" to merge the remote branch into yours) nothing to commit, working tree clean (base) ashish@ashish-Lenovo-ideapad-130-15IKB:~/Desktop/git_practical/local 3/repo_for_testing$ (base) ashish@ashish-Lenovo-ideapad-130-15IKB:~/Desktop/git_practical/local 3/repo_for_testing$ (base) ashish@ashish-Lenovo-ideapad-130-15IKB:~/Desktop/git_practical/local 3/repo_for_testing$ git config pull.ff only (base) ashish@ashish-Lenovo-ideapad-130-15IKB:~/Desktop/git_practical/local 3/repo_for_testing$ ls -l total 60 -rw-rw-r-- 1 ashish ashish 29 Sep 15 23:34 20210528_test_branch.txt -rw-rw-r-- 1 ashish ashish 16 Sep 15 23:34 202107141543.txt -rw-rw-r-- 1 ashish ashish 16 Sep 15 23:34 202107141608.txt -rw-rw-r-- 1 ashish ashish 16 Sep 15 23:34 202107211228.txt -rw-rw-r-- 1 ashish ashish 12 Sep 15 23:34 202110111920.txt -rw-rw-r-- 1 ashish ashish 13 Sep 16 00:14 20220915_local_copy_3.txt -rw-rw-r-- 1 ashish ashish 2 Sep 15 23:34 20220915.txt -rw-rw-r-- 1 ashish ashish 7 Sep 15 23:34 Archana.txt -rw-rw-r-- 1 ashish ashish 45 Sep 15 23:34 Ashish -rw-rw-r-- 1 ashish ashish 11357 Sep 15 23:34 LICENSE -rw-rw-r-- 1 ashish ashish 10 Sep 15 23:34 newFile.txt -rw-rw-r-- 1 ashish ashish 36 Sep 15 23:34 README.md -rw-rw-r-- 1 ashish ashish 22 Sep 15 23:34 test_file_20210528.txt (base) ashish@ashish-Lenovo-ideapad-130-15IKB:~/Desktop/git_practical/local 3/repo_for_testing$ (base) ashish@ashish-Lenovo-ideapad-130-15IKB:~/Desktop/git_practical/local 3/repo_for_testing$ (base) ashish@ashish-Lenovo-ideapad-130-15IKB:~/Desktop/git_practical/local 3/repo_for_testing$ git status On branch main Your branch and 'origin/main' have diverged, and have 1 and 4 different commits each, respectively. (use "git pull" to merge the remote branch into yours) nothing to commit, working tree clean (base) ashish@ashish-Lenovo-ideapad-130-15IKB:~/Desktop/git_practical/local 3/repo_for_testing$ git log commit 5c8d1ff9d1e3d40daabf2b7cbcdc9f9b4e9003b3 (HEAD -> main) Author: Ashish Jain <ashishjain1547@gmail.com> Date: Fri Sep 16 00:14:43 2022 +0530 # commit b20128a7b6148aa7ed668cfe2531a54418e61097 Author: Ashish Jain <ashishjain1547@gmail.com> Date: Thu Sep 15 23:21:37 2022 +0530 20220915 commit 335cb1656a8b862733936531d0e00da92cea7f8f (origin/test_branch) Author: Ashish Jain <ashishjain1547@gmail.com> Date: Mon Oct 11 19:39:46 2021 +0530 Create Ashish commit 99da43ac015c1ed065796b4681ce2fdfd34d426c Author: unknown <ashishjain1547@gmail.com> Date: Mon Oct 11 19:37:33 2021 +0530 We will push this code with new file named Archana. commit be275fd83426869e3d8a27f8346ab903d6343faa Author: unknown <ashishjain1547@gmail.com> Date: Mon Oct 11 19:20:28 2021 +0530 20211011 1920 commit 9f1b42fe6b2cf1fbc3781cdb463b284f871ad291 Merge: d210505 087a5ca Author: unknown <ashishjain1547@gmail.com> Date: Wed Jul 21 12:41:37 2021 +0530 Merge branch 'test_branch' into main commit 087a5ca85b88f7303d025e8770183a6eabbeca7a Author: unknown <ashishjain1547@gmail.com> Date: Wed Jul 21 12:29:09 2021 +0530 20210721 1229 commit d2105058469fdb461a61578f8672e769d4426d79 Merge: daa4600 9017804 Author: Ashish Jain <ashishjain1547@gmail.com> Date: Wed Jul 14 16:25:29 2021 +0530 Merge pull request #1 from ashishjain1547/test_branch Test branch commit 901780465a07e7ce78932226db29a0898a07f4a2 Author: unknown <ashishjain1547@gmail.com> (base) ashish@ashish-Lenovo-ideapad-130-15IKB:~/Desktop/git_practical/local 3/repo_for_testing$ (base) ashish@ashish-Lenovo-ideapad-130-15IKB:~/Desktop/git_practical/local 3/repo_for_testing$ git pull Username for 'https://github.com': ashishjain1547@gmail.com Password for 'https://ashishjain1547@gmail.com@github.com': remote: Support for password authentication was removed on August 13, 2021. remote: Please see https://docs.github.com/en/get-started/getting-started-with-git/about-remote-repositories#cloning-with-https-urls for information on currently recommended modes of authentication. fatal: Authentication failed for 'https://github.com/ashishjain1547/repo_for_testing.git/' (base) ashish@ashish-Lenovo-ideapad-130-15IKB:~/Desktop/git_practical/local 3/repo_for_testing$ git pull Username for 'https://github.com': ashishjain1547@gmail.com Password for 'https://ashishjain1547@gmail.com@github.com': fatal: Not possible to fast-forward, aborting. (base) ashish@ashish-Lenovo-ideapad-130-15IKB:~/Desktop/git_practical/local 3/repo_for_testing$ (base) ashish@ashish-Lenovo-ideapad-130-15IKB:~/Desktop/git_practical/local 3/repo_for_testing$ git status On branch main Your branch and 'origin/main' have diverged, and have 1 and 4 different commits each, respectively. (use "git pull" to merge the remote branch into yours) nothing to commit, working tree clean (base) ashish@ashish-Lenovo-ideapad-130-15IKB:~/Desktop/git_practical/local 3/repo_for_testing$ git log commit 5c8d1ff9d1e3d40daabf2b7cbcdc9f9b4e9003b3 (HEAD -> main) Author: Ashish Jain <ashishjain1547@gmail.com> Date: Fri Sep 16 00:14:43 2022 +0530 # commit b20128a7b6148aa7ed668cfe2531a54418e61097 Author: Ashish Jain <ashishjain1547@gmail.com> Date: Thu Sep 15 23:21:37 2022 +0530 20220915 commit 335cb1656a8b862733936531d0e00da92cea7f8f (origin/test_branch) Author: Ashish Jain <ashishjain1547@gmail.com> Date: Mon Oct 11 19:39:46 2021 +0530 Create Ashish commit 99da43ac015c1ed065796b4681ce2fdfd34d426c Author: unknown <ashishjain1547@gmail.com> Date: Mon Oct 11 19:37:33 2021 +0530 We will push this code with new file named Archana. commit be275fd83426869e3d8a27f8346ab903d6343faa Author: unknown <ashishjain1547@gmail.com> Date: Mon Oct 11 19:20:28 2021 +0530 20211011 1920 commit 9f1b42fe6b2cf1fbc3781cdb463b284f871ad291 Merge: d210505 087a5ca Author: unknown <ashishjain1547@gmail.com> Date: Wed Jul 21 12:41:37 2021 +0530 Merge branch 'test_branch' into main commit 087a5ca85b88f7303d025e8770183a6eabbeca7a Author: unknown <ashishjain1547@gmail.com> Date: Wed Jul 21 12:29:09 2021 +0530 20210721 1229 commit d2105058469fdb461a61578f8672e769d4426d79 Merge: daa4600 9017804 Author: Ashish Jain <ashishjain1547@gmail.com> Date: Wed Jul 14 16:25:29 2021 +0530 Merge pull request #1 from ashishjain1547/test_branch Test branch commit 901780465a07e7ce78932226db29a0898a07f4a2 Author: unknown <ashishjain1547@gmail.com> (base) ashish@ashish-Lenovo-ideapad-130-15IKB:~/Desktop/git_practical/local 3/repo_for_testing$ (base) ashish@ashish-Lenovo-ideapad-130-15IKB:~/Desktop/git_practical/local 3/repo_for_testing$ (base) ashish@ashish-Lenovo-ideapad-130-15IKB:~/Desktop/git_practical/local 3/repo_for_testing$
Tags: Technology,GitHub,

Wednesday, September 14, 2022

Ten Commands For Day 1 With Ubuntu

1.

(base) ashish@ashishdesktop:~$ ls

anaconda3   Desktop   Documents   Downloads   Pictures  "PlayOnLinux's virtual drives"   Public   snap   Videos

2.

(base) ashish@ashishdesktop:~$ cd Desktop

(base) ashish@ashishdesktop:~/Desktop$ ls
'The Tsunami (Class 8th).odt'   ws

(base) ashish@ashishdesktop:~/Desktop$ ls -l
total 28
-rw-rw-r-- 1 ashish ashish 24290 Jul  6 21:37 'The Tsunami (Class 8th).odt'
drwxrwxr-x 6 ashish ashish  4096 Mar 15  2022  ws

(base) ashish@ashishdesktop:~/Desktop$ 
(base) ashish@ashishdesktop:~/Desktop$ 

3.

(base) ashish@ashishdesktop:~/Desktop$ mkdir moni

(base) ashish@ashishdesktop:~/Desktop$ ls -l

total 32
drwxrwxr-x 2 ashish ashish  4096 Sep 14 20:16  moni
-rw-rw-r-- 1 ashish ashish 24290 Jul  6 21:37 'The Tsunami (Class 8th).odt'
drwxrwxr-x 6 ashish ashish  4096 Mar 15  2022  ws

(base) ashish@ashishdesktop:~/Desktop$ 

(base) ashish@ashishdesktop:~/Desktop$ cd moni
(base) ashish@ashishdesktop:~/Desktop/moni$ 
(base) ashish@ashishdesktop:~/Desktop/moni$ 
(base) ashish@ashishdesktop:~/Desktop/moni$ ls -l
total 0

4.

(base) ashish@ashishdesktop:~/Desktop/moni$ touch moni.html
(base) ashish@ashishdesktop:~/Desktop/moni$ ls -l
total 0
-rw-rw-r-- 1 ashish ashish 0 Sep 14 20:21 moni.html
(base) ashish@ashishdesktop:~/Desktop/moni$ 

5.

(base) ashish@ashishdesktop:~/Desktop/moni$ gedit moni.html
(base) ashish@ashishdesktop:~/Desktop/moni$ 
(base) ashish@ashishdesktop:~/Desktop/moni$ ls -l
total 4
-rw-rw-r-- 1 ashish ashish 35 Sep 14 20:27 moni.html
(base) ashish@ashishdesktop:~/Desktop/moni$ 

6.

(base) ashish@ashishdesktop:~/Desktop/moni$ ls
moni.html
(base) ashish@ashishdesktop:~/Desktop/moni$ touch dummy.html
(base) ashish@ashishdesktop:~/Desktop/moni$ 
(base) ashish@ashishdesktop:~/Desktop/moni$ ls -l
total 4
-rw-rw-r-- 1 ashish ashish  0 Sep 14 21:58 dummy.html
-rw-rw-r-- 1 ashish ashish 35 Sep 14 20:27 moni.html
(base) ashish@ashishdesktop:~/Desktop/moni$ 
(base) ashish@ashishdesktop:~/Desktop/moni$ gedit dummy.html
(base) ashish@ashishdesktop:~/Desktop/moni$ ls -l
total 8
-rw-rw-r-- 1 ashish ashish  6 Sep 14 21:59 dummy.html
-rw-rw-r-- 1 ashish ashish 35 Sep 14 20:27 moni.html
(base) ashish@ashishdesktop:~/Desktop/moni$ 
(base) ashish@ashishdesktop:~/Desktop/moni$ rm dummy.html
(base) ashish@ashishdesktop:~/Desktop/moni$ 
(base) ashish@ashishdesktop:~/Desktop/moni$ ls -l
total 4
-rw-rw-r-- 1 ashish ashish 35 Sep 14 20:27 moni.html

7.

(base) ashish@ashishdesktop:~/Desktop/moni$ cat moni.html
<pre>
my name is moni singh.
</pre>

8.

(base) ashish@ashishdesktop:~/Desktop/moni$ pwd
/home/ashish/Desktop/moni

9.

(base) ashish@ashishdesktop:~/Desktop/moni$ echo $USER
ashish
(base) ashish@ashishdesktop:~/Desktop/moni$ echo $HOME
/home/ashish

10.

(base) ashish@ashishdesktop:~/Desktop/moni$ uname -a

Linux ashishdesktop 5.15.0-41-generic #44-Ubuntu SMP Wed Jun 22 14:20:53 UTC 2022 x86_64 x86_64 x86_64 GNU/Linux

(base) ashish@ashishdesktop:~/Desktop/moni$ uname

Linux

FAQs

Ques 1: What is Terminal? Ans 1: Terminal is a command line interface to the Ubuntu operating system. As of Oct, 2021: Terminal icon is depicted by a 'black background with letters ">_". "Terminal" is an application that is used to run command like: "ls", "cd" and "echo". manju@manju-desktop:~$ ls Desktop Documents Downloads Music Pictures Public Templates Videos manju@manju-desktop:~$ manju@manju-desktop:~$ ls -l total 32 drwxr-xr-x 2 manju manju 4096 Oct 1 23:34 Desktop drwxr-xr-x 2 manju manju 4096 Oct 1 20:56 Documents drwxr-xr-x 2 manju manju 4096 Apr 7 11:58 Downloads drwxr-xr-x 2 manju manju 4096 Apr 7 11:58 Music drwxr-xr-x 2 manju manju 4096 Apr 7 11:58 Pictures drwxr-xr-x 2 manju manju 4096 Apr 7 11:58 Public drwxr-xr-x 2 manju manju 4096 Apr 7 11:58 Templates drwxr-xr-x 2 manju manju 4096 Apr 7 11:58 Videos manju@manju-desktop:~$ cd Desktop manju@manju-desktop:~/Desktop$ ls -l total 4 -rw-rw-r-- 1 manju manju 537 Oct 1 23:34 'Beginner FAQs for Ubuntu.txt' --- Ques 2: How to browse internet? Answer 2: Use broswers: 1. Mozilla Firefox Browser. 2. Google Chrome. --- Ques 3: How to install Google Chrome. Answer: Use 'Ubuntu Software'. Step 1: Open "Ubuntu Software". Step 2: Press 'Ctrl+F' to launch 'Find and Search'. OR Step 1: Do a Google search in Firefox: "google chrome ubuntu" Step 2: On "Google Chrome Download" page, select "64 bit .deb (For Debian/Ubuntu)" radio button. Step 3: Click on "Accept and Install". ---
Tags: Technology,Linux,