from __future__ import annotations

from typing import Any, Optional

from ..fluid import layers as layers
from ..fluid.data_feeder import check_dtype as check_dtype
from ..fluid.data_feeder import check_type as check_type
from ..fluid.data_feeder import check_variable_and_dtype as check_variable_and_dtype
from ..fluid.framework import in_dygraph_mode as in_dygraph_mode
from ..fluid.layer_helper import LayerHelper as LayerHelper
from ..framework import core as core
from .logic import logical_not as logical_not

def argsort(x: Any, axis: int = ..., descending: bool = ..., name: Optional[Any] = ...): ...
def argmax(x: Any, axis: Optional[Any] = ..., keepdim: bool = ..., dtype: str = ..., name: Optional[Any] = ...): ...
def argmin(x: Any, axis: Optional[Any] = ..., keepdim: bool = ..., dtype: str = ..., name: Optional[Any] = ...): ...
def index_select(x: Any, index: Any, axis: int = ..., name: Optional[Any] = ...): ...
def nonzero(x: Any, as_tuple: bool = ...): ...
def sort(x: Any, axis: int = ..., descending: bool = ..., name: Optional[Any] = ...): ...
def mode(x: Any, axis: int = ..., keepdim: bool = ..., name: Optional[Any] = ...): ...
def where(condition: Any, x: Optional[Any] = ..., y: Optional[Any] = ..., name: Optional[Any] = ...): ...
def index_sample(x: Any, index: Any): ...
def masked_select(x: Any, mask: Any, name: Optional[Any] = ...): ...
def topk(
    x: Any, k: Any, axis: Optional[Any] = ..., largest: bool = ..., sorted: bool = ..., name: Optional[Any] = ...
): ...
def searchsorted(
    sorted_sequence: Any, values: Any, out_int32: bool = ..., right: bool = ..., name: Optional[Any] = ...
): ...
def kthvalue(x: Any, k: Any, axis: Optional[Any] = ..., keepdim: bool = ..., name: Optional[Any] = ...): ...
