Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Correction for old merge #27

Merged
merged 34 commits into from
Jan 8, 2024
Merged

Correction for old merge #27

merged 34 commits into from
Jan 8, 2024

Conversation

mari-ga
Copy link
Collaborator

@mari-ga mari-ga commented Nov 6, 2023

  • Deleted comments and wrongly saved characters from merging files in BFF
  • Added coded deleted during merging for Demuxem
  • Added code deleted from gmm-demux during merge
  • Added code deleted from summary_hash during merge
  • Added path to env for BFF in nextflow.config - as stated in last corrected version

Tested on multiple data completed

mari-ga and others added 2 commits December 19, 2023 15:30
Reverse Pull Request - adding 3 changes from original
Copy link
Member

@Zethson Zethson left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

  1. Please always leave a space after # comments
  2. Remove outcommented code

bin/demuxem.py Outdated Show resolved Hide resolved
bin/demuxem.py Outdated Show resolved Hide resolved
@@ -105,7 +104,8 @@ def hashsolo_summary(hashsolo_res, raw_adata, raw_mudata):
mudata.write("hash_summary/mudata/mudata_with_mudata_"+ os.path.basename(x)+".h5mu")

hashsolo_classi = obs_res[["most_likely_hypothesis"]]
hashsolo_classi.loc[:, "most_likely_hypothesis"] = hashsolo_classi["most_likely_hypothesis"].replace({0.0: "negative", 1.0: "singlet", 2.0: "doublet"})
#hashsolo_classi.loc[:, "most_likely_hypothesis"] = hashsolo_classi["most_likely_hypothesis"].replace({0.0: "negative", 1.0: "singlet", 2.0: "doublet"})
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Why is this commented out?

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I added a different way to do the same as in the commented line, because it was producing a warning from pandas.
Commeted line is now out

classification_dt["classification"] = classification_dt["assignment"].apply(lambda x: "doublet" if x else "singlet")
classification_dt.at[0, "classification"] = "negative"

##Inner function
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
##Inner function

classification_dt.at[0, "classification"] = "negative"

##Inner function
def classify_hash(row,number_hashes):
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Inner functions should be prefixed with _

@Zethson Zethson merged commit c4736af into theislab:main Jan 8, 2024
2 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants