code: def _primitive_root_prime_power2_iter(p, e):
      r"""Generates the primitive roots of `2p^e`.
  
      Explanation
      ===========
  
      If ``g`` is the primitive root of ``p**e``,
      then the odd one of ``g`` and ``g+p**e`` is the primitive root of ``2*p**e``.
  
      Parameters
      ==========
  
      p : odd prime
      e : positive integer
  
      Yields
      ======
  
      int
          the primitive roots of `2p^e`
  
      Examples
      ========
  
      >>> from sympy.ntheory.residue_ntheory import _primitive_root_prime_power2_iter
      >>> sorted(_primitive_root_prime_power2_iter(5, 2))
      [3, 13, 17, 23, 27, 33, 37, 47]
  
      """
      for g in _primitive_root_prime_power_iter(p, e):
          if g % 2 == 1:
              yield g
          else:
              yield g + p**e
  
imports: from __future__ import annotations
  from sympy.external.gmpy import gcd, lcm, invert, sqrt, legendre, jacobi, kronecker, bit_scan1, remove
  from sympy.polys import Poly
  from sympy.polys.domains import ZZ
  from sympy.polys.galoistools import gf_crt1, gf_crt2, linear_congruence, gf_csolve
  from .primetest import isprime
  from .factor_ import factorint, _perfect_power
  from .modular import crt
  from sympy.utilities.decorator import deprecated
  from sympy.utilities.memoization import recurrence_memo
  from sympy.utilities.misc import as_int
  from sympy.utilities.iterables import iproduct
  from sympy.core.random import _randint, randint
  from itertools import product
label_desc: Use image node_id 4 for calling a global function with example usage: _primitive_root_prime_power2_iter(p, e) without return types