Git Product home page Git Product logo

nasnet-keras's Issues

The Concate layers of ReductionCell is wrong?

Hi, in paper (Figure4, ReductionCell) there are only 3 layer for Concate input , as you code (line 300 in nasnet.py) ,it should be
return Concatenate(.....)([add_2, add_3 add_4])
add_1 is not in Concate input!!!! please check it.

Training NASNet with pretrianed weights but different input_shape

I tried to finetune NASNet like a Keras K.application model however, there is no weights kwarg. For example, for Xception it defaults to loading the imagenet pretrained weights.

I tried to use some of the functions provided in the package as follows,

import nasnet

origin = 'https://storage.googleapis.com/download.tensorflow.org/models/nasnet-a_large_04_10_2017.tar.gz'
fname='nasnet_large'
md5_hash='5286bdbb29bab27c4d3431c70f8becf9'
cache_dir = os.path.expanduser(os.path.join('~', '.keras', 'models'))

model = nasnet.NASNetA(include_top=False, input_shape=(img_height, img_width, 3))

nasnet.load_pretrained_weights(model, fname, origin, md5_hash,
                               skip_first_dense=True, cache_dir=cache_dir)

However, this throws the error,

ValueError: Layer weight shape (1, 1, 96, 8) not compatible with provided weight shape (1, 1, 96, 42)

What is going wrong here? Better still, it would be great to get a weights kwarg built in to make it fully follow the Keras API. Many thanks.

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.