Beispiel #1
0
search_space.add_budget(param.Budget.TIME_IN_H, 24)
search_space.add_evaluation_metric(param.EvaluationMetric.MICRO_F1_SCORE)
search_space.add_optimization_value(param.OptimizationValue.DEV_SCORE)
search_space.add_max_epochs_per_training_run(25)

search_space.add_parameter(param.SequenceTagger.HIDDEN_SIZE,
                           options=[128, 256, 512])
search_space.add_parameter(param.SequenceTagger.DROPOUT,
                           options=[0, 0.1, 0.2, 0.3])
search_space.add_parameter(param.SequenceTagger.WORD_DROPOUT,
                           options=[0, 0.01, 0.05, 0.1])
search_space.add_parameter(param.SequenceTagger.RNN_LAYERS,
                           options=[2, 3, 4, 5, 6])
search_space.add_parameter(param.SequenceTagger.USE_RNN, options=[True, False])
search_space.add_parameter(param.SequenceTagger.USE_CRF, options=[True, False])
search_space.add_parameter(param.SequenceTagger.REPROJECT_EMBEDDINGS,
                           options=[True, False])
search_space.add_parameter(
    param.SequenceTagger.WORD_EMBEDDINGS,
    options=[WordEmbeddings('en'), ['en'], ['en', 'glove']])

search_strategy.make_configurations(search_space)

orchestrator = orchestrator.Orchestrator(
    corpus=corpus,
    base_path="resources/evaluation_wnut_random",
    search_space=search_space,
    search_strategy=search_strategy)

orchestrator.optimize()
Beispiel #2
0
search_space.add_parameter(param.DocumentRNNEmbeddings.HIDDEN_SIZE,
                           options=[128, 256, 512])
search_space.add_parameter(param.DocumentRNNEmbeddings.DROPOUT,
                           options=[0, 0.1, 0.2, 0.3, 0.4, 0.5])
search_space.add_parameter(param.DocumentRNNEmbeddings.REPROJECT_WORDS,
                           options=[True, False])
search_space.add_parameter(param.DocumentRNNEmbeddings.WORD_EMBEDDINGS,
                           options=[['glove'], ['en'], ['en', 'glove']])

#Define parameters for document embeddings Pool
search_space.add_parameter(param.DocumentPoolEmbeddings.WORD_EMBEDDINGS,
                           options=[['glove'], ['en'], ['en', 'glove']])
search_space.add_parameter(param.DocumentPoolEmbeddings.POOLING,
                           options=['mean', 'max', 'min'])

#Define parameters for Transformers
search_space.add_parameter(
    param.TransformerDocumentEmbeddings.MODEL,
    options=["bert-base-uncased", "distilbert-base-uncased"])
search_space.add_parameter(param.TransformerDocumentEmbeddings.BATCH_SIZE,
                           options=[16, 32, 64])

search_strategy.make_configurations(search_space)

orchestrator = orchestrator.Orchestrator(
    corpus=corpus,
    base_path='resources/evaluation-senteval-subj-random',
    search_space=search_space,
    search_strategy=search_strategy)

orchestrator.optimize()
search_space.add_parameter(param.DocumentRNNEmbeddings.HIDDEN_SIZE,
                           options=[128, 256, 512])
search_space.add_parameter(param.DocumentRNNEmbeddings.DROPOUT,
                           options=[0, 0.1, 0.2, 0.3, 0.4, 0.5])
search_space.add_parameter(param.DocumentRNNEmbeddings.REPROJECT_WORDS,
                           options=[True, False])
search_space.add_parameter(param.DocumentRNNEmbeddings.WORD_EMBEDDINGS,
                           options=[['glove'], ['en'], ['en', 'glove']])

#Define parameters for document embeddings Pool
search_space.add_parameter(param.DocumentPoolEmbeddings.WORD_EMBEDDINGS,
                           options=[['glove'], ['en'], ['en', 'glove']])
search_space.add_parameter(param.DocumentPoolEmbeddings.POOLING,
                           options=['mean', 'max', 'min'])

#Define parameters for Transformers
search_space.add_parameter(
    param.TransformerDocumentEmbeddings.MODEL,
    options=["bert-base-uncased", "distilbert-base-uncased"])
search_space.add_parameter(param.TransformerDocumentEmbeddings.BATCH_SIZE,
                           options=[16, 32, 64])

search_strategy.make_configurations(search_space)

orchestrator = orchestrator.Orchestrator(
    corpus=corpus,
    base_path='resources/evaluation-trec-grid',
    search_space=search_space,
    search_strategy=search_strategy)

orchestrator.optimize()
Beispiel #4
0
search_space.add_budget(param.Budget.TIME_IN_H, 24)
search_space.add_evaluation_metric(param.EvaluationMetric.MICRO_F1_SCORE)
search_space.add_optimization_value(param.OptimizationValue.DEV_SCORE)
search_space.add_max_epochs_per_training_run(50)

search_space.add_parameter(param.SequenceTagger.HIDDEN_SIZE,
                           options=[128, 256, 512])
search_space.add_parameter(param.SequenceTagger.DROPOUT,
                           options=[0, 0.1, 0.2, 0.3])
search_space.add_parameter(param.SequenceTagger.WORD_DROPOUT,
                           options=[0, 0.01, 0.05, 0.1])
search_space.add_parameter(param.SequenceTagger.RNN_LAYERS,
                           options=[2, 3, 4, 5, 6])
search_space.add_parameter(param.SequenceTagger.USE_RNN, options=[True, False])
search_space.add_parameter(param.SequenceTagger.USE_CRF, options=[True, False])
search_space.add_parameter(param.SequenceTagger.REPROJECT_EMBEDDINGS,
                           options=[True, False])
search_space.add_parameter(param.SequenceTagger.WORD_EMBEDDINGS,
                           options=[['glove'], ['en'], ['en', 'glove']])

search_strategy.make_configurations(search_space)

orchestrator = orchestrator.Orchestrator(
    corpus=corpus,
    base_path="resources/evaluation_ud-eng_genetic-v2",
    search_space=search_space,
    search_strategy=search_strategy)

orchestrator.optimize()
search_space.add_parameter(param.DocumentRNNEmbeddings.HIDDEN_SIZE,
                           options=[128, 256, 512])
search_space.add_parameter(param.DocumentRNNEmbeddings.DROPOUT,
                           options=[0, 0.1, 0.2, 0.3, 0.4, 0.5])
search_space.add_parameter(param.DocumentRNNEmbeddings.REPROJECT_WORDS,
                           options=[True, False])
search_space.add_parameter(param.DocumentRNNEmbeddings.WORD_EMBEDDINGS,
                           options=[['glove'], ['en'], ['en', 'glove']])

#Define parameters for document embeddings Pool
search_space.add_parameter(param.DocumentPoolEmbeddings.WORD_EMBEDDINGS,
                           options=[['glove'], ['en'], ['en', 'glove']])
search_space.add_parameter(param.DocumentPoolEmbeddings.POOLING,
                           options=['mean', 'max', 'min'])

#Define parameters for Transformers
search_space.add_parameter(
    param.TransformerDocumentEmbeddings.MODEL,
    options=["bert-base-uncased", "distilbert-base-uncased"])
search_space.add_parameter(param.TransformerDocumentEmbeddings.BATCH_SIZE,
                           options=[16, 32, 64])

search_strategy.make_configurations(search_space)

orchestrator = orchestrator.Orchestrator(
    corpus=corpus,
    base_path='resources/evaluation-senteval-cr-genetic',
    search_space=search_space,
    search_strategy=search_strategy)

orchestrator.optimize()