quantumjot / pyfolding Goto Github PK
View Code? Open in Web Editor NEWPython framework for multi-parameter optimization and evaluation of protein folding models
License: MIT License
Python framework for multi-parameter optimization and evaluation of protein folding models
License: MIT License
Originally posted by @mnaqvi-code in #4 (comment)
Hi
I am using the heteropolymer model and using the following fitting command:
ising.fit_heteropolymer(curves[0:12], topology1[0:12], popsize=10, maxiter= 10000)
I am getting the following error:
TypeError Traceback (most recent call last)
in
----> 1 ising.fit_heteropolymer(curves[0:12], topology1[0:12], popsize=10, maxiter= 10000)
~\anaconda3\lib\site-packages\pyfolding\ising.py in fit_heteropolymer(equilibrium_curves, topologies, popsize, tol, maxiter, **kwargs)
755 for protein, topology in zip(equilibrium_curves, topologies):
756 fit_func.append(protein, topology)
--> 757 print( '+ added {0:s} with topology {1:s}'.format(protein.ID, [d().name for d in topology]))
758
759 # do the fitting
TypeError: unsupported format string passed to list.format
Please inform me if you know how to fix it. It seems this is an issue with python 3 version? Thanks
When I am running the code and I am getting the following error
Automatic global fitting to the homozipper model
ValueError Traceback (most recent call last)
in
1 # try with a one-liner which can also save out the curve fits via:"save='/Users/ergm/Desktop/test.csv'
----> 2 r_homo = ising.fit_homopolymer(proteins, n_helices) #, save='/Users/ergm/Desktop/test.csv')
~\anaconda3\lib\site-packages\pyfolding-1.0-py3.8.egg\pyfolding\ising.py in fit_homopolymer(equilibrium_curves, topologies, p0, bounds, **kwargs)
657 # do the global fit
658 # out, covar = global_fit.fit( p0=p0, bounds=((0,-1.,0.),(10.,1.,-10.)) )
--> 659 out, covar = global_fit.fit( p0=p0, bounds=bounds )
660
661
~\anaconda3\lib\site-packages\pyfolding-1.0-py3.8.egg\pyfolding\core.py in fit(self, p0, bounds)
776 # fit the data
777 if bounds:
--> 778 out, covar = optimize.curve_fit(self, x, y, p0=p0, bounds=bounds,
779 max_nfev=20000, absolute_sigma=True,
780 sigma=self.fit_weights)
~\anaconda3\lib\site-packages\scipy\optimize\minpack.py in curve_fit(f, xdata, ydata, p0, sigma, absolute_sigma, check_finite, bounds, method, jac, **kwargs)
793 kwargs['max_nfev'] = kwargs.pop('maxfev', None)
794
--> 795 res = least_squares(func, p0, jac=jac, bounds=bounds, method=method,
796 **kwargs)
797
~\anaconda3\lib\site-packages\scipy\optimize_lsq\least_squares.py in least_squares(fun, x0, jac, bounds, method, ftol, xtol, gtol, x_scale, loss, f_scale, diff_step, tr_solver, tr_options, jac_sparsity, max_nfev, verbose, args, kwargs)
789
790 if np.any(lb >= ub):
--> 791 raise ValueError("Each lower bound must be strictly less than each "
792 "upper bound.")
793
ValueError: Each lower bound must be strictly less than each upper bound.
The equation used for the model :TwoStateEquilibriumSloping is incorrect. The correct equation is :
Fnorm =[An + Bn + (Ad + Bd) exp(m(D-D50%)/RT )]/(1 + exp(m(D-D50%)/RT ))
There is a bracket [ ] missing in the equation currently used which is giving wrong fitting parameters. Please correct it. Thanks
Hello
Every time I try to use the command Equilm_FKBP12.save_fit('(test.csv') I get the error a bytes-like object is required, not 'str'. How do I fix this
A declarative, efficient, and flexible JavaScript library for building user interfaces.
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. ๐๐๐
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google โค๏ธ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.