<SYSTEM_TASK:>
Solve the following problem using Python, implementing the functions described below, one line at a time
<END_TASK>
<USER_TASK:>
Description:
 def initialize_membership_matrix(gene_row_names, pathway_definitions):
 """Create the binary gene-to-pathway membership matrix that will be considered in the maximum impact estimation procedure. Parameters gene_row_names : set(str) The genes for which we want to assess pathway membership pathway_definitions : dict(str -> set(str)) Pathway definitions, pre-crosstalk-removal. A pathway (key) is defined by a set of genes (value). Returns numpy.array, shape = [n, k], the membership matrix """

    membership = []
    for pathway, full_definition in pathway_definitions.items():
        pathway_genes = list(full_definition & gene_row_names)
        membership.append(np.in1d(list(gene_row_names), pathway_genes))
    membership = np.array(membership).astype("float").T
    return membership