aertslab / scenicplus

SCENIC+ is a python package to build gene regulatory networks (GRNs) using combined or separate single-cell gene expression (scRNA-seq) and single-cell chromatin accessibility (scATAC-seq) data.
Other
173 stars 28 forks source link

run_cgs_models_mallet not working #431

Open uqnsarke opened 1 month ago

uqnsarke commented 1 month ago

model_results = run_cgs_models_mallet( cistopic_obj=cistopic_obj, n_topics=n_topics, n_cpu=n_cpu, n_iter=n_iter, random_state=random_state, alpha=alpha, alpha_by_topic=alpha_by_topic, eta=eta, eta_by_topic=eta_by_topic, tmp_path=tmp_path, mallet_path=mallet_path, save_path=out_dir )...not working with all samples , output is showing only one object info

SeppeDeWinter commented 1 month ago

Hi @uqnsarke

Thanks for opening a bug report. Can you please elaborate? From this information it is very difficult to figure out what might be going wrong.

Best,

Seppe

uqnsarke commented 1 month ago

Hi Seppe Thanks for responding. My question is, to run "run_cgs_models_mallet", do I need to use individual objects or a merged object?? Because my merged object isnt working. If I run with individual objects and merge them after cistopic_obj.add_LDA_model(model) step, then find_clusters( cistopicobj, target = 'cell', k = 10, res = [0.6, 1.2, 3], prefix = 'pycisTopic', scale = True, split_pattern = '-' ) doesn't work. Its showing following error: "ValueError: Input X contains NaN."

But my data doesn't have NaN as you can see from below:: After filtering cell names and NaN values, number of cell names: 76219 After filtering cell names and NaN values, cell data shape: (76219, 32)

uqnsarke commented 1 month ago

Hi Seppe Thanks for responding. My question is, to run "run_cgs_models_mallet", do I need to use individual objects or a merged object?? Because my merged object isnt working. If I run with individual objects and merge them after cistopic_obj.add_LDA_model(model) step, then find_clusters( cistopicobj, target = 'cell', k = 10, res = [0.6, 1.2, 3], prefix = 'pycisTopic', scale = True, split_pattern = '-' ) doesn't work. Its showing follwoing error: "ValueError: Input X contains NaN."

But my data doesn't have NaN as you can see from below:: After filtering cell names and NaN values, number of cell names: 76219 After filtering cell names and NaN values, cell data shape: (76219, 32)

SeppeDeWinter commented 4 weeks ago

Hi @uqnsarke

You should run topic modelling after merging your objects.

What error are you getting with the merged object?

Best,

Seppe