From 13d7f41d256418a35f60edc93641379bf5dfe57e Mon Sep 17 00:00:00 2001 From: mortonjt Date: Tue, 8 Mar 2022 14:56:48 -0500 Subject: [PATCH 1/3] updating ci dependencies --- ci/conda_requirements.yml | 373 +++++++++++++++++++++++--------------- 1 file changed, 228 insertions(+), 145 deletions(-) diff --git a/ci/conda_requirements.yml b/ci/conda_requirements.yml index 63a02d2..33ea240 100644 --- a/ci/conda_requirements.yml +++ b/ci/conda_requirements.yml @@ -1,153 +1,236 @@ +name: deepblast2 channels: - - pytorch + - biobakery - conda-forge + - bioconda - defaults dependencies: - - bzip2=1.0.8=h516909a_0 - - cffi=1.12.3=py37h8022711_0 - - cycler=0.10.0=py_1 - - freetype=2.10.0=he983fc9_1 - - icu=64.2=he1b5a44_1 - - joblib=0.13.2=py_0 - - kiwisolver=1.1.0=py37hc9558a2_0 - - libblas=3.8.0=12_openblas - - libcblas=3.8.0=12_openblas - - libffi=3.2.1=he1b5a44_1006 - - liblapack=3.8.0=12_openblas - - libopenblas=0.3.7=h6e990d7_1 - - libpng=1.6.37=hed695b0_0 - - matplotlib-base=3.1.1=py37he7580a8_1 - - ncurses=6.1=hf484d3e_1002 - - ninja=1.9.0=h6bb024c_0 - - pandas=0.25.1=py37hb3f55d8_0 - - patsy=0.5.1=py_0 - - pip=19.2.3=py37_0 - - pycparser=2.19=py37_1 - - pyparsing=2.4.2=py_0 - - python=3.7.3=h33d41f4_1 - - python-dateutil=2.8.0=py_0 - - pytz=2019.2=py_0 - - readline=8.0=hf8c457e_0 - - scikit-learn=0.21.3=py37hcdab131_0 - - seaborn=0.9.0=py_1 - - setuptools=41.2.0=py37_0 - - six=1.12.0=py37_1000 - - sqlite=3.29.0=hcee41ef_1 - - statsmodels=0.10.1=py37hc1659b7_0 - - tk=8.6.9=hed695b0_1002 - - tornado=6.0.3=py37h516909a_0 - - tqdm=4.35.0=py_0 - - wheel=0.33.6=py37_0 - - xz=5.2.4=h14c3975_1001 - - zlib=1.2.11=h516909a_1005 - - _libgcc_mutex=0.1=main - - backcall=0.1.0=py37_0 - - biopython=1.76=py37h7b6447c_0 - - blas=1.0=openblas - - ca-certificates=2020.1.1=0 - - certifi=2020.4.5.1=py37_0 - - cudatoolkit=10.0.130=0 - - decorator=4.4.0=py37_1 - - flake8=3.8.2=py_0 - - importlib-metadata=1.6.0=py37_0 - - intel-openmp=2019.4=243 - - ipython=7.8.0=py37h39e3cac_0 - - ipython_genutils=0.2.0=py37_0 - - jedi=0.15.1=py37_0 - - libgcc-ng=9.1.0=hdf63c60_0 - - libgfortran-ng=7.3.0=hdf63c60_0 - - libstdcxx-ng=9.1.0=hdf63c60_0 - - mccabe=0.6.1=py37_1 - - mkl=2019.4=243 - - numpy=1.18.1=py37h94c655d_0 - - numpy-base=1.18.1=py37h2f8d375_1 - - openssl=1.1.1g=h7b6447c_0 - - parso=0.5.1=py_0 - - pexpect=4.7.0=py37_0 - - pickleshare=0.7.5=py37_0 - - prompt_toolkit=2.0.10=py_0 - - ptyprocess=0.6.0=py37_0 - - pycodestyle=2.6.0=py_0 - - pyflakes=2.2.0=py_0 - - pygments=2.4.2=py_0 - - scipy=1.4.1=py37habc2bb6_0 - - traitlets=4.3.3=py37_0 - - wcwidth=0.1.7=py37_0 - - zipp=3.1.0=py_0 - - pytorch=1.4.0=py3.7_cuda10.0.130_cudnn7.6.3_0 + - _libgcc_mutex=0.1=conda_forge + - _openmp_mutex=4.5=1_gnu + - alsa-lib=1.2.3=h516909a_0 + - argon2-cffi=21.3.0=pyhd8ed1ab_0 + - argon2-cffi-bindings=21.2.0=py39h3811e60_1 + - asttokens=2.0.5=pyhd8ed1ab_0 + - attrs=21.4.0=pyhd8ed1ab_0 + - backcall=0.2.0=pyh9f0ad1d_0 + - backports=1.0=py_2 + - backports.functools_lru_cache=1.6.4=pyhd8ed1ab_0 + - biopython=1.79=py39h3811e60_1 + - bleach=4.1.0=pyhd8ed1ab_0 + - brotli=1.0.9=h7f98852_6 + - brotli-bin=1.0.9=h7f98852_6 + - bzip2=1.0.8=h7f98852_4 + - ca-certificates=2021.10.8=ha878542_0 + - certifi=2021.10.8=py39hf3d152e_1 + - cffi=1.15.0=py39h4bc2ebd_0 + - cycler=0.11.0=pyhd8ed1ab_0 + - dbus=1.13.6=h5008d03_3 + - debugpy=1.5.1=py39he80948d_0 + - decorator=5.1.1=pyhd8ed1ab_0 + - defusedxml=0.7.1=pyhd8ed1ab_0 + - entrypoints=0.4=pyhd8ed1ab_0 + - executing=0.8.3=pyhd8ed1ab_0 + - expat=2.4.6=h27087fc_0 + - flit-core=3.7.1=pyhd8ed1ab_0 + - font-ttf-dejavu-sans-mono=2.37=hab24e00_0 + - font-ttf-inconsolata=3.000=h77eed37_0 + - font-ttf-source-code-pro=2.038=h77eed37_0 + - font-ttf-ubuntu=0.83=hab24e00_0 + - fontconfig=2.13.96=ha180cfb_0 + - fonts-conda-ecosystem=1=0 + - fonts-conda-forge=1=0 + - fonttools=4.29.1=py39h3811e60_0 + - freetype=2.10.4=h0708190_1 + - gettext=0.19.8.1=h73d1719_1008 + - giflib=5.2.1=h36c2ea0_2 + - gst-plugins-base=1.18.5=hf529b03_3 + - gstreamer=1.18.5=h9f60fe5_3 + - hmmer=3.3.2=h87f3376_2 + - icu=69.1=h9c3ff4c_0 + - importlib-metadata=4.11.2=py39hf3d152e_0 + - importlib_resources=5.4.0=pyhd8ed1ab_0 + - ipykernel=6.9.1=py39hef51801_0 + - ipython=8.1.1=py39hf3d152e_0 + - ipython_genutils=0.2.0=py_1 + - ipywidgets=7.6.5=pyhd8ed1ab_0 + - jbig=2.1=h7f98852_2003 + - jedi=0.18.1=py39hf3d152e_0 + - jinja2=3.0.3=pyhd8ed1ab_0 + - jpeg=9e=h7f98852_0 + - jsonschema=4.4.0=pyhd8ed1ab_0 + - jupyter=1.0.0=py39hf3d152e_7 + - jupyter_client=7.1.2=pyhd8ed1ab_0 + - jupyter_console=6.4.3=pyhd8ed1ab_0 + - jupyter_core=4.9.2=py39hf3d152e_0 + - jupyterlab_pygments=0.1.2=pyh9f0ad1d_0 + - jupyterlab_widgets=1.0.2=pyhd8ed1ab_0 + - keyutils=1.6.1=h166bdaf_0 + - kiwisolver=1.3.2=py39h1a9c180_1 + - krb5=1.19.2=h3790be6_4 + - lcms2=2.12=hddcbb42_0 + - ld_impl_linux-64=2.36.1=hea4e1c9_2 + - lerc=3.0=h9c3ff4c_0 + - libblas=3.9.0=13_linux64_openblas + - libbrotlicommon=1.0.9=h7f98852_6 + - libbrotlidec=1.0.9=h7f98852_6 + - libbrotlienc=1.0.9=h7f98852_6 + - libcblas=3.9.0=13_linux64_openblas + - libclang=13.0.1=default_hc23dcda_0 + - libdeflate=1.10=h7f98852_0 + - libedit=3.1.20191231=he28a2e2_2 + - libevent=2.1.10=h9b69904_4 + - libffi=3.4.2=h7f98852_5 + - libgcc-ng=11.2.0=h1d223b6_13 + - libgfortran-ng=11.2.0=h69a702a_13 + - libgfortran5=11.2.0=h5c6108e_13 + - libglib=2.70.2=h174f98d_4 + - libgomp=11.2.0=h1d223b6_13 + - libiconv=1.16=h516909a_0 + - liblapack=3.9.0=13_linux64_openblas + - libllvm11=11.1.0=hf817b99_3 + - libllvm13=13.0.1=hf817b99_2 + - libnsl=2.0.0=h7f98852_0 + - libogg=1.3.4=h7f98852_1 + - libopenblas=0.3.18=pthreads_h8fe5266_0 + - libopus=1.3.1=h7f98852_1 + - libpng=1.6.37=h21135ba_2 + - libpq=14.2=hd57d9b9_0 + - libsodium=1.0.18=h36c2ea0_1 + - libstdcxx-ng=11.2.0=he4da1e4_13 + - libtiff=4.3.0=h542a066_3 + - libuuid=2.32.1=h7f98852_1000 + - libvorbis=1.3.7=h9c3ff4c_0 + - libwebp=1.2.2=h3452ae3_0 + - libwebp-base=1.2.2=h7f98852_1 + - libxcb=1.13=h7f98852_1004 + - libxkbcommon=1.0.3=he3ba5ed_0 + - libxml2=2.9.12=h885dcf4_1 + - libzlib=1.2.11=h36c2ea0_1013 + - llvmlite=0.38.0=py39h1bbdace_0 + - lz4-c=1.9.3=h9c3ff4c_1 + - markupsafe=2.1.0=py39hb9d737c_1 + - matplotlib=3.5.1=py39hf3d152e_0 + - matplotlib-base=3.5.1=py39h2fa2bec_0 + - matplotlib-inline=0.1.3=pyhd8ed1ab_0 + - mistune=0.8.4=py39h3811e60_1005 + - munkres=1.1.4=pyh9f0ad1d_0 + - mysql-common=8.0.28=ha770c72_0 + - mysql-libs=8.0.28=hfa10184_0 + - nbclient=0.5.12=pyhd8ed1ab_0 + - nbconvert=6.4.2=py39hf3d152e_0 + - nbformat=5.1.3=pyhd8ed1ab_0 + - ncurses=6.3=h9c3ff4c_0 + - nest-asyncio=1.5.4=pyhd8ed1ab_0 + - notebook=6.4.8=pyha770c72_0 + - nspr=4.32=h9c3ff4c_1 + - nss=3.74=hb5efdd6_0 + - numba=0.55.1=py39h56b8d98_0 + - numpy=1.21.5=py39haac66dc_0 + - openjpeg=2.4.0=hb52868f_1 + - openssl=1.1.1l=h7f98852_0 + - packaging=21.3=pyhd8ed1ab_0 + - pandas=1.4.1=py39hde0f152_0 + - pandoc=2.17.1.1=ha770c72_0 + - pandocfilters=1.5.0=pyhd8ed1ab_0 + - parso=0.8.3=pyhd8ed1ab_0 + - pcre=8.45=h9c3ff4c_0 + - pexpect=4.8.0=pyh9f0ad1d_2 + - pickleshare=0.7.5=py_1003 + - pillow=9.0.1=py39hae2aec6_2 + - pip=22.0.4=pyhd8ed1ab_0 + - prometheus_client=0.13.1=pyhd8ed1ab_0 + - prompt-toolkit=3.0.27=pyha770c72_0 + - prompt_toolkit=3.0.27=hd8ed1ab_0 + - pthread-stubs=0.4=h36c2ea0_1001 + - ptyprocess=0.7.0=pyhd3deb0d_0 + - pure_eval=0.2.2=pyhd8ed1ab_0 + - pycparser=2.21=pyhd8ed1ab_0 + - pygments=2.11.2=pyhd8ed1ab_0 + - pyparsing=3.0.7=pyhd8ed1ab_0 + - pyqt=5.12.3=py39hf3d152e_8 + - pyqt-impl=5.12.3=py39hde8b62d_8 + - pyqt5-sip=4.19.18=py39he80948d_8 + - pyqtchart=5.12=py39h0fcd23e_8 + - pyqtwebengine=5.12.1=py39h0fcd23e_8 + - pyrsistent=0.18.1=py39h3811e60_0 + - python=3.9.10=h85951f9_2_cpython + - python-dateutil=2.8.2=pyhd8ed1ab_0 + - python_abi=3.9=2_cp39 + - pytz=2021.3=pyhd8ed1ab_0 + - pyzmq=22.3.0=py39h37b5a0c_1 + - qt=5.12.9=ha98a1a1_5 + - qtconsole=5.2.2=pyhd8ed1ab_1 + - qtconsole-base=5.2.2=pyhd8ed1ab_1 + - qtpy=2.0.1=pyhd8ed1ab_0 + - readline=8.1=h46c0cb4_0 + - scipy=1.8.0=py39hee8e79c_1 + - send2trash=1.8.0=pyhd8ed1ab_0 + - setuptools=60.9.3=py39hf3d152e_0 + - six=1.16.0=pyh6c4a22f_0 + - sqlite=3.37.0=h9cd32fc_0 + - stack_data=0.2.0=pyhd8ed1ab_0 + - terminado=0.13.3=py39hf3d152e_0 + - testpath=0.6.0=pyhd8ed1ab_0 + - tk=8.6.12=h27826a3_0 + - tornado=6.1=py39h3811e60_2 + - traitlets=5.1.1=pyhd8ed1ab_0 + - tzdata=2021e=he74cb21_0 + - unicodedata2=14.0.0=py39h3811e60_0 + - wcwidth=0.2.5=pyh9f0ad1d_2 + - webencodings=0.5.1=py_1 + - wheel=0.37.1=pyhd8ed1ab_0 + - widgetsnbextension=3.5.2=py39hf3d152e_1 + - xorg-libxau=1.0.9=h7f98852_0 + - xorg-libxdmcp=1.1.3=h7f98852_0 + - xz=5.2.5=h516909a_1 + - zeromq=4.3.4=h9c3ff4c_1 + - zipp=3.7.0=pyhd8ed1ab_1 + - zlib=1.2.11=h36c2ea0_1013 + - zstd=1.5.2=ha95c52a_0 - pip: - - absl-py==0.9.0 - - appdirs==1.4.3 - - attrs==19.3.0 - - bleach==3.1.0 - - cachecontrol==0.12.6 - - cachetools==4.1.0 - - chardet==3.0.4 - - cherrypy==3.2.4 - - configparser==4.0.2 - - cython==0.29.14 - - defusedxml==0.6.0 - - entrypoints==0.3 - - fairseq==0.8.0 - - fastbpe==0.1.0 + - absl-py==1.0.0 + - aiohttp==3.8.1 + - aiosignal==1.2.0 + - async-timeout==4.0.2 + - cachetools==5.0.0 + - charset-normalizer==2.0.12 + - frozenlist==1.3.0 + - fsspec==2022.2.0 - future==0.18.2 - - google-auth==1.16.1 - - google-auth-oauthlib==0.4.1 - - grpcio==1.29.0 - - hdmedians==0.13 - - idna==2.8 - - ipykernel==5.1.3 - - ipywidgets==7.5.1 - - jinja2==2.10.3 - - jsonschema==3.2.0 - - jupyter==1.0.0 - - jupyter-client==5.3.4 - - jupyter-console==6.0.0 - - jupyter-core==4.6.1 - - llvmlite==0.31.0 - - lockfile==0.12.2 - - markdown==3.2.2 - - markupsafe==1.1.1 - - matplotlib==3.1.1 - - mistune==0.8.4 - - more-itertools==8.0.2 - - msgpack==0.6.2 - - natsort==6.2.0 - - nbconvert==5.6.1 - - nbformat==4.4.0 - - notebook==6.0.2 - - numba==0.47.0 - - oauthlib==3.1.0 - - packaging==20.1 - - pandocfilters==1.4.2 - - pluggy==0.13.1 - - portalocker==1.5.1 - - prometheus-client==0.7.1 - - protobuf==3.12.2 - - py==1.8.1 + - google-auth==2.6.0 + - google-auth-oauthlib==0.4.6 + - grpcio==1.44.0 + - idna==3.3 + - iniconfig==1.1.1 + - joblib==1.1.0 + - markdown==3.3.6 + - multidict==6.0.2 + - oauthlib==3.2.0 + - pluggy==1.0.0 + - protobuf==3.19.4 + - py==1.11.0 - pyasn1==0.4.8 - pyasn1-modules==0.2.8 - - pyrsistent==0.15.6 - - pytest==5.4.3 - - pytorch-lightning==0.8.1 - - pyyaml==5.3.1 - - pyzmq==18.1.1 - - qtconsole==4.6.0 - - regex==2019.8.19 - - requests==2.22.0 - - requests-oauthlib==1.3.0 - - rsa==4.0 - - sacrebleu==1.4.2 - - scikit-bio==0.5.5 - - send2trash==1.5.0 - - tensorboard==2.2.2 - - tensorboard-plugin-wit==1.6.0.post3 - - terminado==0.8.3 - - testpath==0.4.4 - - torch==1.4.0 - - typing==3.7.4.1 - - urllib3==1.25.7 - - webencodings==0.5.1 - - werkzeug==1.0.1 - - widgetsnbextension==3.5.1 - + - pydeprecate==0.3.1 + - pytest==7.0.1 + - pytorch-lightning==1.5.8 + - pyyaml==6.0 + - requests==2.27.1 + - requests-oauthlib==1.3.1 + - rsa==4.8 + - scikit-learn==1.0.2 + - tensorboard==2.8.0 + - tensorboard-data-server==0.6.1 + - tensorboard-plugin-wit==1.8.1 + - threadpoolctl==3.1.0 + - tomli==2.0.1 + - torch==1.10.2+cu113 + - torchaudio==0.10.2+cu113 + - torchmetrics==0.7.2 + - torchvision==0.11.3+cu113 + - tqdm==4.63.0 + - typing-extensions==4.1.1 + - urllib3==1.26.8 + - werkzeug==2.0.3 + - yarl==1.7.2 +prefix: /mnt/home/jmorton/miniconda3/envs/deepblast2 From e1cfd83e661a25f648c6309c68a5c1d41dc78c80 Mon Sep 17 00:00:00 2001 From: mortonjt Date: Wed, 30 Mar 2022 21:05:22 -0400 Subject: [PATCH 2/3] adding backwards compatible fix to load models --- deepblast/trainer.py | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/deepblast/trainer.py b/deepblast/trainer.py index 164c5f5..c2b8b0d 100644 --- a/deepblast/trainer.py +++ b/deepblast/trainer.py @@ -25,7 +25,11 @@ class LightningAligner(pl.LightningModule): def __init__(self, args): super(LightningAligner, self).__init__() - self._hparams = args + if isinstance(args, dict): + self._hparams = argparse.Namespace(**args) + else: + self._hparams = args + self.tokenizer = UniprotTokenizer(pad_ends=False) #self.hparams = args self.initialize_aligner() From b5bd93b93ac1d59222693a7c511b0ce41241d29e Mon Sep 17 00:00:00 2001 From: mortonjt Date: Wed, 30 Mar 2022 21:07:30 -0400 Subject: [PATCH 3/3] updating ci --- ci/conda_requirements.yml | 8 +++----- 1 file changed, 3 insertions(+), 5 deletions(-) diff --git a/ci/conda_requirements.yml b/ci/conda_requirements.yml index 33ea240..ed404b7 100644 --- a/ci/conda_requirements.yml +++ b/ci/conda_requirements.yml @@ -1,6 +1,5 @@ name: deepblast2 channels: - - biobakery - conda-forge - bioconda - defaults @@ -224,13 +223,12 @@ dependencies: - tensorboard-plugin-wit==1.8.1 - threadpoolctl==3.1.0 - tomli==2.0.1 - - torch==1.10.2+cu113 - - torchaudio==0.10.2+cu113 + - torch==1.10.2 + - torchaudio==0.10.2 - torchmetrics==0.7.2 - - torchvision==0.11.3+cu113 + - torchvision==0.11.3 - tqdm==4.63.0 - typing-extensions==4.1.1 - urllib3==1.26.8 - werkzeug==2.0.3 - yarl==1.7.2 -prefix: /mnt/home/jmorton/miniconda3/envs/deepblast2