Code Monkey home page Code Monkey logo

dynae's People

Contributors

nairouz 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

dynae's Issues

Critic weights are not modified during pre-training

Hi,

it appears to me there is an issue during training in the published version of the code leading to the critic/discriminator weights not being trained. In function aci_ae_constructor in file DynAE.py the weights of the critic are set as non-trainable, because the critic should not be trained when the auto encoder is trained: critic.trainable = False. However, this change also propagates to the critic and discriminator model, such that DynAE.train_on_batch_disc() does not update any weights.

This can be verified in two ways, either checking whether the critic weights are updated by inserting into DynAE.py line 333 following:

        last_critic_weights = None
        
        #Training loop
        for ite in range(int(maxiter)):
            #Validation interval
            if ite % validate_interval == 0:
                # Check weights modified
                critic_weights = self.disc.get_weights()
                if last_critic_weights is not None:
                    if all([np.all(critic_weights[i] == last_critic_weights[i]) for i in range(len(critic_weights))]):
                        print("Critic weights were not modified during training")
                last_critic_weights = [np.copy(c) for c in critic_weights]

or by directly checking whether the discriminator model has any trainable weights, i.e. modifying:

    def train_on_batch_disc(self, x1, x2, y1, y2):
        y = np.zeros((x1.shape[0],))
        if len(self.disc.trainable_weights) == 0:
            print("The discriminator is being trained with no trainable weights")
        return self.disc.train_on_batch([x1, x2, y1, y2], y)

It is suprising to me how well the model performs despite the discriminator not being trained, but it seems to me that your published work does things differently. Is this a mistake?

Kind regards

Embeddings

Can you guide me as to how you have plotted the embeddings, as visualizing 2D embedded subspaces using TSNE is showing errors? Are you using the npy files generated in the embeddings?

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.