Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/** | |
* Crie uma nova pasta no Drive e mude PARENT_FOLDER_ID para o ID da nova pasta. | |
* | |
* Cada resposta do formulário terá uma subpasta específica dentro de PARENT_FOLDER_ID, | |
* onde serão salvos todos os arquivos de upload daquela resposta. | |
* | |
* O nome de cada subpasta será definido como a resposta de alguma das perguntas do formulário. | |
* Mude o valor da variável FOLDER_NAME para o título da pergunta desejada, e.g.: | |
* FOLDER_NAME = 'EMAIL'; dessa forma cada pasta será nomeada com o e-mail do respondente. | |
* |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
"""Extract and export the protein binding pocket. | |
Use `python cut_pocket.py -h` for info. | |
""" | |
from typing import List, TextIO | |
import argparse | |
import numpy as np # python3 -m pip install numpy | |
def configure_argparser() -> argparse.ArgumentParser: |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import numpy as np | |
def generate_dataset(N: int, p1: list, p2: list, seed: int = 42): | |
"""Generate a random dataset with size N from p1 and p2.""" | |
p1_ = np.tile(p1, reps=int(N // 2)).reshape(N // 2, 2) | |
p2_ = np.tile(p2, reps=int(N // 2)).reshape(N // 2, 2) | |
rng = np.random.default_rng(seed) # random number generator |