code: def test_reshard():
      """Test that resharding the dataset works."""
      solubility_dataset = load_solubility_data()
      X, y, w, ids = (
          solubility_dataset.X,
          solubility_dataset.y,
          solubility_dataset.w,
          solubility_dataset.ids,
      )
      assert solubility_dataset.get_number_shards() == 1
      solubility_dataset.reshard(shard_size=1)
      assert solubility_dataset.get_shard_size() == 1
      X_r, y_r, w_r, ids_r = (
          solubility_dataset.X,
          solubility_dataset.y,
          solubility_dataset.w,
          solubility_dataset.ids,
      )
      assert solubility_dataset.get_number_shards() == 10
      solubility_dataset.reshard(shard_size=10)
      assert solubility_dataset.get_shard_size() == 10
      X_rr, y_rr, w_rr, ids_rr = (
          solubility_dataset.X,
          solubility_dataset.y,
          solubility_dataset.w,
          solubility_dataset.ids,
      )
  
      # Test first resharding worked
      np.testing.assert_array_equal(X, X_r)
      np.testing.assert_array_equal(y, y_r)
      np.testing.assert_array_equal(w, w_r)
      np.testing.assert_array_equal(ids, ids_r)
  
      # Test second resharding worked
      np.testing.assert_array_equal(X, X_rr)
      np.testing.assert_array_equal(y, y_rr)
      np.testing.assert_array_equal(w, w_rr)
      np.testing.assert_array_equal(ids, ids_rr)
  
imports: import random
  import math
  import unittest
  import os
  import numpy
  import pytest
  import deepchem
  import pandas
  import tempfile
label_desc: Use image node_id 10 for calling a global function with example usage: test_reshard() without return types