NameError: global name 're' is not defined when I edit rules in classifier



I am seeking help for an error I have using CPA.

I use CPA 2.0 r11306 version and I use the classifier to define rules to identify 3 groups of C.elegans images:

After I trained the classifier and get the rules:

I try to use the same rule to classify a different set of images in a different database, and I just try open the other image set and classifier and copy the rules to the edit rules window:
however, once I click OK, there is a error message pop out:
Does anyone know the solution for this problem?




My guess (and I’m not really familiar with this version of CPA, so it is likely just a guess) is that the classification hasn’t been initialized properly somehow- in your new experiment if you re-create your classes, add 1 worm to each, train it, then edit the rules to replace them with your real ones, does that work?


problem remains. It seems that I can not edit anything in the edit rules window.