GithubHelp home page GithubHelp logo

hiranumn / deepaccnet-tf Goto Github PK

View Code? Open in Web Editor NEW
10.0 10.0 3.0 114.99 MB

Python/TF1 implementation of DeepAccNet (https://www.biorxiv.org/content/10.1101/2020.07.17.209643v1)

License: MIT License

Python 98.60% Shell 1.40%

deepaccnet-tf's People

Contributors

hiranumn avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar

deepaccnet-tf's Issues

pyErrorPred.predict error

It seems the pyErrorPred.predict not correct

the predict function in DeepAccNet.py

    result = pyErrorPred.predict(samples,
                                    modelpath,
                                    args.output,
                                    num_blocks=5,
                                    num_filters=128,
                                    verbose=args.verbose,
                                    ensemble=args.ensemble,
                                   csv = args.csv)

while the function in predict.py looks like

def predict(samples, modelpath, outfolder, num_blocks=5, num_filters=128, ensemble=False, verbose=False):

n_models = 5 if ensemble else 2
for i in range(1, n_models):
    modelname = modelpath+"_rep"+str(i)
    if verbose: print("Loading", modelname)
    model = Model(obt_size = 70,
                  tbt_size = 33,
                  prot_size = None,
                  num_chunks = num_blocks,
                  channel = num_filters,
                  optimizer = "adam",
                  loss_weight = [1.0, 0.25, 10.0],
                  name = modelname,
                  label_smoothing = False,
                  no_last_dilation = True,
                  partial_instance_norm = True,
                  bert = False)
    model.load()
        
    for j in range(len(samples)):
        if verbose: print("Predicting for", samples[j], "(network rep"+str(i)+")") 
        tmp = join(outfolder, samples[j]+".features.npz")
        batch = getData(tmp)
        lddt, estogram, mask = model.predict(batch)
        if not ensemble:
            np.savez_compressed(join(outfolder, samples[j]+".npz"),
                                lddt = lddt,
                                estogram = estogram,
                                mask = mask)
        else:
            np.savez_compressed(join(outfolder, samples[j]+".rep"+str(i)+".npz"),
                                lddt = lddt,
                                estogram = estogram,
                                mask = mask)

No csv option and no return value.

Please double-check if the code version is correctly uploaded.
Best

Source code for refinement

It's a very interesting work. The code here can only predict the accuracy. I would appreciate it if you could provide the source code for refinement.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.