



def 					lowerCAmelCase__  (							_SCREAMING_SNAKE_CASE    :     str			,       _SCREAMING_SNAKE_CASE    :     Optional[int]      ):
				"""simple docstring"""







				print("""\nVertex Distance"""      )
				for i in range(__UpperCamelCase      ):
								if dist[i] != float("""inf"""      ):
												print(__UpperCamelCase			,       """\t"""			,       int(dist[i]      )			,       end="""\t"""      )
								else:
												print(__UpperCamelCase			,       """\t"""			,       """INF"""			,       end="""\t"""      )
								print()

def 					lowerCAmelCase__  (							_SCREAMING_SNAKE_CASE    :     Union[str, Any]			,       _SCREAMING_SNAKE_CASE    :     Tuple			,       _SCREAMING_SNAKE_CASE    :     Optional[int]      ):
				"""simple docstring"""







				__a					       =						float("""inf"""      )
				__a					       =						-1
				for i in range(__UpperCamelCase      ):
								if (not vset[i]) and mdist[i] < min_val:
												__a					       =						i
												__a					       =						mdist[i]
				return min_ind

def 					lowerCAmelCase__  (							_SCREAMING_SNAKE_CASE    :     str			,       _SCREAMING_SNAKE_CASE    :     Any			,       _SCREAMING_SNAKE_CASE    :     str      ):
				"""simple docstring"""







				__a					       =						[float("""inf"""      ) for _ in range(__UpperCamelCase      )]
				__a					       =						[False for _ in range(__UpperCamelCase      )]
				__a					       =						0.0

				for _ in range(v - 1      ):
								__a					       =						min_dist(__UpperCamelCase			,       __UpperCamelCase			,       __UpperCamelCase      )
								__a					       =						True

								for i in range(__UpperCamelCase      ):
												if (
												    (not vset[i])
												    and graph[u][i] != float("""inf"""      )
												    and mdist[u] + graph[u][i] < mdist[i]
												):
																__a					       =						mdist[u] + graph[u][i]

				print_dist(__UpperCamelCase			,       __UpperCamelCase      )


if __name__ == "__main__":
						lowerCamelCase__     =	int(input("""Enter number of vertices: """).strip())
						lowerCamelCase__     =	int(input("""Enter number of edges: """).strip())

						lowerCamelCase__     =	[[float("""inf""") for i in range(V)] for j in range(V)]

						for i in range(V):
												lowerCamelCase__     =	0.0

						for i in range(E):
												print("""\nEdge """, i + 1)
												lowerCamelCase__     =	int(input("""Enter source:""").strip())
												lowerCamelCase__     =	int(input("""Enter destination:""").strip())
												lowerCamelCase__     =	float(input("""Enter weight:""").strip())
												lowerCamelCase__     =	weight

						lowerCamelCase__     =	int(input("""\nEnter shortest path source:""").strip())
						dijkstra(graph, V, gsrc)





from typing import TYPE_CHECKING

from ...utils import OptionalDependencyNotAvailable, _LazyModule, is_torch_available, is_vision_available


lowerCamelCase__     =	{
    """configuration_oneformer""": ["""ONEFORMER_PRETRAINED_CONFIG_ARCHIVE_MAP""", """OneFormerConfig"""],
    """processing_oneformer""": ["""OneFormerProcessor"""],
}

try:
						if not is_vision_available():
												raise OptionalDependencyNotAvailable()
except OptionalDependencyNotAvailable:
						pass
else:
						lowerCamelCase__     =	["""OneFormerImageProcessor"""]

try:
						if not is_torch_available():
												raise OptionalDependencyNotAvailable()
except OptionalDependencyNotAvailable:
						pass
else:
						lowerCamelCase__     =	[
						    """ONEFORMER_PRETRAINED_MODEL_ARCHIVE_LIST""",
						    """OneFormerForUniversalSegmentation""",
						    """OneFormerModel""",
						    """OneFormerPreTrainedModel""",
						]

if TYPE_CHECKING:
						from .configuration_oneformer import ONEFORMER_PRETRAINED_CONFIG_ARCHIVE_MAP, OneFormerConfig
						from .processing_oneformer import OneFormerProcessor

						try:
												if not is_vision_available():
																		raise OptionalDependencyNotAvailable()
						except OptionalDependencyNotAvailable:
												pass
						else:
												from .image_processing_oneformer import OneFormerImageProcessor
						try:
												if not is_torch_available():
																		raise OptionalDependencyNotAvailable()
						except OptionalDependencyNotAvailable:
												pass
						else:
												from .modeling_oneformer import (
												    ONEFORMER_PRETRAINED_MODEL_ARCHIVE_LIST,
												    OneFormerForUniversalSegmentation,
												    OneFormerModel,
												    OneFormerPreTrainedModel,
												)


else:
						import sys

						lowerCamelCase__     =	_LazyModule(__name__, globals()["""__file__"""], _import_structure)
