code: def parse(version: str) -> "Version":
      """Parse the given version string.
  
      >>> parse('1.0.dev1')
      <Version('1.0.dev1')>
  
      :param version: The version string to parse.
      :raises InvalidVersion: When the version string is not a valid version.
      """
      return Version(version)
  
imports: import collections
  import itertools
  import re
  from typing import Any, Callable, Optional, SupportsInt, Tuple, Union
  from ._structures import Infinity, InfinityType, NegativeInfinity, NegativeInfinityType
label_desc: Use image node_id 1 for calling a global function with example usage: parse(version) and returns: Version