Comments (8)
Because the first two nodes are the inputs—we reduce the spatial resolution only for edges that are adjacent to the input nodes. I'm closing the issue but feel free to reopen it if you still get OOM.
from darts.
07/12 09:56:00 PM train 000 2.394935e+00 17.187500 45.312500
07/12 09:56:53 PM train 050 1.983369e+00 26.164217 81.127457
07/12 09:57:46 PM train 100 1.866709e+00 30.244431 84.096535
07/12 09:58:39 PM train 150 1.794865e+00 32.895283 85.709854
07/12 09:59:32 PM train 200 1.729609e+00 35.704288 86.986938
07/12 10:00:25 PM train 250 1.681173e+00 37.630730 87.879730
07/12 10:01:17 PM train 300 1.635046e+00 39.503738 88.631645
07/12 10:02:10 PM train 350 1.594318e+00 41.150284 89.400818
07/12 10:02:53 PM train_acc 42.503998
train_search.py:181: UserWarning: volatile was removed and now has no effect. Use with torch.no_grad():
instead.
input = Variable(input, volatile=True).cuda()
train_search.py:182: UserWarning: volatile was removed and now has no effect. Use with torch.no_grad():
instead.
target = Variable(target, volatile=True).cuda(async=True)
train_search.py:189: UserWarning: invalid index of a 0-dim tensor. This will be an error in PyTorch 0.5. Use tensor.item() to convert a 0-dim tensor to a Python number
objs.update(loss.data[0], n)
train_search.py:190: UserWarning: invalid index of a 0-dim tensor. This will be an error in PyTorch 0.5. Use tensor.item() to convert a 0-dim tensor to a Python number
top1.update(prec1.data[0], n)
train_search.py:191: UserWarning: invalid index of a 0-dim tensor. This will be an error in PyTorch 0.5. Use tensor.item() to convert a 0-dim tensor to a Python number
top5.update(prec5.data[0], n)
07/12 10:02:54 PM valid 000 1.367113e+00 48.437500 95.312500
THCudaCheck FAIL file=/opt/conda/conda-bld/pytorch_1524586445097/work/aten/src/THC/generic/THCStorage.cu line=58 error=2 : out of memory
Traceback (most recent call last):
File "train_search.py", line 200, in
main()
File "train_search.py", line 128, in main
valid_acc, valid_obj = infer(valid_queue, model, criterion)
File "train_search.py", line 184, in infer
logits = model(input)
File "/opt/conda/lib/python3.6/site-packages/torch/nn/modules/module.py", line 491, in call
result = self.forward(*input, **kwargs)
File "/home/pyromancer/workspace/shared/darts/cnn/model_search.py", line 104, in forward
s0, s1 = s1, cell(s0, s1, weights)
File "/opt/conda/lib/python3.6/site-packages/torch/nn/modules/module.py", line 491, in call
result = self.forward(*input, **kwargs)
File "/home/pyromancer/workspace/shared/darts/cnn/model_search.py", line 54, in forward
s = sum(self._ops[offset+j](h, weights[offset+j]) for j, h in enumerate(states))
File "/home/pyromancer/workspace/shared/darts/cnn/model_search.py", line 54, in
s = sum(self._ops[offset+j](h, weights[offset+j]) for j, h in enumerate(states))
File "/opt/conda/lib/python3.6/site-packages/torch/nn/modules/module.py", line 491, in call
result = self.forward(*input, **kwargs)
File "/home/pyromancer/workspace/shared/darts/cnn/model_search.py", line 22, in forward
return sum(w * op(x) for w, op in zip(weights, self._ops))
File "/home/pyromancer/workspace/shared/darts/cnn/model_search.py", line 22, in
return sum(w * op(x) for w, op in zip(weights, self._ops))
RuntimeError: cuda runtime error (2) : out of memory at /opt/conda/conda-bld/pytorch_1524586445097/work/aten/src/THC/generic/THCStorage.cu:58
no, even on TITAN V CNN example crashes
from darts.
Are you using pytorch 0.4? If so, please refer to #14.
from darts.
@AlexMikhalev
I have met the same problem, when i use TITAN v with cuda 9.1 pytorch = 0.4.0 torchvision = 0.2.1, it throws out the error that gc object that already tracked.then i look up to the source code. i found that gc in python is base on queue, which will lead to circular references.
to fix this problem, you can degrade your torchvision and pytorch version to 0.2.0 0.3.1
you can use this command,which is already work for me
pip install http://download.pytorch.org/whl/cu91/torch-0.3.1-cp36-cp36m-linux_x86_64.whl
pip install torchvision==0.2.0
i'm trying to solve this problem with pytorch 0.4.0. but it's really time-comsuming project.
you can use command ' watch -n 5 nvidia-smi ' to timely surpervise your cuda volidate-utils,and you will find the problem may caused by that.
and i think that the pytorch 0.4.0 have deprecated the volatile flag that cause this problem,you can also look it at pytorch.org release note.
from darts.
For pytorch 0.4, did any of you try wrapping the validation process into torch.no_grad()
, as in #14 ? I thought that alone should resolve the OOM issue.
from darts.
when i wrap it into torch.no_grad(),it seems work.but i don't completely do the experiment , because it really needs much time :( , but i am sure it works well with pytorch 0.3.1
from darts.
@quark0
for i in range(self._steps):#0 1 2 3
for j in range(2+i):# 0 1 , 0 1 2, 0 1 2 3, 0 1 2 3 4
stride = 2 if reduction and j < 2 else 1
op = MixedOp(C, stride)
self._ops.append(op)
how about that code means ? in your 42 to 46 lines in search_model.py why you plus 2 ? and set the stride with 2 only j < 2
from darts.
@quark0 do you plan to make darts pytorch 0.4 compatible?
from darts.
Related Issues (20)
- Approximate Architecture Gradient
- Imagenet mobile setting
- Can not reproduce the search result on PTB dataset (Fig3)? HOT 5
- The discrepancy between DARTS and ENAS for RNN cell searching
- Indentation bugs HOT 1
- Why are stem.0.weight different in pretrained and searched CIFAR-10 architectures?
- Questions about DARTS
- Can you tell me how to calculate Search Cost? HOT 1
- When running train,py, why can't I get the same high accuracy as in train_search.py
- Training time on colab HOT 2
- About alpha HOT 1
- RuntimeError: cannot pin 'torch.cuda.DoubleTensor' on GPU on version 0.10.0
- About utils.accuracy
- Broken pipe issue HOT 1
- try to visulize the genotype but got error HOT 1
- Not much comments in code. HOT 2
- Implementation compatible with the recent PyTorch and CUDA version
- Can only achieve 93% accuracy on CIFAR10
- Please upadate codes for latest version of PyTorch
- confuse about the train_search/train/test
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 darts.