def _frequency_generated_trips_rows(self, gtfs_soure_path, return_df_freq=False):
df_freq = source_csv_to_pandas(gtfs_soure_path, '<STR_LIT>')<EOL>df_trips = source_csv_to_pandas(gtfs_soure_path, "<STR_LIT>")<EOL>df_freq['<STR_LIT>'] = df_freq.apply(lambda row: len(range(str_time_to_day_seconds(row['<STR_LIT>']),<EOL>str_time_to_day_seconds(row['<STR_LIT>']),<EOL>row['<STR_LIT>'])), axis=<NUM_LIT:1>)<EOL>df_trips_freq = pd.merge(df_freq, df_trips, how='<STR_LIT>', on='<STR_LIT>')<EOL>n_freq_generated_trips = int(df_trips_freq['<STR_LIT>'].fillna(<NUM_LIT:1>).sum(axis=<NUM_LIT:0>))<EOL>if return_df_freq:<EOL><INDENT>return df_trips_freq<EOL><DEDENT>else:<EOL><INDENT>return n_freq_generated_trips<EOL><DEDENT>
This function calculates the equivalent rowcounts for trips when
taking into account the generated rows in the gtfs object
Parameters
----------
gtfs_soure_path: path to the source file
param txt: txt file in question
:return: sum of all trips