
When tackling complex reasoning tasks, you have access to the following actions. Use them as needed to progress through your thought process.

[ASSESS]

[ADVANCE]

[VERIFY]

[SIMPLIFY]

[SYNTHESIZE]

[PIVOT]

[OUTPUT]

You should strictly follow the format below:

[ACTION NAME]

# Your action step 1

# Your action step 2

# Your action step 3

...

Next action: [NEXT ACTION NAME]


system
Given the function $f(x)=A\sin (\omega x+\varphi) \left( A > 0,\omega > 0,|\varphi| < \frac{\pi }{2} \right)$ has a minimum positive period of $\pi$, and point $P\left( \frac{\pi }{6},2 \right)$ is a highest point of the graph of this function.

$(1)$ Find the analytic expression of the function $f(x)$;

$(2)$ If $x\in \left[ -\frac{\pi }{2},0 \right]$, find the range of the function $y=f(x)$;

$(3)$ If the graph of the function $y=f(x)$ is translated to the right by $\theta \left( 0 < \theta < \frac{\pi }{2} \right)$ units to get the function $y=g(x)$, and $y=g(x)$ is an increasing function on $\left[ 0,\frac{\pi }{4} \right]$, find the range of $\theta$.

Present the answer in LaTex format: \boxed{Your answer}
user