code: def test_upcast(self) -> None:
      fresh = MapData(df=self.df, map_key_infos=self.map_key_infos)
      self.assertIsNone(
          fresh._memo_df
      )  # Assert df is not cached before first call
  
      self.assertEqual(
          fresh.df.columns.size,
          fresh.map_df.columns.size - len(self.mmd.map_key_infos),
      )
  
      self.assertIsNotNone(fresh._memo_df)
  
file_path: Ax/ax/core/tests/test_map_data.py
imports: import pandas
  from ax.core.data import Data
  from ax.core.map_data import MapData, MapKeyInfo
  from ax.utils.common.testutils import TestCase
label_desc: Use image node_id 7 for calling the MapDataTest obj's underlying member method code with example usage: obj.test_upcast() without return types