code: def generate_uri(
      cls,
      repo: "Repo",
      run_name: str,
      sub_name: str,
      resource_path: str = None,
  ) -> str:
      encryptor = Fernet(key=repo.encryption_key)
      to_be_encrypted = f"{run_name}{URIService.SEPARATOR}{sub_name}"
      if resource_path:
          to_be_encrypted = (
              f"{to_be_encrypted}{URIService.SEPARATOR}{resource_path}"
          )
  
      return encryptor.encrypt(to_be_encrypted.encode()).decode()
  
file_path: aim/aim/sdk/uri_service.py
imports: from cryptography.fernet import Fernet
  from collections import defaultdict
  from typing import Iterator, List, Optional, Dict
  from typing import TYPE_CHECKING
  from aim.storage.encoding import encode_path, decode_path
  from aim.storage.types import BLOB
label_desc: Use image node_id 2 for calling the URIService obj's underlying member method code with example usage: obj.generate_uri(cls, repo, run_name, sub_name, resource_path) and returns: encryptor