Code Monkey home page Code Monkey logo

Comments (5)

Ariel-JUAN avatar Ariel-JUAN commented on July 20, 2024 1

Hi, I solved this problem by compiling caffe under python3 environment.

from pytorchtocaffe.

Ariel-JUAN avatar Ariel-JUAN commented on July 20, 2024

您好 我使用的是python2.7 traceback没有walk_stack的属性。如果我只想使用python2.7,我应该如何修改代码呢?

from pytorchtocaffe.

ljeff97 avatar ljeff97 commented on July 20, 2024

Any ideas how to solve this problem please?

from pytorchtocaffe.

BaofengZan avatar BaofengZan commented on July 20, 2024

您好,请问你遇到的这个问题是如何解决的呢 ?@Ariel-JUAN

from pytorchtocaffe.

gailysun avatar gailysun commented on July 20, 2024

Hi, I solved this problem by compiling caffe under python3 environment.

Thanks for your solution. When I use python3, this problem is solved. But I meet a new problem: KeyError: 140477310121448 when I convert run /example/resnet_pytorch_2_caffe.py

  1. 140477310121520:view_blob1 was added to blobs
  2. Add blob view_blob1 : torch.Size([1, 512])
  3. Traceback (most recent call last):
  4. File "./example/resnet_pytorch_2_caffe.py", line 17, in
  5. pytorch_to_caffe.trans_net(resnet18,input,name)
    
  6. File "./pytorch_to_caffe.py", line 613, in trans_net
  7. out = net.forward(input_var)
    
  8. File "/home/scr/anaconda2/envs/pt2caffeenv/lib/python3.6/site-packages/torchvision/models/resnet.py", line 161, in forward
  9. x = x.view(x.size(0), -1)
    
  10. File "./pytorch_to_caffe.py", line 411, in _view
  11. bottom=[log.blobs(input)],top=top_blobs)
    
  12. File "./pytorch_to_caffe.py", line 89, in blobs
  13. print("{}:{} getting".format(var, self._blobs[var]))
    
  14. File "./pytorch_to_caffe.py", line 32, in getitem
  15. return self.data[key]
    
  16. KeyError: 140477310121448
    Did you meet the problem?

from pytorchtocaffe.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo 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.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.