Loading bolzano-address-trees/download_prepare.sh +3 −3 Original line number Diff line number Diff line Loading @@ -23,11 +23,11 @@ cd original_data # prepare data for file L.trees # convert file into UTF-8 format | remove header | remove IDs | sort by number of nodes (equivalent to number of "{") iconv -f ISO-8859-1 -t "UTF-8" L.trees | tail -n +14 | sed 's/.*://' | awk '{print gsub("{","{"), $0}' | sort -n | cut -d' ' -f2- > ../L_preprocessed.bracket iconv -f ISO-8859-1 -t "UTF-8" L.trees | tail -n +14 | sed 's/.*://' | awk '{print gsub("{","{"), $0}' | sort -n | cut -d' ' -f2- > ../L_preprocessed.txt # prepare data for file R.trees # convert file into UTF-8 format | remove header | remove IDs | sort by number of nodes (equivalent to number of "{") iconv -f ISO-8859-1 -t "UTF-8" R.trees | tail -n +14 | sed 's/.*://' | awk '{print gsub("{","{"), $0}' | sort -n | cut -d' ' -f2- > ../R_preprocessed.bracket iconv -f ISO-8859-1 -t "UTF-8" R.trees | tail -n +14 | sed 's/.*://' | awk '{print gsub("{","{"), $0}' | sort -n | cut -d' ' -f2- > ../R_preprocessed.txt # prepare dataset with a single label # | remove non-bracket chars. | add single dummy label 'o' > save to file Loading sentiment/download_prepare.sh +2 −2 Original line number Diff line number Diff line Loading @@ -23,7 +23,7 @@ cd trees # prepare data for file L.trees # convert dev.txt and train.txt into UTF-8 format | replace ( by { | replace ) by } | remove whitespace before '{' | sort by number of nodes (equivalent to number of "{") iconv -f ISO-8859-1 -t "UTF-8" dev.txt train.txt | sed -e 's/(/{/g' | sed -e 's/)/}/g' | sed -E 's/[[:space:]]([{])/\1/g' | awk '{print gsub("{","{"), $0}' | sort -n | cut -d' ' -f2- > ../sentiment.bracket iconv -f ISO-8859-1 -t "UTF-8" dev.txt train.txt | sed -e 's/(/{/g' | sed -e 's/)/}/g' | sed -E 's/[[:space:]]([{])/\1/g' | awk '{print gsub("{","{"), $0}' | sort -n | cut -d' ' -f2- > ../sentiment_sorted.bracket # go back to the folder cd .. Loading
bolzano-address-trees/download_prepare.sh +3 −3 Original line number Diff line number Diff line Loading @@ -23,11 +23,11 @@ cd original_data # prepare data for file L.trees # convert file into UTF-8 format | remove header | remove IDs | sort by number of nodes (equivalent to number of "{") iconv -f ISO-8859-1 -t "UTF-8" L.trees | tail -n +14 | sed 's/.*://' | awk '{print gsub("{","{"), $0}' | sort -n | cut -d' ' -f2- > ../L_preprocessed.bracket iconv -f ISO-8859-1 -t "UTF-8" L.trees | tail -n +14 | sed 's/.*://' | awk '{print gsub("{","{"), $0}' | sort -n | cut -d' ' -f2- > ../L_preprocessed.txt # prepare data for file R.trees # convert file into UTF-8 format | remove header | remove IDs | sort by number of nodes (equivalent to number of "{") iconv -f ISO-8859-1 -t "UTF-8" R.trees | tail -n +14 | sed 's/.*://' | awk '{print gsub("{","{"), $0}' | sort -n | cut -d' ' -f2- > ../R_preprocessed.bracket iconv -f ISO-8859-1 -t "UTF-8" R.trees | tail -n +14 | sed 's/.*://' | awk '{print gsub("{","{"), $0}' | sort -n | cut -d' ' -f2- > ../R_preprocessed.txt # prepare dataset with a single label # | remove non-bracket chars. | add single dummy label 'o' > save to file Loading
sentiment/download_prepare.sh +2 −2 Original line number Diff line number Diff line Loading @@ -23,7 +23,7 @@ cd trees # prepare data for file L.trees # convert dev.txt and train.txt into UTF-8 format | replace ( by { | replace ) by } | remove whitespace before '{' | sort by number of nodes (equivalent to number of "{") iconv -f ISO-8859-1 -t "UTF-8" dev.txt train.txt | sed -e 's/(/{/g' | sed -e 's/)/}/g' | sed -E 's/[[:space:]]([{])/\1/g' | awk '{print gsub("{","{"), $0}' | sort -n | cut -d' ' -f2- > ../sentiment.bracket iconv -f ISO-8859-1 -t "UTF-8" dev.txt train.txt | sed -e 's/(/{/g' | sed -e 's/)/}/g' | sed -E 's/[[:space:]]([{])/\1/g' | awk '{print gsub("{","{"), $0}' | sort -n | cut -d' ' -f2- > ../sentiment_sorted.bracket # go back to the folder cd ..