Skip to content

Instantly share code, notes, and snippets.

View NatureGeorge's full-sized avatar
🌗
Still have lots more to work on.

Zefeng Zhu NatureGeorge

🌗
Still have lots more to work on.
View GitHub Profile
@NatureGeorge
NatureGeorge / dagdeps.py
Last active October 26, 2022 11:51
Example for generating an arbitrary DAG as a dependency map (single machine, async version)
# @Created Date: 2020-05-17 07:56:52 pm
# @Filename: dagdeps.py
# @Email: 1730416009@stu.suda.edu.cn
# @Author: ZeFeng Zhu
# @Last Modified: 2020-05-17 08:32:11 pm
"""
Example for generating an arbitrary DAG as a dependency map (single machine, async version).
Modification on MinRK's code
@NatureGeorge
NatureGeorge / dagdeps_unsync.py
Last active September 21, 2020 04:16
Example for generating an arbitrary DAG as a dependency map (single machine, unsync version)
# @Created Date: 2020-08-04 22:16:21 pm
# @Filename: dagdeps_unsync.py
# @Email: 1730416009@stu.suda.edu.cn
# @Author: ZeFeng Zhu
# @Last Modified: 2020-08-05 15:22:07 pm
"""
Example for generating an arbitrary DAG as a dependency map (single machine, unsync version).
Modification on MinRK's code
Reference
@NatureGeorge
NatureGeorge / 2020-08-13-note-of-async-unsync.md
Last active August 15, 2020 09:42
Note of `async` and `unsync` programming in Python
title author date categories tags
Note of async and unsync programming in Python
Zefeng Zhu
2020-08-13 17:40:00 +0800
Notes
Programming
python
asynchronous-programming

About Hashable function

# Copyright (C) 2002, Thomas Hamelryck (thamelry@binf.ku.dk)
#
# This file is part of the Biopython distribution and governed by your
# choice of the "Biopython License Agreement" or the "BSD 3-Clause License".
# Please see the LICENSE file that should have been included as part of this
# package.
"""Turn an mmCIF file into a dictionary."""
from IPython.core.magic import register_line_magic
@register_line_magic
def styledf(line):
"""Style Pandas DataFrame
Usage:
>>> %styledf pandas.DataFrame
@NatureGeorge
NatureGeorge / rp.ipynb
Last active May 11, 2024 10:06
Jupyter Notebook Demo for calculating phi-psi info of a PDB file via Biopython
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.

PDBe-KB

Note: this gist is heavily based on materials provided by organizers of the Mining PDBe and PDBe-KB Using a Graph Database workshop.

Note: this gist is foke from PawelSzczerbiak/pdbe-kb.md.

Why graph DB?

Graph DBs are much more useful for representing unstructured, sparse data and relationships than conventional relational DBs.

Graph is a structure that models pairwise relations between objects:

@NatureGeorge
NatureGeorge / PDBe_API_Issue.md
Last active September 5, 2020 12:48
📝Record for PDBe API Issue
title author date categories tags
Record for PDBe API Issues
Zefeng Zhu
2020-09-04 17:39:51 +0800
Notes
Research
pdbe

Basic Information

@NatureGeorge
NatureGeorge / graphviz_demo.md
Last active September 8, 2020 05:54
graphviz demo
```viz
digraph flowchart_4 {
    # rankdir=LR;
    fontname="Courier New";
    size="6,5"; ratio = fill;
    node [style="filled,setlinewidth(3)", color="#8383cc", fontname="Courier New", shape="Mrecord",fixedsize=true,width=2.5,fillcolor="#d9e7ee"];
    edge [color="0.635 0.707 0.707", fontname="Courier New"];
    label="从头预测与结构建模";
 # step1[label="数据准备"];
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.