@tom Thank you for your patience, sir. Would you please clarify the step of “combining them”?
I indeed checked the for-loop example in the link which accumulates result in each for-loop iteration.
However, here, each channel’s result is final, and excludes each other. When using multitask model, it expose argument for each individual channel. For example, passing in channel “games” will produce a final score for itself (no need to combine with other channels), while passing in channel “fashion” will produce another final score for itself.
What shall be returned in loop_in_traced_fn? Returning any channel’s result  will discard other channels’.
@torch.jit.script
def loop_in_traced_fn(premise, premise_length, hypotheses, hypotheses_length, channel_list):
	for channel in channel_list:
		result = model(premise, premise_length, hypotheses, hypotheses_length, channel)
		#what shall be returned here? since each channel's result exclude each other. 

#channel_list = ["games", "fashion", "news", "food"]
traced = torch.jit.trace(loop_in_traced_fn, premise, premise_length, hypotheses, hypotheses_length, channel_list)