Coder Social home page Coder Social logo

Comments (4)

csala avatar csala commented on May 18, 2024 1

and how can I save the learned model?

You can do so using PyTorch save and load

For this, after fitting your model, you save it using:

import torch

torch.save(synthesizer, '/path/to/your/model.pkl')

And later on load it doing:

import torch

synthesizer = torch.load('/path/to/your/model.pkl')

from sdgym.

sungreong avatar sungreong commented on May 18, 2024 1

Thank you very much for your quick answer.
If you have time later, I think it will be helpful if you make a brief example of other frameworks such as Tensorflow and Keras.

Oh, I have one question about TGAN paper.
In the paper, there is a way to deal with category missing value variables, and I think it's right to do so.

But if there's no explanation in the paper about a numerical variable that can't be substituted for missing values, is there any way you can recommend it?

from sdgym.

csala avatar csala commented on May 18, 2024

Hello @sungreong

I'm not entirely sure about understanding you properly, but if you mean whether it is possible to use the benchmarking tool for tensorflow based synthesizers, yes, it is possible.

All you need to do is prepare your synthesizer function following the specification and pass it to the benchmark function:

from sdgym import benchmark
from your_package import your_tensorflow_synthesizer

def your_synthesizer_function(real_data, categorical_columns, ordinal_columns):
    # put the code here to use your_tensorflow_synthesizer to model and sample data
    return sampled_data

benchmark(your_synthesizer_function)

Please, let me know if this is what you were looking for.

from sdgym.

csala avatar csala commented on May 18, 2024

This question has already been answered here, so I'm closing this issue for now.

from sdgym.

Related Issues (20)

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.