Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix bugs on training Parametric Models #26

Closed
BirkhoffG opened this issue Nov 15, 2023 · 0 comments · Fixed by #32
Closed

Fix bugs on training Parametric Models #26

BirkhoffG opened this issue Nov 15, 2023 · 0 comments · Fixed by #32
Assignees
Labels
bug Something isn't working

Comments

@BirkhoffG
Copy link
Owner

At this point, relax.generate_cf_explanations will train the ParametricCFModule no matter what. However, if this ParametricCFModule has already been trained, we should not repeat this process.

For example,

cfnet = CounterNet()
# we train cfnet here
cfnet.train(data_module)

# but relax will train `cfnet` again here
exp = relax.generate_cf_explanations(cfnet, data_module)

Delivery

Fix bug here:

if isinstance(cf_module, ParametricCFModule):

  1. Check ParametricCFModule.is_trained is True or not under this if statement.
  2. Write test cases

You might also need to fix bugs in some of the methods inherent ParametricCFModule.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
2 participants