Arraymancer icon indicating copy to clipboard operation
Arraymancer copied to clipboard

about cifar10-demo

Open cashiwamochi opened this issue 5 years ago • 3 comments

Hello, Thanks for your good DL framework. I implemented simple cifar-10 classification using Arraymancer. The demo is placed here ( https://github.com/cashiwamochi/nim_dl ) . How do you think about adding this to Arraymancer repository. Other DL frameworks have mnist and cifar examples. This suggestion is not weird. By the way, the accuracy of this is not good now. Maybe I need to find good models.

Thanks, R-Y ( cashiwamochi )

cashiwamochi avatar Oct 17 '18 13:10 cashiwamochi

Yes, I will add CIFAR as one of the default downloadable datasets like MNIST.

Regarding accuracy, either there is a bug :P or you need a deeper model like ResNets (or a pretrained NN is needed but for 10 classes I don't think so).

I'll investigate when I allow deep learning model composition which should just need to change this:

https://github.com/mratsim/Arraymancer/blob/0a08949030ceb0ca5499f73e4b6bca280bec774d/src/nn_dsl/dsl_types.nim#L63-L68

into

  TrainableLayer*[TT] = concept layer
    block:
      var trainable: false
      for field in fields(layer):
        trainable = trainable or (field is Variable[TT]) or field is TrainableLayer[TT]
      trainable

mratsim avatar Oct 19 '18 15:10 mratsim

Thanks for your reply. I'll try deeper networks and make something using Arraymancer.

cashiwamochi avatar Oct 21 '18 12:10 cashiwamochi

Hello. Thanks you for the new release. I tried cifar10 classification using v0.4.0, but the performance was worse than expected. ( This is what I reported in this issue. ) Yesterday I tried again using new version, and it worked correctly. The performance is better than the old version and good enough. You can see figures here. https://github.com/cashiwamochi/nim_dl This comment is just a report. Thank you.

cashiwamochi avatar Jan 01 '19 10:01 cashiwamochi