conda env create -f environment.yml
conda activate tleaf
Generate edge embedder dataset:
python ./src/Synthetic/edge_dataset_generation.py --prop_size=3
python ./src/Synthetic/edge_dataset_generation.py --prop_size=6
Train edge embedder:
python ./src/Synthetic/edge_embedder_train.py --prop_size=3
python ./src/Synthetic/edge_embedder_train.py --prop_size=6
Generate meta embedder dataset:
python ./src/Synthetic/meta_dataset_generation.py --prop_size=3 --tree_size=10
python ./src/Synthetic/meta_dataset_generation.py --prop_size=3 --tree_size=20
python ./src/Synthetic/meta_dataset_generation.py --prop_size=6 --tree_size=20
Train meta embedder dataset:
python ./src/Synthetic/meta_embedder_train.py --replace --nodes_only --random_path_agg --dataset_name=3_10
python ./src/Synthetic/meta_embedder_train.py --replace --nodes_only --random_path_agg --dataset_name=3_20
python ./src/Synthetic/meta_embedder_train.py --replace --nodes_only --random_path_agg --dataset_name=6_20
Generate embedding data for DFA:
python ./src/Synthetic/visualization/embedding_data_generation.py --replace --nodes_only --random_path_agg --notonebyone --dataset_name=6_20
Generate embedding data for syntax tree:
python ./src/Synthetic/visualization/embedding_data_generation.py --replace --nodes_only --random_path_agg --syntax --notonebyone --dataset_name=6_20
Run TSNE and plot:
python ./src/Synthetic/visualization/tsne_plot.py
Download dataset from:\
Upzip and place it under:
./datasets/Action_Recognition/recipes/
Preprocess and build embedder dataset:
python ./src/Action_Recognition/preprocess/build_dataset_action_recognition.py
Train edge embedder:
python ./src/Action_Recognition/edge_embedder_train.py
Train meta embedder:
python ./src/Action_Recognition/meta_embedder_train.py --replace --nodes_only --random_path_agg
Train LSTM action recognition model:
Baseline:
python ./src/Action_Recognition/LSTM_train.py --memory_predictor
With checker loss:
python ./src/Action_Recognition/LSTM_train.py --memory_pr edictor --checker_loss
With embedder loss:
python ./src/Action_Recognition/LSTM_train.py --memory_predictor --embedder_loss
Train TCN action recognition model:
Baseline:
python ./src/Action_Recognition/TCN_train.py --memory_predictor
With checker loss:
python ./src/Action_Recognition/TCN_train.py --memory_predictor --checker_loss
With embedder loss:
python ./src/Action_Recognition/TCN_train.py --memory_predictor --embedder_loss
Visualize formula DFA graph:
python ./src/Action_Recognition/visualization/visualize_dfa.py
Node degree distribution:
python ./src/Action_Recognition/visualization/node_degree_distribution_plot.py
Get expert trajectories:
python ./src/Imitation_Cooking/algorithm/imitation_train.py --use-linear-lr-decay --use-proper-time-limits --save-expert
Generate cooking rules:
python ./src/Imitation_Cooking/env/generate_cooking_rules.py
Build embedder dataset from rules:
python ./src/Imitation_Cooking/embedder/build_dataset_cooking.py
Train edge embedder:
python ./src/Action_Recognition/edge_embedder_train.py --dataset_root=./datasets/Imitation_Cooking/ --dataset_name=/edge_embedder_dataset/ --model_save_path=./saved_models/Imitation_Cooking/edge_embedder/
Train meta embedder:
python ./src/Action_Recognition/meta_embedder_train.py --replace --nodes_only --random_path_agg --dataset_root=./datasets/Imitation_Cooking/ --dataset_name=/meta_embedder_dataset/ --edge_embedder_rootpath=./saved_models/Imitation_Cooking/edge_embedder/ --edge_embedder_name=edge_embedder_latest.pt --model_save_path=./saved_models/Imitation_Cooking/meta_embedder/
Baseline GAIL:
python ./src/Imitation_Cooking/algorithm/imitation_train.py --use-linear-lr-decay --use-proper-time-limits --gail
GAIL with checker loss:
python ./src/Imitation_Cooking/algorithm/imitation_train.py --use-linear-lr-decay --use-proper-time-limits --gail --checker-loss
GAIL with embedder loss:
python ./src/Imitation_Cooking/algorithm/imitation_train.py --use-linear-lr-decay --use-proper-time-limits --gail --embedder-loss