I defined a new function SetPopulation using the function editor. I have used it in the field calculator, and it works as desired.
I have a model (deliberately very simple for testing purposes) in which I wish to use this new SetPopulation function in the Advanced Python field calculator to calculate the values of a new attribute created by the Advanced Python field calculator.
Why does the the Advanced Python field calculator algorithm in the model not recognize SetPopulation as a legitimate expression?