To determine the amplitude of the given function, we analyze the general form of a cosine function, which is:
[tex]\[ y = A \cos(Bx - C) + D \][/tex]
Where:
- [tex]\( A \)[/tex] represents the amplitude of the function.
- [tex]\( B \)[/tex] affects the period of the function.
- [tex]\( C \)[/tex] represents the phase shift.
- [tex]\( D \)[/tex] represents the vertical shift.
The amplitude of the cosine function is the absolute value of the coefficient in front of the cosine term, [tex]\( A \)[/tex].
For the given function:
[tex]\[ y = 2 \cos \frac{\pi}{4} \left(x - \frac{1}{2}\right) \][/tex]
We can identify the coefficient [tex]\( A \)[/tex] as 2. Therefore, the amplitude is the absolute value of this coefficient.
Thus, the amplitude of the function is:
[tex]\[ \boxed{2} \][/tex]