class_docstr: Tile sizes parameterizing FlashAttention kernels.
  
  Those parameters have negligible effect on numerics, but affect performance
  greatly.
class_docstr_tok: ["Tile","sizes","parameterizing","FlashAttention","kernels",".","Those","parameters","have","negligible","effect","on","numerics",",","but","affect","performance","greatly","."]
code: def __post_init__(self):
      def verify_major_minor(prefix, suffix, major, minor):
          if minor > major:
              raise ValueError(
                  f"{prefix}{suffix}={minor} should be smaller than"
                  f" {prefix}_major{suffix}={major}"
              )
          if major % minor != 0:
              raise ValueError(
                  f"{prefix}{suffix}={minor} should divide"
                  f" {prefix}_major{suffix}={major}"
              )
  
      verify_major_minor(
          "block_k", "", self.block_k_major, self.block_k
      )
      if (
          self.block_q_major_dkv is not None
          and self.block_q_dkv is not None
      ):
          verify_major_minor(
              "block_q",
              "_dkv",
              self.block_q_major_dkv,
              self.block_q_dkv,
          )
      if (
          self.block_k_major_dkv is not None
          and self.block_k_dkv is not None
      ):
          verify_major_minor(
              "block_k",
              "_dkv",
              self.block_k_major_dkv,
              self.block_k_dkv,
          )
      if (
          self.block_k_major_dq is not None
          and self.block_k_dq is not None
      ):
          verify_major_minor(
              "block_k", "_dq", self.block_k_major_dq, self.block_k_dq
          )
  
imports: from __future__ import annotations
  import dataclasses
  import functools
  from typing import Any, NamedTuple
  import jax
  from jax import lax
  from jax.experimental import pallas
  from jax.experimental.pallas import tpu
  import jax.numpy
label_desc: Use image node_id 1 for calling the BlockSizes obj's underlying member method code with example usage: obj.__post_init__() without return types