Coder Social home page Coder Social logo

numbersrotationdl's Introduction

NumbersRotationDL

Implementation of ANN with number rotation

As a first step, the classification NN was implemented. I used CNN there.

try

anntest.m

As a second step, I build the regression network that detects an angle of digit rotation.

try

CNNregression.m

Then I implemented a script that freezed all the weights of the network.

FrozenANN.m

CustomLayer.m

This was a major problem for this project. I tried two different implementations. The fucntion:

failedRotation.m

doesn't even work. But I didn't delete it, hoping to fix.

The second function called

digitRotation.m

It performs bicubic interpolation. However, there is a need for clarification. Let's compare the behaviour of this function and MATLAB's imrotate()

imrotate by 180 degrees:

However, here is rotation using my function:

bicubic rotation by 180 degrees

We see that for some reason, the image was zoomed in by 10-15%. Nevertheless, the rotation happens.

customLayer.m

The customLayer was implemented in two ways. I tried to incorporate my function, but the problem with small numbers, so it needs to be optimized further. So, I eventually put imrotate() inside my custorLayer. Backprop is also implemented (in a trivial way).

Comments by the Reviewer

  • Good job, all goals accomplished
  • All networks performed as expected for the architecture chosen
  • Good knowledge of the layers and their proper placement in the model
  • I think you may have squeezed a bit more performance by allowing more epochs. Validation never terminated training, and I have a feeling that the net was not yet fully trained.
  • A very concise and readable implementation of rotation. It is much less complicated that the one ChatGPT wrote for us, and also that I found by Google search. As I recall, you used a book to study the algorithm. Would you please send me the reference?
  • NOTE: Used Emacs to indent your code, easier to read this way.

Score: 100%

numbersrotationdl's People

Contributors

ephemeraldream avatar mrychlik avatar

Stargazers

 avatar

Watchers

 avatar  avatar

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.