ir-assemble was being used because the function definition overwrote the thunk that calls scipy