paper version of Algorithm

This commit is contained in:
Jonas Weinz 2020-02-16 13:20:04 +01:00
parent 6115df7945
commit 3f075ff941
14 changed files with 36128 additions and 41184 deletions

6
.gitignore vendored
View File

@ -5,3 +5,9 @@ __pycache__
*.gz *.gz
.vscode .vscode
*.pickle *.pickle
*.dot
*.pdf
*.svg
*.png
*.dill
*.pickle

View File

@ -505,7 +505,8 @@
"name": "stdout", "name": "stdout",
"output_type": "stream", "output_type": "stream",
"text": [ "text": [
"Are the instructions understandable? (0: totally confusing, 3: very clear)\n" "Are the instructions understandable? (0: totally confusing, 3: very clear)\n",
"(['noodle', 'rice'], [[1, 0], [2, 2], [8, 10], [23, 22]])\n"
] ]
}, },
{ {
@ -524,7 +525,8 @@
"name": "stdout", "name": "stdout",
"output_type": "stream", "output_type": "stream",
"text": [ "text": [
"How tasty is it probably? (0: not at all, 3: very tasty)\n" "How tasty is it probably? (0: not at all, 3: very tasty)\n",
"(['noodle', 'rice'], [[1, 1], [10, 9], [15, 15], [8, 9]])\n"
] ]
}, },
{ {
@ -543,7 +545,8 @@
"name": "stdout", "name": "stdout",
"output_type": "stream", "output_type": "stream",
"text": [ "text": [
"Would you cook it? (0: not at all, 3: immediately!)\n" "Would you cook it? (0: not at all, 3: immediately!)\n",
"(['noodle', 'rice'], [[7, 5], [12, 9], [7, 13], [8, 7]])\n"
] ]
}, },
{ {
@ -562,7 +565,8 @@
"name": "stdout", "name": "stdout",
"output_type": "stream", "output_type": "stream",
"text": [ "text": [
"How creative is this recipe? (0: not at all, 3: very creative!)\n" "How creative is this recipe? (0: not at all, 3: very creative!)\n",
"(['noodle', 'rice'], [[1, 0], [10, 10], [15, 19], [8, 5]])\n"
] ]
}, },
{ {
@ -581,7 +585,8 @@
"name": "stdout", "name": "stdout",
"output_type": "stream", "output_type": "stream",
"text": [ "text": [
"Is this a good combination of ingredients? (0: not at all, 3: very good!)\n" "Is this a good combination of ingredients? (0: not at all, 3: very good!)\n",
"(['noodle', 'rice'], [[2, 1], [6, 7], [13, 11], [13, 15]])\n"
] ]
}, },
{ {
@ -600,7 +605,8 @@
"name": "stdout", "name": "stdout",
"output_type": "stream", "output_type": "stream",
"text": [ "text": [
"Are the used cooking actions suitable for the ingredients? (0: not at all, 3: totally!)\n" "Are the used cooking actions suitable for the ingredients? (0: not at all, 3: totally!)\n",
"(['noodle', 'rice'], [[2, 5], [12, 6], [13, 15], [7, 8]])\n"
] ]
}, },
{ {
@ -620,6 +626,7 @@
"for q in range_questions:\n", "for q in range_questions:\n",
" print(q)\n", " print(q)\n",
" answer = get_range_group_answer(q)\n", " answer = get_range_group_answer(q)\n",
" print (answer)\n",
" \n", " \n",
" x = np.arange(len(answer[0])) \n", " x = np.arange(len(answer[0])) \n",
"\n", "\n",
@ -699,7 +706,7 @@
}, },
{ {
"cell_type": "code", "cell_type": "code",
"execution_count": 23, "execution_count": 22,
"metadata": {}, "metadata": {},
"outputs": [ "outputs": [
{ {
@ -727,7 +734,7 @@
" 'rice_9.md']" " 'rice_9.md']"
] ]
}, },
"execution_count": 23, "execution_count": 22,
"metadata": {}, "metadata": {},
"output_type": "execute_result" "output_type": "execute_result"
} }

File diff suppressed because one or more lines are too long

File diff suppressed because it is too large Load Diff

718
Evaluation/all_results.json Normal file
View File

@ -0,0 +1,718 @@
[
{
"noodle_8.md": {
"Is this a valid recipe?": "Yes",
"Does it seem eatable?": "Yes",
"Are the instructions understandable? (0: totally confusing, 3: very clear)": "3",
"How tasty is it probably? (0: not at all, 3: very tasty)": "1",
"Would you cook it? (0: not at all, 3: immediately!)": "1",
"How creative is this recipe? (0: not at all, 3: very creative!)": "2",
"Is this a good combination of ingredients? (0: not at all, 3: very good!)": "3",
"Are the used cooking actions suitable for the ingredients? (0: not at all, 3: totally!)": "1"
},
"noodle_3.md": {
"Is this a valid recipe?": "Yes",
"Does it seem eatable?": "Yes",
"Are the instructions understandable? (0: totally confusing, 3: very clear)": "1",
"How tasty is it probably? (0: not at all, 3: very tasty)": "1",
"Would you cook it? (0: not at all, 3: immediately!)": "0",
"How creative is this recipe? (0: not at all, 3: very creative!)": "2",
"Is this a good combination of ingredients? (0: not at all, 3: very good!)": "1",
"Are the used cooking actions suitable for the ingredients? (0: not at all, 3: totally!)": "1"
},
"rice_8.md": {
"Is this a valid recipe?": "Yes",
"Does it seem eatable?": "Yes",
"Are the instructions understandable? (0: totally confusing, 3: very clear)": "3",
"How tasty is it probably? (0: not at all, 3: very tasty)": "3",
"Would you cook it? (0: not at all, 3: immediately!)": "2",
"How creative is this recipe? (0: not at all, 3: very creative!)": "2",
"Is this a good combination of ingredients? (0: not at all, 3: very good!)": "3",
"Are the used cooking actions suitable for the ingredients? (0: not at all, 3: totally!)": "3"
},
"rice_2.md": {
"Is this a valid recipe?": "Yes",
"Does it seem eatable?": "Yes",
"Are the instructions understandable? (0: totally confusing, 3: very clear)": "3",
"How tasty is it probably? (0: not at all, 3: very tasty)": "1",
"Would you cook it? (0: not at all, 3: immediately!)": "1",
"How creative is this recipe? (0: not at all, 3: very creative!)": "2",
"Is this a good combination of ingredients? (0: not at all, 3: very good!)": "1",
"Are the used cooking actions suitable for the ingredients? (0: not at all, 3: totally!)": "2"
}
},
{
"rice_0.md": {
"Is this a valid recipe?": "Yes",
"Does it seem eatable?": "Yes",
"Are the instructions understandable? (0: totally confusing, 3: very clear)": "3",
"How tasty is it probably? (0: not at all, 3: very tasty)": "2",
"Would you cook it? (0: not at all, 3: immediately!)": "2",
"How creative is this recipe? (0: not at all, 3: very creative!)": "3",
"Is this a good combination of ingredients? (0: not at all, 3: very good!)": "1",
"Are the used cooking actions suitable for the ingredients? (0: not at all, 3: totally!)": "2"
},
"noodle_5.md": {
"Is this a valid recipe?": "Yes",
"Does it seem eatable?": "Yes",
"Are the instructions understandable? (0: totally confusing, 3: very clear)": "3",
"How tasty is it probably? (0: not at all, 3: very tasty)": "2",
"Would you cook it? (0: not at all, 3: immediately!)": "1",
"How creative is this recipe? (0: not at all, 3: very creative!)": "2",
"Is this a good combination of ingredients? (0: not at all, 3: very good!)": "3",
"Are the used cooking actions suitable for the ingredients? (0: not at all, 3: totally!)": "1"
},
"rice_9.md": {
"Is this a valid recipe?": "Yes",
"Does it seem eatable?": "Yes",
"Are the instructions understandable? (0: totally confusing, 3: very clear)": "3",
"How tasty is it probably? (0: not at all, 3: very tasty)": "2",
"Would you cook it? (0: not at all, 3: immediately!)": "2",
"How creative is this recipe? (0: not at all, 3: very creative!)": "1",
"Is this a good combination of ingredients? (0: not at all, 3: very good!)": "2",
"Are the used cooking actions suitable for the ingredients? (0: not at all, 3: totally!)": "2"
},
"noodle_8.md": {
"Is this a valid recipe?": "Yes",
"Does it seem eatable?": "Yes",
"Are the instructions understandable? (0: totally confusing, 3: very clear)": "3",
"How tasty is it probably? (0: not at all, 3: very tasty)": "2",
"Would you cook it? (0: not at all, 3: immediately!)": "2",
"How creative is this recipe? (0: not at all, 3: very creative!)": "1",
"Is this a good combination of ingredients? (0: not at all, 3: very good!)": "3",
"Are the used cooking actions suitable for the ingredients? (0: not at all, 3: totally!)": "2"
},
"rice_6.md": {
"Is this a valid recipe?": "Yes",
"Does it seem eatable?": "Yes",
"Are the instructions understandable? (0: totally confusing, 3: very clear)": "3",
"How tasty is it probably? (0: not at all, 3: very tasty)": "2",
"Would you cook it? (0: not at all, 3: immediately!)": "3",
"How creative is this recipe? (0: not at all, 3: very creative!)": "1",
"Is this a good combination of ingredients? (0: not at all, 3: very good!)": "3",
"Are the used cooking actions suitable for the ingredients? (0: not at all, 3: totally!)": "2"
}
},
{
"rice_5.md": {
"Is this a valid recipe?": "Yes",
"Does it seem eatable?": "Yes",
"Are the instructions understandable? (0: totally confusing, 3: very clear)": "3",
"How tasty is it probably? (0: not at all, 3: very tasty)": "2",
"Would you cook it? (0: not at all, 3: immediately!)": "0",
"How creative is this recipe? (0: not at all, 3: very creative!)": "2",
"Is this a good combination of ingredients? (0: not at all, 3: very good!)": "2",
"Are the used cooking actions suitable for the ingredients? (0: not at all, 3: totally!)": "2"
},
"noodle_8.md": {
"Is this a valid recipe?": "Yes",
"Does it seem eatable?": "Yes",
"Are the instructions understandable? (0: totally confusing, 3: very clear)": "3",
"How tasty is it probably? (0: not at all, 3: very tasty)": "3",
"Would you cook it? (0: not at all, 3: immediately!)": "3",
"How creative is this recipe? (0: not at all, 3: very creative!)": "3",
"Is this a good combination of ingredients? (0: not at all, 3: very good!)": "3",
"Are the used cooking actions suitable for the ingredients? (0: not at all, 3: totally!)": "3"
},
"rice_2.md": {
"Is this a valid recipe?": "Yes",
"Does it seem eatable?": "Yes",
"Are the instructions understandable? (0: totally confusing, 3: very clear)": "3",
"How tasty is it probably? (0: not at all, 3: very tasty)": "3",
"Would you cook it? (0: not at all, 3: immediately!)": "2",
"How creative is this recipe? (0: not at all, 3: very creative!)": "3",
"Is this a good combination of ingredients? (0: not at all, 3: very good!)": "3",
"Are the used cooking actions suitable for the ingredients? (0: not at all, 3: totally!)": "3"
},
"noodle_4.md": {
"Is this a valid recipe?": "Yes",
"Does it seem eatable?": "Yes",
"Are the instructions understandable? (0: totally confusing, 3: very clear)": "3",
"How tasty is it probably? (0: not at all, 3: very tasty)": "2",
"Would you cook it? (0: not at all, 3: immediately!)": "1",
"How creative is this recipe? (0: not at all, 3: very creative!)": "2",
"Is this a good combination of ingredients? (0: not at all, 3: very good!)": "1",
"Are the used cooking actions suitable for the ingredients? (0: not at all, 3: totally!)": "2"
}
},
{
"noodle_5.md": {
"Is this a valid recipe?": "Yes",
"Does it seem eatable?": "Yes",
"Are the instructions understandable? (0: totally confusing, 3: very clear)": "2",
"How tasty is it probably? (0: not at all, 3: very tasty)": "3",
"Would you cook it? (0: not at all, 3: immediately!)": "3",
"How creative is this recipe? (0: not at all, 3: very creative!)": "1",
"Is this a good combination of ingredients? (0: not at all, 3: very good!)": "3",
"Are the used cooking actions suitable for the ingredients? (0: not at all, 3: totally!)": "1"
},
"rice_3.md": {
"Is this a valid recipe?": "Yes",
"Does it seem eatable?": "Yes",
"Are the instructions understandable? (0: totally confusing, 3: very clear)": "3",
"How tasty is it probably? (0: not at all, 3: very tasty)": "3",
"Would you cook it? (0: not at all, 3: immediately!)": "3",
"How creative is this recipe? (0: not at all, 3: very creative!)": "3",
"Is this a good combination of ingredients? (0: not at all, 3: very good!)": "3",
"Are the used cooking actions suitable for the ingredients? (0: not at all, 3: totally!)": "3"
},
"rice_8.md": {
"Is this a valid recipe?": "Yes",
"Does it seem eatable?": "Yes",
"Are the instructions understandable? (0: totally confusing, 3: very clear)": "2",
"How tasty is it probably? (0: not at all, 3: very tasty)": "3",
"Would you cook it? (0: not at all, 3: immediately!)": "3",
"How creative is this recipe? (0: not at all, 3: very creative!)": "2",
"Is this a good combination of ingredients? (0: not at all, 3: very good!)": "3",
"Are the used cooking actions suitable for the ingredients? (0: not at all, 3: totally!)": "2"
},
"noodle_8.md": {
"Is this a valid recipe?": "Yes",
"Does it seem eatable?": "Yes",
"Are the instructions understandable? (0: totally confusing, 3: very clear)": "3",
"How tasty is it probably? (0: not at all, 3: very tasty)": "3",
"Would you cook it? (0: not at all, 3: immediately!)": "3",
"How creative is this recipe? (0: not at all, 3: very creative!)": "1",
"Is this a good combination of ingredients? (0: not at all, 3: very good!)": "3",
"Are the used cooking actions suitable for the ingredients? (0: not at all, 3: totally!)": "2"
}
},
{
"noodle_8.md": {
"Is this a valid recipe?": "Yes",
"Does it seem eatable?": "Yes",
"Are the instructions understandable? (0: totally confusing, 3: very clear)": "3",
"How tasty is it probably? (0: not at all, 3: very tasty)": "2",
"Would you cook it? (0: not at all, 3: immediately!)": "2",
"How creative is this recipe? (0: not at all, 3: very creative!)": "2",
"Is this a good combination of ingredients? (0: not at all, 3: very good!)": "2",
"Are the used cooking actions suitable for the ingredients? (0: not at all, 3: totally!)": "2"
},
"rice_4.md": {
"Is this a valid recipe?": "Yes",
"Does it seem eatable?": "Yes",
"Are the instructions understandable? (0: totally confusing, 3: very clear)": "3",
"How tasty is it probably? (0: not at all, 3: very tasty)": "2",
"Would you cook it? (0: not at all, 3: immediately!)": "2",
"How creative is this recipe? (0: not at all, 3: very creative!)": "2",
"Is this a good combination of ingredients? (0: not at all, 3: very good!)": "2",
"Are the used cooking actions suitable for the ingredients? (0: not at all, 3: totally!)": "2"
},
"rice_7.md": {
"Is this a valid recipe?": "Yes",
"Does it seem eatable?": "Yes",
"Are the instructions understandable? (0: totally confusing, 3: very clear)": "2",
"How tasty is it probably? (0: not at all, 3: very tasty)": "3",
"Would you cook it? (0: not at all, 3: immediately!)": "2",
"How creative is this recipe? (0: not at all, 3: very creative!)": "3",
"Is this a good combination of ingredients? (0: not at all, 3: very good!)": "2",
"Are the used cooking actions suitable for the ingredients? (0: not at all, 3: totally!)": "2"
},
"noodle_2.md": {
"Is this a valid recipe?": "Yes",
"Does it seem eatable?": "Yes",
"Are the instructions understandable? (0: totally confusing, 3: very clear)": "3",
"How tasty is it probably? (0: not at all, 3: very tasty)": "3",
"Would you cook it? (0: not at all, 3: immediately!)": "1",
"How creative is this recipe? (0: not at all, 3: very creative!)": "2",
"Is this a good combination of ingredients? (0: not at all, 3: very good!)": "2",
"Are the used cooking actions suitable for the ingredients? (0: not at all, 3: totally!)": "2"
}
},
{
"rice_2.md": {
"Is this a valid recipe?": "Yes",
"Does it seem eatable?": "Yes",
"Are the instructions understandable? (0: totally confusing, 3: very clear)": "2",
"How tasty is it probably? (0: not at all, 3: very tasty)": "1",
"Would you cook it? (0: not at all, 3: immediately!)": "1",
"How creative is this recipe? (0: not at all, 3: very creative!)": "1",
"Is this a good combination of ingredients? (0: not at all, 3: very good!)": "3",
"Are the used cooking actions suitable for the ingredients? (0: not at all, 3: totally!)": "1"
},
"noodle_1.md": {
"Is this a valid recipe?": "Yes",
"Does it seem eatable?": "Yes",
"Are the instructions understandable? (0: totally confusing, 3: very clear)": "1",
"How tasty is it probably? (0: not at all, 3: very tasty)": "2",
"Would you cook it? (0: not at all, 3: immediately!)": "1",
"How creative is this recipe? (0: not at all, 3: very creative!)": "2",
"Is this a good combination of ingredients? (0: not at all, 3: very good!)": "2",
"Are the used cooking actions suitable for the ingredients? (0: not at all, 3: totally!)": "1"
},
"noodle_7.md": {
"Is this a valid recipe?": "Yes",
"Does it seem eatable?": "No",
"Are the instructions understandable? (0: totally confusing, 3: very clear)": "0",
"How tasty is it probably? (0: not at all, 3: very tasty)": "1",
"Would you cook it? (0: not at all, 3: immediately!)": "0",
"How creative is this recipe? (0: not at all, 3: very creative!)": "3",
"Is this a good combination of ingredients? (0: not at all, 3: very good!)": "1",
"Are the used cooking actions suitable for the ingredients? (0: not at all, 3: totally!)": "1"
}
},
{
"noodle_3.md": {
"Is this a valid recipe?": "No",
"Does it seem eatable?": "No",
"Are the instructions understandable? (0: totally confusing, 3: very clear)": "3",
"How tasty is it probably? (0: not at all, 3: very tasty)": "0",
"Would you cook it? (0: not at all, 3: immediately!)": "0",
"How creative is this recipe? (0: not at all, 3: very creative!)": "2",
"Is this a good combination of ingredients? (0: not at all, 3: very good!)": "0",
"Are the used cooking actions suitable for the ingredients? (0: not at all, 3: totally!)": "0"
},
"rice_5.md": {
"Is this a valid recipe?": "Yes",
"Does it seem eatable?": "Yes",
"Are the instructions understandable? (0: totally confusing, 3: very clear)": "3",
"How tasty is it probably? (0: not at all, 3: very tasty)": "1",
"Would you cook it? (0: not at all, 3: immediately!)": "3",
"How creative is this recipe? (0: not at all, 3: very creative!)": "1",
"Is this a good combination of ingredients? (0: not at all, 3: very good!)": "2",
"Are the used cooking actions suitable for the ingredients? (0: not at all, 3: totally!)": "3"
},
"noodle_7.md": {
"Is this a valid recipe?": "Yes",
"Does it seem eatable?": "Yes",
"Are the instructions understandable? (0: totally confusing, 3: very clear)": "3",
"How tasty is it probably? (0: not at all, 3: very tasty)": "3",
"Would you cook it? (0: not at all, 3: immediately!)": "3",
"How creative is this recipe? (0: not at all, 3: very creative!)": "3",
"Is this a good combination of ingredients? (0: not at all, 3: very good!)": "2",
"Are the used cooking actions suitable for the ingredients? (0: not at all, 3: totally!)": "3"
},
"rice_6.md": {
"Is this a valid recipe?": "Yes",
"Does it seem eatable?": "Yes",
"Are the instructions understandable? (0: totally confusing, 3: very clear)": "3",
"How tasty is it probably? (0: not at all, 3: very tasty)": "1",
"Would you cook it? (0: not at all, 3: immediately!)": "2",
"How creative is this recipe? (0: not at all, 3: very creative!)": "2",
"Is this a good combination of ingredients? (0: not at all, 3: very good!)": "3",
"Are the used cooking actions suitable for the ingredients? (0: not at all, 3: totally!)": "3"
}
},
{
"noodle_6.md": {
"Is this a valid recipe?": "Yes",
"Does it seem eatable?": "Yes",
"Are the instructions understandable? (0: totally confusing, 3: very clear)": "3",
"How tasty is it probably? (0: not at all, 3: very tasty)": "2",
"Would you cook it? (0: not at all, 3: immediately!)": "3",
"How creative is this recipe? (0: not at all, 3: very creative!)": "2",
"Is this a good combination of ingredients? (0: not at all, 3: very good!)": "2",
"Are the used cooking actions suitable for the ingredients? (0: not at all, 3: totally!)": "2"
}
},
{
"rice_2.md": {
"Is this a valid recipe?": "Yes",
"Does it seem eatable?": "Yes",
"Are the instructions understandable? (0: totally confusing, 3: very clear)": "2",
"How tasty is it probably? (0: not at all, 3: very tasty)": "2",
"Would you cook it? (0: not at all, 3: immediately!)": "2",
"How creative is this recipe? (0: not at all, 3: very creative!)": "2",
"Is this a good combination of ingredients? (0: not at all, 3: very good!)": "3",
"Are the used cooking actions suitable for the ingredients? (0: not at all, 3: totally!)": "2"
},
"noodle_2.md": {
"Is this a valid recipe?": "Yes",
"Does it seem eatable?": "Yes",
"Are the instructions understandable? (0: totally confusing, 3: very clear)": "2",
"How tasty is it probably? (0: not at all, 3: very tasty)": "1",
"Would you cook it? (0: not at all, 3: immediately!)": "1",
"How creative is this recipe? (0: not at all, 3: very creative!)": "3",
"Is this a good combination of ingredients? (0: not at all, 3: very good!)": "2",
"Are the used cooking actions suitable for the ingredients? (0: not at all, 3: totally!)": "2"
},
"noodle_4.md": {
"Is this a valid recipe?": "Yes",
"Does it seem eatable?": "Yes",
"Are the instructions understandable? (0: totally confusing, 3: very clear)": "2",
"How tasty is it probably? (0: not at all, 3: very tasty)": "2",
"Would you cook it? (0: not at all, 3: immediately!)": "3",
"How creative is this recipe? (0: not at all, 3: very creative!)": "2",
"Is this a good combination of ingredients? (0: not at all, 3: very good!)": "2",
"Are the used cooking actions suitable for the ingredients? (0: not at all, 3: totally!)": "2"
},
"rice_4.md": {
"Is this a valid recipe?": "Yes",
"Does it seem eatable?": "Yes",
"Are the instructions understandable? (0: totally confusing, 3: very clear)": "3",
"How tasty is it probably? (0: not at all, 3: very tasty)": "3",
"Would you cook it? (0: not at all, 3: immediately!)": "3",
"How creative is this recipe? (0: not at all, 3: very creative!)": "2",
"Is this a good combination of ingredients? (0: not at all, 3: very good!)": "3",
"Are the used cooking actions suitable for the ingredients? (0: not at all, 3: totally!)": "3"
}
},
{
"rice_7.md": {
"Is this a valid recipe?": "No",
"Does it seem eatable?": "Yes",
"Are the instructions understandable? (0: totally confusing, 3: very clear)": "3",
"How tasty is it probably? (0: not at all, 3: very tasty)": "1",
"Would you cook it? (0: not at all, 3: immediately!)": "0",
"How creative is this recipe? (0: not at all, 3: very creative!)": "2",
"Is this a good combination of ingredients? (0: not at all, 3: very good!)": "3",
"Are the used cooking actions suitable for the ingredients? (0: not at all, 3: totally!)": "1"
},
"noodle_9.md": {
"Is this a valid recipe?": "No",
"Does it seem eatable?": "Yes",
"Are the instructions understandable? (0: totally confusing, 3: very clear)": "3",
"How tasty is it probably? (0: not at all, 3: very tasty)": "2",
"Would you cook it? (0: not at all, 3: immediately!)": "1",
"How creative is this recipe? (0: not at all, 3: very creative!)": "2",
"Is this a good combination of ingredients? (0: not at all, 3: very good!)": "3",
"Are the used cooking actions suitable for the ingredients? (0: not at all, 3: totally!)": "1"
},
"rice_8.md": {
"Is this a valid recipe?": "No",
"Does it seem eatable?": "Yes",
"Are the instructions understandable? (0: totally confusing, 3: very clear)": "3",
"How tasty is it probably? (0: not at all, 3: very tasty)": "2",
"Would you cook it? (0: not at all, 3: immediately!)": "1",
"How creative is this recipe? (0: not at all, 3: very creative!)": "2",
"Is this a good combination of ingredients? (0: not at all, 3: very good!)": "3",
"Are the used cooking actions suitable for the ingredients? (0: not at all, 3: totally!)": "1"
},
"noodle_4.md": {
"Is this a valid recipe?": "No",
"Does it seem eatable?": "Yes",
"Are the instructions understandable? (0: totally confusing, 3: very clear)": "2",
"How tasty is it probably? (0: not at all, 3: very tasty)": "3",
"Would you cook it? (0: not at all, 3: immediately!)": "2",
"How creative is this recipe? (0: not at all, 3: very creative!)": "1",
"Is this a good combination of ingredients? (0: not at all, 3: very good!)": "3",
"Are the used cooking actions suitable for the ingredients? (0: not at all, 3: totally!)": "1"
}
},
{
"noodle_5.md": {
"Is this a valid recipe?": "Yes",
"Does it seem eatable?": "Yes",
"Are the instructions understandable? (0: totally confusing, 3: very clear)": "3",
"How tasty is it probably? (0: not at all, 3: very tasty)": "2",
"Would you cook it? (0: not at all, 3: immediately!)": "1",
"How creative is this recipe? (0: not at all, 3: very creative!)": "0",
"Is this a good combination of ingredients? (0: not at all, 3: very good!)": "2",
"Are the used cooking actions suitable for the ingredients? (0: not at all, 3: totally!)": "3"
},
"rice_1.md": {
"Is this a valid recipe?": "Yes",
"Does it seem eatable?": "Yes",
"Are the instructions understandable? (0: totally confusing, 3: very clear)": "3",
"How tasty is it probably? (0: not at all, 3: very tasty)": "2",
"Would you cook it? (0: not at all, 3: immediately!)": "1",
"How creative is this recipe? (0: not at all, 3: very creative!)": "3",
"Is this a good combination of ingredients? (0: not at all, 3: very good!)": "1",
"Are the used cooking actions suitable for the ingredients? (0: not at all, 3: totally!)": "2"
},
"rice_6.md": {
"Is this a valid recipe?": "No",
"Does it seem eatable?": "No",
"Are the instructions understandable? (0: totally confusing, 3: very clear)": "1",
"How tasty is it probably? (0: not at all, 3: very tasty)": "3",
"Would you cook it? (0: not at all, 3: immediately!)": "1",
"How creative is this recipe? (0: not at all, 3: very creative!)": "1",
"Is this a good combination of ingredients? (0: not at all, 3: very good!)": "2",
"Are the used cooking actions suitable for the ingredients? (0: not at all, 3: totally!)": "0"
},
"noodle_0.md": {
"Is this a valid recipe?": "Yes",
"Does it seem eatable?": "Yes",
"Are the instructions understandable? (0: totally confusing, 3: very clear)": "3",
"How tasty is it probably? (0: not at all, 3: very tasty)": "1",
"Would you cook it? (0: not at all, 3: immediately!)": "0",
"How creative is this recipe? (0: not at all, 3: very creative!)": "3",
"Is this a good combination of ingredients? (0: not at all, 3: very good!)": "3",
"Are the used cooking actions suitable for the ingredients? (0: not at all, 3: totally!)": "1"
}
},
{
"rice_5.md": {
"Is this a valid recipe?": "Yes",
"Does it seem eatable?": "Yes",
"Are the instructions understandable? (0: totally confusing, 3: very clear)": "3",
"How tasty is it probably? (0: not at all, 3: very tasty)": "2",
"Would you cook it? (0: not at all, 3: immediately!)": "2",
"How creative is this recipe? (0: not at all, 3: very creative!)": "2",
"Is this a good combination of ingredients? (0: not at all, 3: very good!)": "2",
"Are the used cooking actions suitable for the ingredients? (0: not at all, 3: totally!)": "1"
},
"noodle_8.md": {
"Is this a valid recipe?": "Yes",
"Does it seem eatable?": "Yes",
"Are the instructions understandable? (0: totally confusing, 3: very clear)": "3",
"How tasty is it probably? (0: not at all, 3: very tasty)": "2",
"Would you cook it? (0: not at all, 3: immediately!)": "2",
"How creative is this recipe? (0: not at all, 3: very creative!)": "2",
"Is this a good combination of ingredients? (0: not at all, 3: very good!)": "2",
"Are the used cooking actions suitable for the ingredients? (0: not at all, 3: totally!)": "3"
},
"rice_8.md": {
"Is this a valid recipe?": "Yes",
"Does it seem eatable?": "Yes",
"Are the instructions understandable? (0: totally confusing, 3: very clear)": "3",
"How tasty is it probably? (0: not at all, 3: very tasty)": "2",
"Would you cook it? (0: not at all, 3: immediately!)": "2",
"How creative is this recipe? (0: not at all, 3: very creative!)": "2",
"Is this a good combination of ingredients? (0: not at all, 3: very good!)": "2",
"Are the used cooking actions suitable for the ingredients? (0: not at all, 3: totally!)": "2"
},
"noodle_1.md": {
"Is this a valid recipe?": "Yes",
"Does it seem eatable?": "Yes",
"Are the instructions understandable? (0: totally confusing, 3: very clear)": "3",
"How tasty is it probably? (0: not at all, 3: very tasty)": "1",
"Would you cook it? (0: not at all, 3: immediately!)": "0",
"How creative is this recipe? (0: not at all, 3: very creative!)": "1",
"Is this a good combination of ingredients? (0: not at all, 3: very good!)": "1",
"Are the used cooking actions suitable for the ingredients? (0: not at all, 3: totally!)": "1"
}
},
{
"noodle_2.md": {
"Is this a valid recipe?": "Yes",
"Does it seem eatable?": "Yes",
"Are the instructions understandable? (0: totally confusing, 3: very clear)": "2",
"How tasty is it probably? (0: not at all, 3: very tasty)": "1",
"Would you cook it? (0: not at all, 3: immediately!)": "1",
"How creative is this recipe? (0: not at all, 3: very creative!)": "1",
"Is this a good combination of ingredients? (0: not at all, 3: very good!)": "2",
"Are the used cooking actions suitable for the ingredients? (0: not at all, 3: totally!)": "2"
},
"rice_5.md": {
"Is this a valid recipe?": "No",
"Does it seem eatable?": "No",
"Are the instructions understandable? (0: totally confusing, 3: very clear)": "2",
"How tasty is it probably? (0: not at all, 3: very tasty)": "0",
"Would you cook it? (0: not at all, 3: immediately!)": "0",
"How creative is this recipe? (0: not at all, 3: very creative!)": "1",
"Is this a good combination of ingredients? (0: not at all, 3: very good!)": "0",
"Are the used cooking actions suitable for the ingredients? (0: not at all, 3: totally!)": "0"
},
"noodle_5.md": {
"Is this a valid recipe?": "Yes",
"Does it seem eatable?": "Yes",
"Are the instructions understandable? (0: totally confusing, 3: very clear)": "3",
"How tasty is it probably? (0: not at all, 3: very tasty)": "3",
"Would you cook it? (0: not at all, 3: immediately!)": "3",
"How creative is this recipe? (0: not at all, 3: very creative!)": "2",
"Is this a good combination of ingredients? (0: not at all, 3: very good!)": "3",
"Are the used cooking actions suitable for the ingredients? (0: not at all, 3: totally!)": "3"
},
"rice_1.md": {
"Is this a valid recipe?": "Yes",
"Does it seem eatable?": "Yes",
"Are the instructions understandable? (0: totally confusing, 3: very clear)": "2",
"How tasty is it probably? (0: not at all, 3: very tasty)": "1",
"Would you cook it? (0: not at all, 3: immediately!)": "1",
"How creative is this recipe? (0: not at all, 3: very creative!)": "1",
"Is this a good combination of ingredients? (0: not at all, 3: very good!)": "1",
"Are the used cooking actions suitable for the ingredients? (0: not at all, 3: totally!)": "0"
}
},
{
"rice_9.md": {
"Is this a valid recipe?": "Yes",
"Does it seem eatable?": "Yes",
"Are the instructions understandable? (0: totally confusing, 3: very clear)": "2",
"How tasty is it probably? (0: not at all, 3: very tasty)": "2",
"Would you cook it? (0: not at all, 3: immediately!)": "2",
"How creative is this recipe? (0: not at all, 3: very creative!)": "2",
"Is this a good combination of ingredients? (0: not at all, 3: very good!)": "2",
"Are the used cooking actions suitable for the ingredients? (0: not at all, 3: totally!)": "1"
},
"noodle_6.md": {
"Is this a valid recipe?": "Yes",
"Does it seem eatable?": "Yes",
"Are the instructions understandable? (0: totally confusing, 3: very clear)": "3",
"How tasty is it probably? (0: not at all, 3: very tasty)": "2",
"Would you cook it? (0: not at all, 3: immediately!)": "2",
"How creative is this recipe? (0: not at all, 3: very creative!)": "3",
"Is this a good combination of ingredients? (0: not at all, 3: very good!)": "3",
"Are the used cooking actions suitable for the ingredients? (0: not at all, 3: totally!)": "2"
},
"rice_0.md": {
"Is this a valid recipe?": "Yes",
"Does it seem eatable?": "Yes",
"Are the instructions understandable? (0: totally confusing, 3: very clear)": "3",
"How tasty is it probably? (0: not at all, 3: very tasty)": "3",
"Would you cook it? (0: not at all, 3: immediately!)": "3",
"How creative is this recipe? (0: not at all, 3: very creative!)": "2",
"Is this a good combination of ingredients? (0: not at all, 3: very good!)": "3",
"Are the used cooking actions suitable for the ingredients? (0: not at all, 3: totally!)": "2"
}
},
{
"noodle_4.md": {
"Is this a valid recipe?": "Yes",
"Does it seem eatable?": "Yes",
"Are the instructions understandable? (0: totally confusing, 3: very clear)": "3",
"How tasty is it probably? (0: not at all, 3: very tasty)": "2",
"Would you cook it? (0: not at all, 3: immediately!)": "1",
"How creative is this recipe? (0: not at all, 3: very creative!)": "1",
"Is this a good combination of ingredients? (0: not at all, 3: very good!)": "3",
"Are the used cooking actions suitable for the ingredients? (0: not at all, 3: totally!)": "3"
},
"rice_2.md": {
"Is this a valid recipe?": "No",
"Does it seem eatable?": "No",
"Are the instructions understandable? (0: totally confusing, 3: very clear)": "2",
"How tasty is it probably? (0: not at all, 3: very tasty)": "1",
"Would you cook it? (0: not at all, 3: immediately!)": "0",
"How creative is this recipe? (0: not at all, 3: very creative!)": "1",
"Is this a good combination of ingredients? (0: not at all, 3: very good!)": "1",
"Are the used cooking actions suitable for the ingredients? (0: not at all, 3: totally!)": "0"
},
"noodle_9.md": {
"Is this a valid recipe?": "Yes",
"Does it seem eatable?": "Yes",
"Are the instructions understandable? (0: totally confusing, 3: very clear)": "3",
"How tasty is it probably? (0: not at all, 3: very tasty)": "3",
"Would you cook it? (0: not at all, 3: immediately!)": "3",
"How creative is this recipe? (0: not at all, 3: very creative!)": "3",
"Is this a good combination of ingredients? (0: not at all, 3: very good!)": "3",
"Are the used cooking actions suitable for the ingredients? (0: not at all, 3: totally!)": "3"
},
"rice_8.md": {
"Is this a valid recipe?": "No",
"Does it seem eatable?": "No",
"Are the instructions understandable? (0: totally confusing, 3: very clear)": "1",
"How tasty is it probably? (0: not at all, 3: very tasty)": "1",
"Would you cook it? (0: not at all, 3: immediately!)": "0",
"How creative is this recipe? (0: not at all, 3: very creative!)": "1",
"Is this a good combination of ingredients? (0: not at all, 3: very good!)": "1",
"Are the used cooking actions suitable for the ingredients? (0: not at all, 3: totally!)": "0"
}
},
{
"noodle_7.md": {
"Is this a valid recipe?": "Yes",
"Does it seem eatable?": "Yes",
"Are the instructions understandable? (0: totally confusing, 3: very clear)": "2",
"How tasty is it probably? (0: not at all, 3: very tasty)": "1",
"Would you cook it? (0: not at all, 3: immediately!)": "1",
"How creative is this recipe? (0: not at all, 3: very creative!)": "1",
"Is this a good combination of ingredients? (0: not at all, 3: very good!)": "2",
"Are the used cooking actions suitable for the ingredients? (0: not at all, 3: totally!)": "1"
},
"noodle_4.md": {
"Is this a valid recipe?": "Yes",
"Does it seem eatable?": "Yes",
"Are the instructions understandable? (0: totally confusing, 3: very clear)": "2",
"How tasty is it probably? (0: not at all, 3: very tasty)": "1",
"Would you cook it? (0: not at all, 3: immediately!)": "0",
"How creative is this recipe? (0: not at all, 3: very creative!)": "1",
"Is this a good combination of ingredients? (0: not at all, 3: very good!)": "1",
"Are the used cooking actions suitable for the ingredients? (0: not at all, 3: totally!)": "0"
},
"rice_8.md": {
"Is this a valid recipe?": "Yes",
"Does it seem eatable?": "Yes",
"Are the instructions understandable? (0: totally confusing, 3: very clear)": "3",
"How tasty is it probably? (0: not at all, 3: very tasty)": "2",
"Would you cook it? (0: not at all, 3: immediately!)": "1",
"How creative is this recipe? (0: not at all, 3: very creative!)": "2",
"Is this a good combination of ingredients? (0: not at all, 3: very good!)": "1",
"Are the used cooking actions suitable for the ingredients? (0: not at all, 3: totally!)": "3"
},
"rice_3.md": {
"Is this a valid recipe?": "Yes",
"Does it seem eatable?": "Yes",
"Are the instructions understandable? (0: totally confusing, 3: very clear)": "3",
"How tasty is it probably? (0: not at all, 3: very tasty)": "1",
"Would you cook it? (0: not at all, 3: immediately!)": "1",
"How creative is this recipe? (0: not at all, 3: very creative!)": "2",
"Is this a good combination of ingredients? (0: not at all, 3: very good!)": "2",
"Are the used cooking actions suitable for the ingredients? (0: not at all, 3: totally!)": "2"
}
},
{
"rice_2.md": {
"Is this a valid recipe?": "Yes",
"Does it seem eatable?": "Yes",
"Are the instructions understandable? (0: totally confusing, 3: very clear)": "2",
"How tasty is it probably? (0: not at all, 3: very tasty)": "2",
"Would you cook it? (0: not at all, 3: immediately!)": "1",
"How creative is this recipe? (0: not at all, 3: very creative!)": "2",
"Is this a good combination of ingredients? (0: not at all, 3: very good!)": "2",
"Are the used cooking actions suitable for the ingredients? (0: not at all, 3: totally!)": "1"
},
"noodle_2.md": {
"Is this a valid recipe?": "Yes",
"Does it seem eatable?": "Yes",
"Are the instructions understandable? (0: totally confusing, 3: very clear)": "2",
"How tasty is it probably? (0: not at all, 3: very tasty)": "2",
"Would you cook it? (0: not at all, 3: immediately!)": "2",
"How creative is this recipe? (0: not at all, 3: very creative!)": "3",
"Is this a good combination of ingredients? (0: not at all, 3: very good!)": "1",
"Are the used cooking actions suitable for the ingredients? (0: not at all, 3: totally!)": "2"
},
"rice_7.md": {
"Is this a valid recipe?": "Yes",
"Does it seem eatable?": "Yes",
"Are the instructions understandable? (0: totally confusing, 3: very clear)": "2",
"How tasty is it probably? (0: not at all, 3: very tasty)": "2",
"Would you cook it? (0: not at all, 3: immediately!)": "2",
"How creative is this recipe? (0: not at all, 3: very creative!)": "2",
"Is this a good combination of ingredients? (0: not at all, 3: very good!)": "3",
"Are the used cooking actions suitable for the ingredients? (0: not at all, 3: totally!)": "3"
},
"noodle_0.md": {
"Is this a valid recipe?": "Yes",
"Does it seem eatable?": "No",
"Are the instructions understandable? (0: totally confusing, 3: very clear)": "3",
"How tasty is it probably? (0: not at all, 3: very tasty)": "1",
"Would you cook it? (0: not at all, 3: immediately!)": "0",
"How creative is this recipe? (0: not at all, 3: very creative!)": "2",
"Is this a good combination of ingredients? (0: not at all, 3: very good!)": "0",
"Are the used cooking actions suitable for the ingredients? (0: not at all, 3: totally!)": "1"
}
},
{
"noodle_9.md": {
"Is this a valid recipe?": "Yes",
"Does it seem eatable?": "Yes",
"Are the instructions understandable? (0: totally confusing, 3: very clear)": "3",
"How tasty is it probably? (0: not at all, 3: very tasty)": "2",
"Would you cook it? (0: not at all, 3: immediately!)": "1",
"How creative is this recipe? (0: not at all, 3: very creative!)": "2",
"Is this a good combination of ingredients? (0: not at all, 3: very good!)": "2",
"Are the used cooking actions suitable for the ingredients? (0: not at all, 3: totally!)": "2"
},
"rice_6.md": {
"Is this a valid recipe?": "Yes",
"Does it seem eatable?": "Yes",
"Are the instructions understandable? (0: totally confusing, 3: very clear)": "3",
"How tasty is it probably? (0: not at all, 3: very tasty)": "3",
"Would you cook it? (0: not at all, 3: immediately!)": "2",
"How creative is this recipe? (0: not at all, 3: very creative!)": "1",
"Is this a good combination of ingredients? (0: not at all, 3: very good!)": "3",
"Are the used cooking actions suitable for the ingredients? (0: not at all, 3: totally!)": "2"
},
"rice_5.md": {
"Is this a valid recipe?": "Yes",
"Does it seem eatable?": "Yes",
"Are the instructions understandable? (0: totally confusing, 3: very clear)": "3",
"How tasty is it probably? (0: not at all, 3: very tasty)": "2",
"Would you cook it? (0: not at all, 3: immediately!)": "3",
"How creative is this recipe? (0: not at all, 3: very creative!)": "2",
"Is this a good combination of ingredients? (0: not at all, 3: very good!)": "3",
"Are the used cooking actions suitable for the ingredients? (0: not at all, 3: totally!)": "2"
},
"noodle_8.md": {
"Is this a valid recipe?": "Yes",
"Does it seem eatable?": "Yes",
"Are the instructions understandable? (0: totally confusing, 3: very clear)": "3",
"How tasty is it probably? (0: not at all, 3: very tasty)": "2",
"Would you cook it? (0: not at all, 3: immediately!)": "2",
"How creative is this recipe? (0: not at all, 3: very creative!)": "1",
"Is this a good combination of ingredients? (0: not at all, 3: very good!)": "2",
"Are the used cooking actions suitable for the ingredients? (0: not at all, 3: totally!)": "2"
}
}
]

View File

@ -0,0 +1,9 @@
"noodle_0.md","noodle_1.md","noodle_2.md","noodle_3.md","noodle_4.md","noodle_5.md","noodle_6.md","noodle_7.md","noodle_8.md","noodle_9.md","rice_0.md","rice_1.md","rice_2.md","rice_3.md","rice_4.md","rice_5.md","rice_6.md","rice_7.md","rice_8.md","rice_9.md"
1,1,1,0.5,0.8,1,1,1,1,0.6666666666666666,1,1,0.8333333333333334,1,1,0.8,0.75,0.6666666666666666,0.6666666666666666,1
0.5,1,1,0.5,1,1,1,0.6666666666666666,1,1,1,1,0.8333333333333334,1,1,0.8,0.75,1,0.8333333333333334,1
3,2,2.25,2,2.4,2.75,3,1.6666666666666667,3,3,3,2.5,2.3333333333333335,3,3,2.8,2.5,2.3333333333333335,2.5,2.5
1,1.5,1.75,0.5,2,2.5,2,1.6666666666666667,2.142857142857143,2.3333333333333335,2.5,1.5,1.6666666666666667,2,2.5,1.4,2.25,2,2.1666666666666665,2
0,0.5,1.25,0,1.4,2,2.5,1.3333333333333333,2.142857142857143,1.6666666666666667,2.5,1,1.1666666666666667,2,2.5,1.6,2,1.3333333333333333,1.5,2
2.5,1.5,2.25,2,1.4,1.25,2.5,2.3333333333333335,1.7142857142857142,2.3333333333333335,2.5,2,1.8333333333333333,2.5,2,1.6,1.25,2.3333333333333335,1.8333333333333333,1.5
1.5,1.5,1.75,0.5,2,2.75,2.5,1.6666666666666667,2.5714285714285716,2.6666666666666665,2,1,2.1666666666666665,2.5,2.5,1.8,2.75,2.6666666666666665,2.1666666666666665,2
1,1,2,0.5,1.6,2,2,1.6666666666666667,2.142857142857143,2,2,1,1.5,2.5,2.5,1.6,1.75,2,1.8333333333333333,1.5
1 noodle_0.md noodle_1.md noodle_2.md noodle_3.md noodle_4.md noodle_5.md noodle_6.md noodle_7.md noodle_8.md noodle_9.md rice_0.md rice_1.md rice_2.md rice_3.md rice_4.md rice_5.md rice_6.md rice_7.md rice_8.md rice_9.md
2 1 1 1 0.5 0.8 1 1 1 1 0.6666666666666666 1 1 0.8333333333333334 1 1 0.8 0.75 0.6666666666666666 0.6666666666666666 1
3 0.5 1 1 0.5 1 1 1 0.6666666666666666 1 1 1 1 0.8333333333333334 1 1 0.8 0.75 1 0.8333333333333334 1
4 3 2 2.25 2 2.4 2.75 3 1.6666666666666667 3 3 3 2.5 2.3333333333333335 3 3 2.8 2.5 2.3333333333333335 2.5 2.5
5 1 1.5 1.75 0.5 2 2.5 2 1.6666666666666667 2.142857142857143 2.3333333333333335 2.5 1.5 1.6666666666666667 2 2.5 1.4 2.25 2 2.1666666666666665 2
6 0 0.5 1.25 0 1.4 2 2.5 1.3333333333333333 2.142857142857143 1.6666666666666667 2.5 1 1.1666666666666667 2 2.5 1.6 2 1.3333333333333333 1.5 2
7 2.5 1.5 2.25 2 1.4 1.25 2.5 2.3333333333333335 1.7142857142857142 2.3333333333333335 2.5 2 1.8333333333333333 2.5 2 1.6 1.25 2.3333333333333335 1.8333333333333333 1.5
8 1.5 1.5 1.75 0.5 2 2.75 2.5 1.6666666666666667 2.5714285714285716 2.6666666666666665 2 1 2.1666666666666665 2.5 2.5 1.8 2.75 2.6666666666666665 2.1666666666666665 2
9 1 1 2 0.5 1.6 2 2 1.6666666666666667 2.142857142857143 2 2 1 1.5 2.5 2.5 1.6 1.75 2 1.8333333333333333 1.5

View File

@ -0,0 +1 @@
{"Is this a valid recipe?": {"noodle_8.md": 1.0, "noodle_3.md": 0.5, "rice_8.md": 0.6666666666666666, "rice_2.md": 0.8333333333333334, "rice_0.md": 1.0, "noodle_5.md": 1.0, "rice_9.md": 1.0, "rice_6.md": 0.75, "rice_5.md": 0.8, "noodle_4.md": 0.8, "rice_3.md": 1.0, "rice_4.md": 1.0, "rice_7.md": 0.6666666666666666, "noodle_2.md": 1.0, "noodle_1.md": 1.0, "noodle_7.md": 1.0, "noodle_6.md": 1.0, "noodle_9.md": 0.6666666666666666, "rice_1.md": 1.0, "noodle_0.md": 1.0}, "Does it seem eatable?": {"noodle_8.md": 1.0, "noodle_3.md": 0.5, "rice_8.md": 0.8333333333333334, "rice_2.md": 0.8333333333333334, "rice_0.md": 1.0, "noodle_5.md": 1.0, "rice_9.md": 1.0, "rice_6.md": 0.75, "rice_5.md": 0.8, "noodle_4.md": 1.0, "rice_3.md": 1.0, "rice_4.md": 1.0, "rice_7.md": 1.0, "noodle_2.md": 1.0, "noodle_1.md": 1.0, "noodle_7.md": 0.6666666666666666, "noodle_6.md": 1.0, "noodle_9.md": 1.0, "rice_1.md": 1.0, "noodle_0.md": 0.5}, "Are the instructions understandable? (0: totally confusing, 3: very clear)": {"noodle_8.md": 3.0, "noodle_3.md": 2.0, "rice_8.md": 2.5, "rice_2.md": 2.3333333333333335, "rice_0.md": 3.0, "noodle_5.md": 2.75, "rice_9.md": 2.5, "rice_6.md": 2.5, "rice_5.md": 2.8, "noodle_4.md": 2.4, "rice_3.md": 3.0, "rice_4.md": 3.0, "rice_7.md": 2.3333333333333335, "noodle_2.md": 2.25, "noodle_1.md": 2.0, "noodle_7.md": 1.6666666666666667, "noodle_6.md": 3.0, "noodle_9.md": 3.0, "rice_1.md": 2.5, "noodle_0.md": 3.0}, "How tasty is it probably? (0: not at all, 3: very tasty)": {"noodle_8.md": 2.142857142857143, "noodle_3.md": 0.5, "rice_8.md": 2.1666666666666665, "rice_2.md": 1.6666666666666667, "rice_0.md": 2.5, "noodle_5.md": 2.5, "rice_9.md": 2.0, "rice_6.md": 2.25, "rice_5.md": 1.4, "noodle_4.md": 2.0, "rice_3.md": 2.0, "rice_4.md": 2.5, "rice_7.md": 2.0, "noodle_2.md": 1.75, "noodle_1.md": 1.5, "noodle_7.md": 1.6666666666666667, "noodle_6.md": 2.0, "noodle_9.md": 2.3333333333333335, "rice_1.md": 1.5, "noodle_0.md": 1.0}, "Would you cook it? (0: not at all, 3: immediately!)": {"noodle_8.md": 2.142857142857143, "noodle_3.md": 0.0, "rice_8.md": 1.5, "rice_2.md": 1.1666666666666667, "rice_0.md": 2.5, "noodle_5.md": 2.0, "rice_9.md": 2.0, "rice_6.md": 2.0, "rice_5.md": 1.6, "noodle_4.md": 1.4, "rice_3.md": 2.0, "rice_4.md": 2.5, "rice_7.md": 1.3333333333333333, "noodle_2.md": 1.25, "noodle_1.md": 0.5, "noodle_7.md": 1.3333333333333333, "noodle_6.md": 2.5, "noodle_9.md": 1.6666666666666667, "rice_1.md": 1.0, "noodle_0.md": 0.0}, "How creative is this recipe? (0: not at all, 3: very creative!)": {"noodle_8.md": 1.7142857142857142, "noodle_3.md": 2.0, "rice_8.md": 1.8333333333333333, "rice_2.md": 1.8333333333333333, "rice_0.md": 2.5, "noodle_5.md": 1.25, "rice_9.md": 1.5, "rice_6.md": 1.25, "rice_5.md": 1.6, "noodle_4.md": 1.4, "rice_3.md": 2.5, "rice_4.md": 2.0, "rice_7.md": 2.3333333333333335, "noodle_2.md": 2.25, "noodle_1.md": 1.5, "noodle_7.md": 2.3333333333333335, "noodle_6.md": 2.5, "noodle_9.md": 2.3333333333333335, "rice_1.md": 2.0, "noodle_0.md": 2.5}, "Is this a good combination of ingredients? (0: not at all, 3: very good!)": {"noodle_8.md": 2.5714285714285716, "noodle_3.md": 0.5, "rice_8.md": 2.1666666666666665, "rice_2.md": 2.1666666666666665, "rice_0.md": 2.0, "noodle_5.md": 2.75, "rice_9.md": 2.0, "rice_6.md": 2.75, "rice_5.md": 1.8, "noodle_4.md": 2.0, "rice_3.md": 2.5, "rice_4.md": 2.5, "rice_7.md": 2.6666666666666665, "noodle_2.md": 1.75, "noodle_1.md": 1.5, "noodle_7.md": 1.6666666666666667, "noodle_6.md": 2.5, "noodle_9.md": 2.6666666666666665, "rice_1.md": 1.0, "noodle_0.md": 1.5}, "Are the used cooking actions suitable for the ingredients? (0: not at all, 3: totally!)": {"noodle_8.md": 2.142857142857143, "noodle_3.md": 0.5, "rice_8.md": 1.8333333333333333, "rice_2.md": 1.5, "rice_0.md": 2.0, "noodle_5.md": 2.0, "rice_9.md": 1.5, "rice_6.md": 1.75, "rice_5.md": 1.6, "noodle_4.md": 1.6, "rice_3.md": 2.5, "rice_4.md": 2.5, "rice_7.md": 2.0, "noodle_2.md": 2.0, "noodle_1.md": 1.0, "noodle_7.md": 1.6666666666666667, "noodle_6.md": 2.0, "noodle_9.md": 2.0, "rice_1.md": 1.0, "noodle_0.md": 1.0}}

File diff suppressed because it is too large Load Diff

View File

@ -727,7 +727,19 @@ class MixNode(RecipeTreeNode):
n = random.choice(range(1, len(childs)-1)) n = random.choice(range(1, len(childs)-1))
between_node = ActionNode(random.choice(actions)) ings = self.traverse_ingredients()
ing = random.choice(ings)
base_ing = ing._base_ingredient
act = None
try:
a, w = m_base_act.get_backward_adjacent(base_ing)
act = ea_tools.wheel_of_fortune_selection(a,w)
except ValueError:
print("Warning: cannot mutate given node")
if act is not None:
between_node = ActionNode(act)
self.split(set(childs[:n]), set(childs[n:]), between_node) self.split(set(childs[:n]), set(childs[n:]), between_node)
@ -760,13 +772,19 @@ class MixNode(RecipeTreeNode):
#p2 = sym_p_a_given_b(ing_b.to_json(), ing_a.to_json(), m_mix, c_mix) #p2 = sym_p_a_given_b(ing_b.to_json(), ing_a.to_json(), m_mix, c_mix)
#s += 0.5 * p1 + 0.5 * p2 #s += 0.5 * p1 + 0.5 * p2
grouped_ing_a = to_grouped_ingredient(ing_a) #grouped_ing_a = to_grouped_ingredient(ing_a)
grouped_ing_b = to_grouped_ingredient(ing_b) #grouped_ing_b = to_grouped_ingredient(ing_b)
ia = m_grouped_mix._label_index[grouped_ing_a.to_json()] #ia = m_grouped_mix._label_index[grouped_ing_a.to_json()]
ib = m_grouped_mix._label_index[grouped_ing_b.to_json()] #ib = m_grouped_mix._label_index[grouped_ing_b.to_json()]
if c_grouped_mix[ia,ib] > 0 or c_grouped_mix[ib,ia] > 0: #if c_grouped_mix[ia,ib] > 0 or c_grouped_mix[ib,ia] > 0:
# s += 1
ia = m_mix._label_index[grouped_ing_a.to_json()]
ib = m_mix._label_index[grouped_ing_b.to_json()]
if c_mix[ia,ib] > 0 or c_mix[ib,ia] > 0:
s += 1 s += 1
@ -1302,11 +1320,12 @@ class Tree(object):
return Tree(nodes[s[0]['id']]) return Tree(nodes[s[0]['id']])
def __init__(self, root): def __init__(self, root, main_ingredients=None):
# create a dummy entry node # create a dummy entry node
self._root = RecipeTreeNode("root", single_child=True) self._root = RecipeTreeNode("root", single_child=True)
self._root.add_child(root) self._root.add_child(root)
self._touched = True self._touched = True
self._main_ingredients = main_ingredients
def root(self): def root(self):
return self._root.child() return self._root.child()
@ -1321,7 +1340,7 @@ class Tree(object):
n.mutate() n.mutate()
# check for simplification after modification # check for simplification after modification
# self.root().simplify() self.root().simplify()
def dot(self): def dot(self):
return self.root().dot() return self.root().dot()
@ -1379,6 +1398,29 @@ class Tree(object):
def ing_scores(self): def ing_scores(self):
return self._ing_scores return self._ing_scores
def main_ingredient_score(self):
if self._main_ingredients is None:
return 1
ings = self.root().traverse_ingredients()
actions_for_ing = {}
score_for_ing = {}
for ing in ings:
if ing._base_ingredient in self._main_ingredients:
actions_for_ing[ing._base_ingredient] = ing._action_set
score_for_ing[ing._base_ingredient] = 0
for ing in self._main_ingredients:
for act in actions_for_ing[ing]:
s = fw_p_a_given_b(act, ing, m_base_act, c_base_act)
if s > 0.5:
score_for_ing[ing] = 1
return sum([score_for_ing[ing] for ing in self._main_ingredients]) / len(self._main_ingredients)
def score(self): def score(self):
if not self._touched: if not self._touched:
return self._score return self._score
@ -1408,6 +1450,7 @@ class Tree(object):
else: else:
self._score = (sum_mix + sum_act + sum_ing) / n self._score = (sum_mix + sum_act + sum_ing) / n
self._score *= (len(s_ing) - self._n_duplicates) / len(s_ing) self._score *= (len(s_ing) - self._n_duplicates) / len(s_ing)
#self._score = 0.95 * self._score + 0.05 * self.main_ingredient_score()
return self._score return self._score
@ -1418,17 +1461,19 @@ class Tree(object):
# ## Population # ## Population
class Population(object): class Population(object):
def __init__(self, start_ingredients, main_ingredients, n_population = 50, min_additional=0, max_additional=15): def __init__(self, start_ingredients, main_ingredients, n_population = 50, min_additional=0, max_additional=15, mutations=3):
self.population = [] self.population = []
for i in tqdm(range(n_population), desc="build initial population"): for i in tqdm(range(n_population), desc="build initial population"):
self.population.append(Tree.from_ingredients(start_ingredients, main_ingredients, min_additional=min_additional, max_additional=max_additional)) self.population.append(Tree.from_ingredients(start_ingredients, main_ingredients, min_additional=min_additional, max_additional=max_additional))
self._n = n_population self._n = n_population
self._n_mutations = mutations
def mutate(self): def mutate(self):
for tree in self.population.copy(): for tree in self.population.copy():
t_clone = tree.copy() t_clone = tree.copy()
for i in range(self._n_mutations):
t_clone.mutate() t_clone.mutate()
t_clone.mutate() #t_clone.mutate()
#t_clone.mutate() #t_clone.mutate()
self.population.append(t_clone) self.population.append(t_clone)
@ -1457,6 +1502,7 @@ class Population(object):
self.population = np.array(self.population)[sorted_indices[:n]].tolist() self.population = np.array(self.population)[sorted_indices[:n]].tolist()
def run(self, n=50): def run(self, n=50):
avg_scores = []
for i in tqdm(range(n), desc="run evolutionary cycles"): for i in tqdm(range(n), desc="run evolutionary cycles"):
self.mutate() self.mutate()
#self.mutate() #self.mutate()
@ -1465,7 +1511,9 @@ class Population(object):
self.pairwise_competition() self.pairwise_competition()
#self.collect_scores() #self.collect_scores()
#self.hold_best(self._n) #self.hold_best(self._n)
scores = [t.score() for t in self.population]
avg_scores.append(scores)
return avg_scores
def plot_population(self, n_best=10): def plot_population(self, n_best=10):

View File

@ -0,0 +1,77 @@
groups = {
'heat':'heat',
'cook':'heat',
'bake':'heat',
'grill':'heat',
'melt':'heat',
'blend':None,
'beat':'prepare',
'spread':None,
'cool':'cool',
'brown':'heat',
'cut':'prepare',
'chill':'cool',
'drain':None,
'boil':'heat',
'simmer':'heat',
'pour':None,
'freeze':'cool',
'saute':'heat',
'rinse':'prepare',
'warm':'heat',
'wash':'prepare',
'knead':'prepare',
'peel':'prepare',
'parboil':'heat',
'break':'prepare',
'broil':'heat',
'scorch':'heat',
'skim':None,
'fry':'heat',
'refrigerate':'cool',
'burn':'heat',
'thicken':None,
'grate':'prepare',
'brush':'prepare',
'open':'prepare',
'crack':'prepare',
'poach':'heat',
'slice':'prepare',
'whisk':None,
'dice':'prepare',
'marinate':None,
'whip':None,
'sour':None,
'soak':None,
'steam':'heat',
'chop':'prepare',
'mince':None,
'mash':'prepare',
'squeeze':'prepare',
'wipe':'prepare',
'thaw':'prepare',
'curdle':'heat',
'sweeten':None,
'baste':None,
'carve':None,
'grind':'prepare',
'debone':'prepare',
'steep':None,
'clarify':None,
'macerate':'prepare',
'crumple':'prepare',
'braise':'heat',
'gut':None,
'bury':None,
'spread':None,
'place':None
}
inverse_groups = {}
for g in set(groups.values()):
if g is not None:
inverse_groups[g] = []
for a,g in groups.items():
if g is not None:
inverse_groups[g].append(a)

View File

@ -9,7 +9,7 @@
}, },
{ {
"cell_type": "code", "cell_type": "code",
"execution_count": null, "execution_count": 1,
"metadata": {}, "metadata": {},
"outputs": [], "outputs": [],
"source": [ "source": [
@ -91,7 +91,7 @@
"outputs": [], "outputs": [],
"source": [ "source": [
"groups = {\n", "groups = {\n",
" 'place':None,\n", " #'place':None,\n",
" 'heat':'heat',\n", " 'heat':'heat',\n",
" 'cook':'heat',\n", " 'cook':'heat',\n",
" 'bake':'heat',\n", " 'bake':'heat',\n",
@ -99,7 +99,6 @@
" 'melt':'heat',\n", " 'melt':'heat',\n",
" 'blend':None,\n", " 'blend':None,\n",
" 'beat':'prepare',\n", " 'beat':'prepare',\n",
" 'spread':None,\n",
" 'cool':'cool',\n", " 'cool':'cool',\n",
" 'brown':'heat',\n", " 'brown':'heat',\n",
" 'cut':'prepare',\n", " 'cut':'prepare',\n",
@ -152,6 +151,7 @@
" 'steep':None,\n", " 'steep':None,\n",
" 'clarify':None,\n", " 'clarify':None,\n",
" 'macerate':'prepare',\n", " 'macerate':'prepare',\n",
" #'spread':None,\n",
" 'crumple':'prepare',\n", " 'crumple':'prepare',\n",
" 'braise':'heat',\n", " 'braise':'heat',\n",
" 'gut':None,\n", " 'gut':None,\n",
@ -187,22 +187,26 @@
{ {
"data": { "data": {
"application/vnd.jupyter.widget-view+json": { "application/vnd.jupyter.widget-view+json": {
"model_id": "6b079a15f1b94d9e9ebce8ad6eb82058", "model_id": "77d9643f1116425eb40c8664edca0bf9",
"version_major": 2, "version_major": 2,
"version_minor": 0 "version_minor": 0
}, },
"text/plain": [ "text/plain": [
"HBox(children=(FloatProgress(value=0.0, max=527544.0), HTML(value='')))" "HBox(children=(FloatProgress(value=0.0, max=467050.0), HTML(value='')))"
] ]
}, },
"metadata": {}, "metadata": {},
"output_type": "display_data" "output_type": "display_data"
}, },
{ {
"name": "stdout", "ename": "KeyError",
"output_type": "stream", "evalue": "'spread'",
"text": [ "output_type": "error",
"\n" "traceback": [
"\u001b[0;31m---------------------------------------------------------------------------\u001b[0m",
"\u001b[0;31mKeyError\u001b[0m Traceback (most recent call last)",
"\u001b[0;32m<ipython-input-6-8156ba150c10>\u001b[0m in \u001b[0;36m<module>\u001b[0;34m\u001b[0m\n\u001b[1;32m 9\u001b[0m \u001b[0mgrouped_ing\u001b[0m \u001b[0;34m=\u001b[0m \u001b[0mIngredient\u001b[0m\u001b[0;34m(\u001b[0m\u001b[0ming\u001b[0m\u001b[0;34m.\u001b[0m\u001b[0m_base_ingredient\u001b[0m\u001b[0;34m)\u001b[0m\u001b[0;34m\u001b[0m\u001b[0;34m\u001b[0m\u001b[0m\n\u001b[1;32m 10\u001b[0m \u001b[0;32mfor\u001b[0m \u001b[0ma\u001b[0m \u001b[0;32min\u001b[0m \u001b[0ming\u001b[0m\u001b[0;34m.\u001b[0m\u001b[0m_action_set\u001b[0m\u001b[0;34m:\u001b[0m\u001b[0;34m\u001b[0m\u001b[0;34m\u001b[0m\u001b[0m\n\u001b[0;32m---> 11\u001b[0;31m \u001b[0mgrouped_ing\u001b[0m\u001b[0;34m.\u001b[0m\u001b[0mapply_action\u001b[0m\u001b[0;34m(\u001b[0m\u001b[0mgroups\u001b[0m\u001b[0;34m[\u001b[0m\u001b[0ma\u001b[0m\u001b[0;34m]\u001b[0m\u001b[0;34m)\u001b[0m\u001b[0;34m\u001b[0m\u001b[0;34m\u001b[0m\u001b[0m\n\u001b[0m\u001b[1;32m 12\u001b[0m \u001b[0;34m\u001b[0m\u001b[0m\n\u001b[1;32m 13\u001b[0m \u001b[0mgrouped_act\u001b[0m \u001b[0;34m=\u001b[0m \u001b[0mgroups\u001b[0m\u001b[0;34m[\u001b[0m\u001b[0mact\u001b[0m\u001b[0;34m]\u001b[0m\u001b[0;34m\u001b[0m\u001b[0;34m\u001b[0m\u001b[0m\n",
"\u001b[0;31mKeyError\u001b[0m: 'spread'"
] ]
} }
], ],
@ -227,31 +231,9 @@
}, },
{ {
"cell_type": "code", "cell_type": "code",
"execution_count": 7, "execution_count": null,
"metadata": {}, "metadata": {},
"outputs": [ "outputs": [],
{
"data": {
"application/vnd.jupyter.widget-view+json": {
"model_id": "b5b6c8ff52d1407495ef7fcd3ff409a8",
"version_major": 2,
"version_minor": 0
},
"text/plain": [
"HBox(children=(FloatProgress(value=0.0, max=2123892.0), HTML(value='')))"
]
},
"metadata": {},
"output_type": "display_data"
},
{
"name": "stdout",
"output_type": "stream",
"text": [
"\n"
]
}
],
"source": [ "source": [
"c = m_mix.get_csr()\n", "c = m_mix.get_csr()\n",
"\n", "\n",

File diff suppressed because it is too large Load Diff

View File

@ -75,7 +75,7 @@
{ {
"data": { "data": {
"text/plain": [ "text/plain": [
"<db.database_connection.DatabaseConnection at 0x7fbc4c131510>" "<db.database_connection.DatabaseConnection at 0x7f3635212850>"
] ]
}, },
"execution_count": 2, "execution_count": 2,
@ -101,8 +101,8 @@
"name": "stdout", "name": "stdout",
"output_type": "stream", "output_type": "stream",
"text": [ "text": [
"CPU times: user 8.68 s, sys: 778 ms, total: 9.46 s\n", "CPU times: user 8.52 s, sys: 719 ms, total: 9.24 s\n",
"Wall time: 12.5 s\n" "Wall time: 9.4 s\n"
] ]
} }
], ],
@ -187,7 +187,7 @@
{ {
"data": { "data": {
"application/vnd.jupyter.widget-view+json": { "application/vnd.jupyter.widget-view+json": {
"model_id": "70396063ce4140b48105751d0ece88c9", "model_id": "fa6557a61875425495f90a61f88115af",
"version_major": 2, "version_major": 2,
"version_minor": 0 "version_minor": 0
}, },
@ -202,9 +202,15 @@
"name": "stdout", "name": "stdout",
"output_type": "stream", "output_type": "stream",
"text": [ "text": [
"warning: recipe 0a14762efd has no ingredient! skipping it\n", "warning: recipe 8be34a1b83 has no ingredient! skipping it\n",
"warning: recipe 361b00dc50 has no ingredient! skipping it\n", "warning: recipe 5f02077e4c has no ingredient! skipping it\n",
"warning: recipe e3b081a317 has no ingredient! skipping it\n", "warning: recipe e5c317b3f1 has no ingredient! skipping it\n",
"warning: recipe 56016a1985 has no ingredient! skipping it\n",
"warning: recipe eb77bd6edc has no ingredient! skipping it\n",
"warning: recipe 5ce8c2cedd has no ingredient! skipping it\n",
"warning: recipe d7a9aaba3a has no ingredient! skipping it\n",
"warning: recipe 5d99d73716 has no ingredient! skipping it\n",
"warning: recipe 5a8462b13f has no ingredient! skipping it\n",
"an error occured : 'NoneType' object has no attribute 'lower'\n" "an error occured : 'NoneType' object has no attribute 'lower'\n"
] ]
}, },
@ -235,30 +241,83 @@
"name": "stdout", "name": "stdout",
"output_type": "stream", "output_type": "stream",
"text": [ "text": [
"warning: recipe 80dd4d10ab has no ingredient! skipping it\n", "warning: recipe 99ab771181 has no ingredient! skipping it\n",
"warning: recipe ac1ab87418 has no ingredient! skipping it\n", "warning: recipe de79b67e1a has no ingredient! skipping it\n",
"warning: recipe fa5b33cadc has no ingredient! skipping it\n", "warning: recipe ebc64e182c has no ingredient! skipping it\n",
"warning: recipe 80eb0385d0 has no ingredient! skipping it\n", "warning: recipe 7358870155 has no ingredient! skipping it\n",
"warning: recipe 2dfb05c466 has no ingredient! skipping it\n", "warning: recipe 3e06b9bc57 has no ingredient! skipping it\n",
"warning: recipe 7b372faa16 has no ingredient! skipping it\n", "warning: recipe 7c67cd9da7 has no ingredient! skipping it\n",
"warning: recipe f53fe916f2 has no ingredient! skipping it\n", "warning: recipe 1e5911a066 has no ingredient! skipping it\n",
"warning: recipe b4ff30e1de has no ingredient! skipping it\n", "an error occured : 'NoneType' object is not subscriptable\n"
"warning: recipe cf2300c7ac has no ingredient! skipping it\n", ]
"warning: recipe d09e7e82f9 has no ingredient! skipping it\n", },
"warning: recipe edbdc9c52f has no ingredient! skipping it\n", {
"warning: recipe 4db0dadfce has no ingredient! skipping it\n", "name": "stderr",
"warning: recipe d9933872c6 has no ingredient! skipping it\n", "output_type": "stream",
"warning: recipe 37af7ba84f has no ingredient! skipping it\n", "text": [
"warning: recipe cfc02f6bd7 has no ingredient! skipping it\n", "Traceback (most recent call last):\n",
"warning: recipe fac985c58f has no ingredient! skipping it\n", " File \"<timed exec>\", line 4, in <module>\n",
"warning: recipe 91308ac1b2 has no ingredient! skipping it\n", " File \"/home/jonas/Dokumente/gitRepos/master_thesis/RecipeAnalysis/Recipe.py\", line 888, in __init__\n",
"warning: recipe d3ff2bf3f9 has no ingredient! skipping it\n", " self.annotate_sentences()\n",
"warning: recipe ed9a0d0d51 has no ingredient! skipping it\n", " File \"/home/jonas/Dokumente/gitRepos/master_thesis/RecipeAnalysis/Recipe.py\", line 981, in annotate_sentences\n",
"warning: recipe 52f19fe220 has no ingredient! skipping it\n", " self._annotate_sentences(self._sentences, self.predict_labels())\n",
"warning: recipe 6fa7839c14 has no ingredient! skipping it\n", " File \"/home/jonas/Dokumente/gitRepos/master_thesis/RecipeAnalysis/Recipe.py\", line 933, in predict_labels\n",
" features = [sent2features(sent) for sent in self._sentences]\n",
" File \"/home/jonas/Dokumente/gitRepos/master_thesis/RecipeAnalysis/Recipe.py\", line 933, in <listcomp>\n",
" features = [sent2features(sent) for sent in self._sentences]\n",
" File \"../Tagging/crf_data_generator.py\", line 87, in sent2features\n",
" return [word2features(sent, i) for i in range(len(sent))]\n",
" File \"../Tagging/crf_data_generator.py\", line 87, in <listcomp>\n",
" return [word2features(sent, i) for i in range(len(sent))]\n",
" File \"../Tagging/crf_data_generator.py\", line 19, in word2features\n",
" 'word[-3:]=' + word[-3:],\n",
"TypeError: 'NoneType' object is not subscriptable\n"
]
},
{
"name": "stdout",
"output_type": "stream",
"text": [
"warning: recipe 56016a1985 has no ingredient! skipping it\n",
"warning: recipe 1d14e148c9 has no ingredient! skipping it\n",
"warning: recipe f96375e11c has no ingredient! skipping it\n",
"warning: recipe 026e9af79d has no ingredient! skipping it\n",
"warning: recipe c884f5d8a0 has no ingredient! skipping it\n",
"warning: recipe 76b02fee35 has no ingredient! skipping it\n",
"an error occured : 'NoneType' object has no attribute 'lower'\n"
]
},
{
"name": "stderr",
"output_type": "stream",
"text": [
"Traceback (most recent call last):\n",
" File \"<timed exec>\", line 4, in <module>\n",
" File \"/home/jonas/Dokumente/gitRepos/master_thesis/RecipeAnalysis/Recipe.py\", line 888, in __init__\n",
" self.annotate_sentences()\n",
" File \"/home/jonas/Dokumente/gitRepos/master_thesis/RecipeAnalysis/Recipe.py\", line 981, in annotate_sentences\n",
" self._annotate_sentences(self._sentences, self.predict_labels())\n",
" File \"/home/jonas/Dokumente/gitRepos/master_thesis/RecipeAnalysis/Recipe.py\", line 933, in predict_labels\n",
" features = [sent2features(sent) for sent in self._sentences]\n",
" File \"/home/jonas/Dokumente/gitRepos/master_thesis/RecipeAnalysis/Recipe.py\", line 933, in <listcomp>\n",
" features = [sent2features(sent) for sent in self._sentences]\n",
" File \"../Tagging/crf_data_generator.py\", line 87, in sent2features\n",
" return [word2features(sent, i) for i in range(len(sent))]\n",
" File \"../Tagging/crf_data_generator.py\", line 87, in <listcomp>\n",
" return [word2features(sent, i) for i in range(len(sent))]\n",
" File \"../Tagging/crf_data_generator.py\", line 54, in word2features\n",
" '+1:word.lower=' + word1.lower(),\n",
"AttributeError: 'NoneType' object has no attribute 'lower'\n"
]
},
{
"name": "stdout",
"output_type": "stream",
"text": [
"warning: recipe 2fa5b920f4 has no ingredient! skipping it\n",
"\n", "\n",
"CPU times: user 1h 57min 25s, sys: 36.8 s, total: 1h 58min 2s\n", "CPU times: user 2h 2min 39s, sys: 43.4 s, total: 2h 3min 23s\n",
"Wall time: 1h 58min 41s\n" "Wall time: 2h 4min 37s\n"
] ]
} }
], ],
@ -282,7 +341,7 @@
}, },
{ {
"cell_type": "code", "cell_type": "code",
"execution_count": 8, "execution_count": 10,
"metadata": {}, "metadata": {},
"outputs": [ "outputs": [
{ {
@ -291,7 +350,7 @@
"99999" "99999"
] ]
}, },
"execution_count": 8, "execution_count": 10,
"metadata": {}, "metadata": {},
"output_type": "execute_result" "output_type": "execute_result"
} }
@ -302,7 +361,7 @@
}, },
{ {
"cell_type": "code", "cell_type": "code",
"execution_count": 9, "execution_count": 11,
"metadata": {}, "metadata": {},
"outputs": [], "outputs": [],
"source": [ "source": [
@ -318,7 +377,7 @@
}, },
{ {
"cell_type": "code", "cell_type": "code",
"execution_count": 10, "execution_count": 12,
"metadata": {}, "metadata": {},
"outputs": [], "outputs": [],
"source": [ "source": [
@ -330,19 +389,19 @@
}, },
{ {
"cell_type": "code", "cell_type": "code",
"execution_count": 11, "execution_count": 13,
"metadata": {}, "metadata": {},
"outputs": [], "outputs": [],
"source": [ "source": [
"m_act.apply_threshold(5)\n", "m_act.apply_threshold(10)\n",
"m_mix.apply_threshold(5)\n", "m_mix.apply_threshold(10)\n",
"m_base_act.apply_threshold(10)\n", "m_base_act.apply_threshold(20)\n",
"m_base_mix.apply_threshold(10)" "m_base_mix.apply_threshold(20)"
] ]
}, },
{ {
"cell_type": "code", "cell_type": "code",
"execution_count": 12, "execution_count": 14,
"metadata": {}, "metadata": {},
"outputs": [], "outputs": [],
"source": [ "source": [
@ -354,7 +413,7 @@
}, },
{ {
"cell_type": "code", "cell_type": "code",
"execution_count": 13, "execution_count": 15,
"metadata": {}, "metadata": {},
"outputs": [], "outputs": [],
"source": [ "source": [
@ -373,7 +432,7 @@
}, },
{ {
"cell_type": "code", "cell_type": "code",
"execution_count": 14, "execution_count": 16,
"metadata": {}, "metadata": {},
"outputs": [], "outputs": [],
"source": [ "source": [
@ -385,17 +444,17 @@
}, },
{ {
"cell_type": "code", "cell_type": "code",
"execution_count": 15, "execution_count": 17,
"metadata": {}, "metadata": {},
"outputs": [ "outputs": [
{ {
"name": "stdout", "name": "stdout",
"output_type": "stream", "output_type": "stream",
"text": [ "text": [
"(65, 272623) (293753, 293753)\n", "(64, 237792) (266772, 266772)\n",
"30381 42885\n", "13170 17041\n",
"(65, 11807) (13603, 13603)\n", "(64, 11455) (13528, 13528)\n",
"10725 19775\n" "6083 10775\n"
] ]
} }
], ],
@ -408,15 +467,15 @@
}, },
{ {
"cell_type": "code", "cell_type": "code",
"execution_count": 16, "execution_count": 18,
"metadata": {}, "metadata": {},
"outputs": [ "outputs": [
{ {
"name": "stdout", "name": "stdout",
"output_type": "stream", "output_type": "stream",
"text": [ "text": [
"(65, 272623) (293753, 293753)\n", "(64, 237792) (266772, 266772)\n",
"30381 42885\n" "13170 17041\n"
] ]
} }
], ],
@ -427,16 +486,16 @@
}, },
{ {
"cell_type": "code", "cell_type": "code",
"execution_count": 18, "execution_count": 19,
"metadata": {}, "metadata": {},
"outputs": [ "outputs": [
{ {
"data": { "data": {
"text/plain": [ "text/plain": [
"30381" "13170"
] ]
}, },
"execution_count": 18, "execution_count": 19,
"metadata": {}, "metadata": {},
"output_type": "execute_result" "output_type": "execute_result"
} }

View File

@ -289,7 +289,6 @@ old_cooking_verbs2 = ['arrange',
cooking_verbs = [ cooking_verbs = [
'add', 'add',
'adjust',
'arrange', 'arrange',
'bake', 'bake',
'baste', 'baste',
@ -299,7 +298,6 @@ cooking_verbs = [
'boil', 'boil',
'braise', 'braise',
'break', 'break',
'bread',
'broil', 'broil',
'brown', 'brown',
'brush', 'brush',
@ -322,7 +320,6 @@ cooking_verbs = [
'cut', 'cut',
'debone', 'debone',
'dice', 'dice',
'discard',
'drain', 'drain',
'dress', 'dress',
'fillet', 'fillet',
@ -349,10 +346,8 @@ cooking_verbs = [
'parboil', 'parboil',
'peel', 'peel',
'pickle', 'pickle',
'place',
'poach', 'poach',
'pour', 'pour',
'prepare',
'pull', 'pull',
'put', 'put',
'reduce', 'reduce',
@ -378,9 +373,6 @@ cooking_verbs = [
'soak', 'soak',
'sour', 'sour',
'spice', 'spice',
'spoon',
'spread',
'sprinkle',
'squeeze', 'squeeze',
'steam', 'steam',
'steep', 'steep',