Housekeeping - upgrade to Torch 1.3.1#28
Conversation
Couldn't get it to run otherwise due to dependency conflicts.
- `.numpy()` sometimes returns a scalar ndarray directly now, so indexing is no longer required - we need to return the outer tensor for training now, not just the data, because it has the gradient information
|
@cbowdon This PR was helpful, thanks! I recommend that it be merged in. |
|
Thanks for your work on this, @cbowdon! Would be great if this could be merged in. |
| name: torchMoji | ||
| channels: | ||
| - pytorch | ||
| - defaults | ||
| dependencies: | ||
| - _libgcc_mutex=0.1=main | ||
| - blas=1.0=mkl | ||
| - ca-certificates=2019.11.27=0 | ||
| - certifi=2019.11.28=py36_0 | ||
| - cffi=1.13.2=py36h2e261b9_0 | ||
| - cudatoolkit=10.1.243=h6bb024c_0 | ||
| - intel-openmp=2019.4=243 | ||
| - libedit=3.1.20181209=hc058e9b_0 | ||
| - libffi=3.2.1=hd88cf55_4 | ||
| - libgcc-ng=9.1.0=hdf63c60_0 | ||
| - libgfortran-ng=7.3.0=hdf63c60_0 | ||
| - libstdcxx-ng=9.1.0=hdf63c60_0 | ||
| - mkl=2018.0.3=1 | ||
| - ncurses=6.1=he6710b0_1 | ||
| - ninja=1.9.0=py36hfd86e86_0 | ||
| - nose=1.3.7=py36_2 | ||
| - numpy=1.13.1=py36h5bc529a_2 | ||
| - openssl=1.1.1d=h7b6447c_3 | ||
| - pip=19.3.1=py36_0 | ||
| - pycparser=2.19=py36_0 | ||
| - python=3.6.9=h265db76_0 | ||
| - pytorch=1.3.1=py3.6_cuda10.1.243_cudnn7.6.3_0 | ||
| - readline=7.0=h7b6447c_5 | ||
| - scikit-learn=0.19.0=py36h97ac459_2 | ||
| - scipy=0.19.1=py36h9976243_3 | ||
| - setuptools=42.0.2=py36_0 | ||
| - sqlite=3.30.1=h7b6447c_0 | ||
| - text-unidecode=1.0=py36he5a4ee8_0 | ||
| - tk=8.6.8=hbc83047_0 | ||
| - wheel=0.33.6=py36_0 | ||
| - xz=5.2.4=h14c3975_4 | ||
| - zlib=1.2.11=h7b6447c_3 | ||
| - pip: | ||
| - emoji==0.4.5 | ||
| prefix: /home/cbowdon/miniconda3/envs/torchMoji | ||
|
|
There was a problem hiding this comment.
Can this be replaced with a from-history or atleast a no-builds variant of the export?
conda env export --no-builds is restrictive on the version, but not on the build ID, which differs from OS to OS.
There was a problem hiding this comment.
Thanks for the suggestion! Added a no-builds variant.
|
@thomwolf: Thanks for porting this from the source Keras implementation, and your continuing work with HuggingFace (big fan of |
|
Hi! Thank you for your work on Torchmoji! |
Thanks for open-sourcing this work!
I'm afraid I couldn't get the dependencies to resolve without conflicts when following the README instructions, so this PR upgrades the dependency.
Since the README suggested installing PyTorch with Conda originally, I've included an
environment.ymlthat will hopefully make this easier for future users.To verify the changes I've run:
nosetests -v -a '!slow'examples/text_emojize.pyexamples/finetune_youtube_last.pyThese all work as expected, although I can't guarantee this fixes every incompatibility.