Comments (1)
Recently I have managed to make it work on GPU. Though it was not easy...
Basically, you shall install DyNet with GPU support. Then run your script with --dynet-gpu option which tells DyNet to run calculations on GPU (as described in https://dynet.readthedocs.io/en/latest/python.html#installing-a-cutting-edge-and-or-gpu-version).
Now, step-by-step instructions:
-
Install DyNet with GPU support. This was the most difficult part. To achieve this, I had to install old CUDA 10.0, old gcc 7.3 and run:
CUDNN_ROOT=/path/to/cudnn BACKEND=cuda pip install git+https://github.com/clab/dynet#egg=dynet -
Add --dynet-gpu flag to the command line arguments of OptionParser, otherwise OptionParser will report unsupported argument and exit.
For instance, I've added to sesame/targetid.py the following line:
optpr.add_option("--config", type="str", metavar="FILE")
+optpr.add_option("--dynet-gpu") -
Finally, I had an error telling me that log_softmax operation does not have GPU implementation in DyNet. So had to move it to the CPU:
-
score_i = dy.to_device(score_i, 'CPU') logloss = log_softmax(score_i, [0, 1])
After these steps training started utilizing GPU. But... seems it became even slower than on CPU. Probably, need some code optimization to improve performance on GPU :((
from open-sesame.
Related Issues (20)
- output description HOT 1
- Dimensionality Mismatch While Trying to Run Prediction HOT 7
- I just made the necessary modifications to work with Python 3 and produce the output in Json format. HOT 1
- get postags and lemmas of sentences all zero when running prediction
- FrameID Results include Gold Arguments
- Error While Training: no attribute '__reduce_cython__'
- Got an Error while Running a Basic Prediction Task HOT 1
- install error
- Question on the reported results. HOT 1
- 'WindowsPath' object has no attribute 'read'
- KeyError while training FrameID and ArgID
- The link to GloVe embeddings is not valid
- RuntimeError: Dimensions of lookup parameter /_0 lookup up from file ({100,400574}) do not match parameters to be populated ({100,410050}) HOT 23
- Glove word embedding links returns 404 HOT 2
- TypeError: Argument 'init' has incorrect type (expected _dynet.PyInitializer, got str) HOT 1
- Any suggestions/pipeline process for large text files?
- Process aborts abruptly with "Killed" message
- Using open-sesame framework for a new language? HOT 1
- Is open-sesame still supported? HOT 1
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from open-sesame.