# Path: fedjax/datasets/shakespeare.py
# SPLITS = ('train', 'test')
# TABLE, VOCAB_SIZE = _build_look_up_table(
#     b'dhlptx@DHLPTX $(,048cgkoswCGKOSW[_#\'/37;?bfjnrvzBFJNRVZ"&*.26:\naeimquyAEIMQUY]!%)-159\r',
#     num_reserved=3)
# OOV = VOCAB_SIZE - 1
# PAD = 0
# BOS = 1
# EOS = 2
# def cite():
# def load_split(split: str,
#                mode: str = 'sqlite',
#                cache_dir: Optional[str] = None) -> federated_data.FederatedData:
# def load_data(
#     sequence_length: int = 80,
#     mode: str = 'sqlite',
#     cache_dir: Optional[str] = None
# ) -> Tuple[federated_data.FederatedData, federated_data.FederatedData]:
# def _build_look_up_table(vocab: bytes,
#                          num_reserved: int) -> Tuple[np.ndarray, int]:
# def preprocess_client(client_id: federated_data.ClientId,
#                       examples: client_datasets.Examples,
#                       sequence_length: int) -> client_datasets.Examples:


from absl.testing import absltest
from fedjax.datasets import shakespeare
import numpy as np
import numpy.testing as npt
# Copyright 2021 Google LLC
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
#      http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, software
# distributed under the License is distributed on an "AS IS" BASIS,
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# See the License for the specific language governing permissions and
# limitations under the License.
"""Tests for fedjax.datasets.shakespeare.

This file only tests preprocessing functions.
"""



class ShakespeareTest(absltest.TestCase):

  def test_preprocess_client(self):

# Path: fedjax/datasets/shakespeare.py
# SPLITS = ('train', 'test')
# TABLE, VOCAB_SIZE = _build_look_up_table(
#     b'dhlptx@DHLPTX $(,048cgkoswCGKOSW[_#\'/37;?bfjnrvzBFJNRVZ"&*.26:\naeimquyAEIMQUY]!%)-159\r',
#     num_reserved=3)
# OOV = VOCAB_SIZE - 1
# PAD = 0
# BOS = 1
# EOS = 2
# def cite():
# def load_split(split: str,
#                mode: str = 'sqlite',
#                cache_dir: Optional[str] = None) -> federated_data.FederatedData:
# def load_data(
#     sequence_length: int = 80,
#     mode: str = 'sqlite',
#     cache_dir: Optional[str] = None
# ) -> Tuple[federated_data.FederatedData, federated_data.FederatedData]:
# def _build_look_up_table(vocab: bytes,
#                          num_reserved: int) -> Tuple[np.ndarray, int]:
# def preprocess_client(client_id: federated_data.ClientId,
#                       examples: client_datasets.Examples,
#                       sequence_length: int) -> client_datasets.Examples:


# Path: fedjax/datasets/shakespeare_test.py
from absl.testing import absltest
from fedjax.datasets import shakespeare
import numpy as np
import numpy.testing as npt

# Copyright 2021 Google LLC
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
#      http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, software
# distributed under the License is distributed on an "AS IS" BASIS,
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# See the License for the specific language governing permissions and
# limitations under the License.
"""Tests for fedjax.datasets.shakespeare.

This file only tests preprocessing functions.
"""



class ShakespeareTest(absltest.TestCase):

  def test_preprocess_client(self):

    examples = shakespeare.preprocess_client(