<commit_before>#!/usr/bin/env bash

DIR=$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )

# Temporarily setting the internal field seperator (IFS) to the newline character.
IFS=$'\n';

DATASET_DIRECTORY=$1

bash $DIR/create_rosbag_dataset.sh $DATASET_DIRECTORY
if ! [ $? -eq 0 ]; then
  echo "Error calling script $DIR/create_rosbag_dataset.sh $DATASET_DIRECTORY"
  exit 1
fi

bash $DIR/create_rosbag_logs.sh $DATASET_DIRECTORY
if ! [ $? -eq 0 ]; then
  echo "Error calling script $DIR/create_rosbag_logs.sh $DATASET_DIRECTORY"
  exit 1
fi

bash $DIR/create_rosbag_stats_crop.sh $DATASET_DIRECTORY $DATASET_DIRECTORY
if ! [ $? -eq 0 ]; then
  echo "Error calling script $DIR/create_rosbag_cropped.sh $DATASET_DIRECTORY"
  exit 1<commit_msg>Fixed issue where bags were being cropped twice<commit_after>#!/usr/bin/env bash

DIR=$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )

# Temporarily setting the internal field seperator (IFS) to the newline character.
IFS=$'\n';

DATASET_DIRECTORY=$1

bash $DIR/create_rosbag_dataset.sh $DATASET_DIRECTORY
if ! [ $? -eq 0 ]; then
  echo "Error calling script $DIR/create_rosbag_dataset.sh $DATASET_DIRECTORY"
  exit 1
fi

bash $DIR/create_rosbag_logs.sh $DATASET_DIRECTORY
if ! [ $? -eq 0 ]; then
  echo "Error calling script $DIR/create_rosbag_logs.sh $DATASET_DIRECTORY"
  exit 1
{'fraction_non_alphanumeric': 0.12235649546827794, 'fraction_numerical': 0.010574018126888218, 'mean_word_length': 4.995475113122172, 'pattern_counts': {'":': 0, '<': 3, '<?xml version=': 0, '>': 3, '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}}
{'dir': 'git-commits-cleaned', 'id': '3427409', 'n_tokens_mistral': 502, 'n_tokens_neox': 491, 'n_words': 125}