<jupyter_start><jupyter_text>Load The Data<jupyter_code>train, dev, test = dataloader.train_dev_test_sets()
print(f'Train set size: {len(train[0])}')
print(f'Dev set size: {len(dev[0])}')
print(f'Test set size: {len(test[0])}')
print()

print(f'Image shape: {dataloader.IMG_SHAPE}')
print(f'Number of classes: {len(dataloader.LABELS_MAP.values())}')
print(f'Classes: {list(dataloader.LABELS_MAP.values())}')
print()
trans_learn = TransferLearning('resnet50', num_bottom_layers_to_keep=0)
trans_learn.model.compile(
    optimizer=tf.train.RMSPropOptimizer(0.003),
    loss=tf.keras.losses.categorical_crossentropy,
    metrics=[tf.keras.metrics.categorical_accuracy]
)

trans_learn.model.fit(
    train[0][:10_000],
    train[1][:10_000],
    
    batch_size=32,
    epochs=50,
    
    callbacks=[
        tf.keras.callbacks.ReduceLROnPlateau(),
    ]
)<jupyter_output><empty_output>
{'fraction_non_alphanumeric': 0.16421291053227632, 'fraction_numerical': 0.02944507361268403, 'mean_word_length': 6.015873015873016, 'pattern_counts': {'":': 0, '<': 5, '<?xml version=': 0, '>': 5, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'chain_length': '1', 'dir': 'jupyter-structured-clean-dedup', 'id': '431083', 'license': 'CC0-1.0', 'n_tokens_mistral': 377, 'n_tokens_neox': 363, 'n_words': 44, 'path': 'deep-face/Transfer Learning.ipynb', 'repo_name': 'elsyser/Dr.f0to', 'size': '883'}