FIle Download Button on Event

I have a plot and a download button next to it. The plot requires some processing steps sensitive to the MultiSelect button. So after i filter using the MultiSelect button, I expect the plot to change along with the FileDownload button’s data (that will be dumped as an xlsx file). In order to do that, I bind the process_function. However, given the DataFrame is big and the processing steps are expensive. I don’t want to bind the method anymore, but rather have it run on-demand (per event/click).

Code snippet:

def process_func(df, filter1):
   ...
  return processed_df

filter_m = pn.widgets.MultiSelect(...)
excel_button = pn.widgets.FileDownload(file=None,  callback = pn.bind(process_func, original_df, filter1))

Can you clarify? Not sure I follow.