Giter Club home page Giter Club logo

ternarynet's People

Contributors

czhu95 avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

ternarynet's Issues

Traceback was occured at cifar10 training.

Hi Chenzhuo!

I tried to train cifar10 by

python ./tw-cifar10-resnet.py --gpu 0

But, Traceback was occured.

Traceback (most recent call last):
  File "./tw-cifar10-resnet.py", line 213, in <module>
    config = get_config(args.n)
  File "./tw-cifar10-resnet.py", line 197, in get_config
    model=Model(n=nsize),
TypeError: Can't instantiate abstract class Model with abstract methods _get_inputs

My environment were below.
by conda install.

freetype                  2.5.5                         2
h5py                      2.7.0               np112py36_0
hdf5                      1.8.17                        1
jbig                      2.1                           0
jpeg                      8d                            2
libgfortran               3.0.0                         1
libpng                    1.6.27                        0
libprotobuf               3.2.0                         0
libsodium                 1.0.10                        0
libtiff                   4.0.6                         2
lmdb                      0.9.18                        0
mkl                       2017.0.1                      0
msgpack-numpy             0.3.9                     <pip>
msgpack-python            0.4.8                    py36_0
nltk                      3.2.2                    py36_0
numpy                     1.12.1                   py36_0
opencv                    3.1.0               np112py36_1
openssl                   1.0.2k                        2
pillow                    3.4.2                    py36_0
pip                       9.0.1                    py36_1
protobuf                  3.2.0                    py36_0
protobuf                  3.3.0                     <pip>
python                    3.6.1                         2
pyzmq                     16.0.2                   py36_0
readline                  6.2                           2
scipy                     0.19.0              np112py36_0
setuptools                27.2.0                   py36_0
six                       1.10.0                   py36_0
sqlite                    3.13.0                        0
tabulate                  0.7.7                     <pip>
tensorflow                1.1.0               np112py36_0
tensorpack                0.1.9                     <pip>
termcolor                 1.1.0                     <pip>
tk                        8.5.18                        0
tqdm                      4.11.2                   py36_0
werkzeug                  0.12.2                   py36_0
Werkzeug                  0.12.2                    <pip>
wheel                     0.29.0                   py36_0
xz                        5.2.2                         1
zeromq                    4.1.5                         0
zlib                      1.2.8                         3

by pip install

appdirs (1.4.3)
h5py (2.7.0)
msgpack-numpy (0.3.9)
msgpack-python (0.4.8)
nltk (3.2.2)
numpy (1.12.1)
packaging (16.8)
Pillow (3.4.2)
pip (9.0.1)
protobuf (3.3.0)
pyparsing (2.2.0)
pyzmq (16.0.2)
scipy (0.19.0)
setuptools (35.0.2)
six (1.10.0)
tabulate (0.7.7)
tensorflow (1.1.0)
tensorpack (0.1.9)
termcolor (1.1.0)
tqdm (4.11.2)
Werkzeug (0.12.2)
wheel (0.29.0)

关于阈值delta的问题?

您好,论文中做ternary之前,先对weight进行归一化,即除以最大的abs(w)归一化到[-1, 1]。
根据论文中设定threshold的方法
default
weight已经归一化,最大的max(abs(w))是1,因此delta就是t,也就是文中的0.05。
请问是这样吗?谢谢

Alexnet+Imagenet training

Hi Chenzhuo,
I was studying your Ternarynet work and was trying to run the Alexnet+Imagenet training.
'python ./tw-imagenet-alexnet.py --gpu 0,1,2,3 --data MY_IMAGENET_PATH' {I have arranged the data in the format expected by the ILSVRC12()}

I got the following AssertionError:
Command protoc caffe.proto --python_out . failed!

Where is it actually looking for caffe.proto? Is Caffe installation required for it to run?
Thanks and regards.

Reproduced ResNet18 CIFAR10 result is 10% lower than reported

Hi @czhu95 ,

Thanks for providing the codes!

Recently I use your codes to ternarize a ResNet18 using CIFAR10. Firstly I use tensorpack to train a ResNet18 to validation error as 0.083. However, when I apply this as initial status and ternarize (using the example codes), as I use the default delta t=0.05 in your code, the validation error is always around 0.1843. I tried other t but it is still around 0.18, which is about 10% lower than your paper report.

Is there any tricks or mistake I made?

Best regards,
Shangyu

resnet fine-tuned models

Hi @czhu95 ,

Thanks for your interesting work. I ran your code to reproduce your results of resnet on Cifar-10 from scratch. However I see the results are not similar as you reported because it might be not using finetune models of ResNet. How can I download finetuned models?

Thanks,
Hai

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.