ImportError: cannot import name 'CTGANSynthesizer' from 'ctgan' (/usr/local/lib/python3.10/dist-packages/ctgan/__init__.py)

755 views Asked by At

I am working on synthetic data generation from GAN but facing some issues with the CTGANSynthesizer. Here is the code sample:

from ctgan import CTGANSynthesizer
ctgan = CTGANSynthesizer() 
ctgan.fit(data) 

I am getting an error as shown in the screenshot: Error of given script. I am trying to generate some Bengali text data from a Bengali text dataset using this GAN.

1

There are 1 answers

0
Daraan On

See the update-log, the model is now named differently:

## v0.6.0 - 2022-10-07

This release renames the models in CTGAN.
 `CTGANSynthesizer` is now called `CTGAN`
and `TVAESynthesizer` is now called `TVAE`.