cosmopharm 0.1.2__py3-none-any.whl → 0.1.2a0__py3-none-any.whl

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -0,0 +1,213 @@
1
+ Metadata-Version: 2.4
2
+ Name: cosmopharm
3
+ Version: 0.1.2a0
4
+ Summary: Predictive modeling for drug-polymer compatibility in pharmaceutical formulations using COSMO-SAC.
5
+ Home-page: https://github.com/ivanantolo/cosmopharm
6
+ Author: Ivan Antolovic
7
+ Author-email: Ivan.Antolovic@tu-berlin.de
8
+ Maintainer: Martin Klajmon
9
+ Maintainer-email: Martin.Klajmon@vscht.cz
10
+ License: MIT
11
+ Keywords: Drug-Polymer Compatibility,Amorphous Solid Dispersions,Pharmaceutical Formulation,COSMO-SAC Model,Solubility Prediction,Miscibility Analysis,Phase Behavior Prediction,Pharmaceutical Sciences,Drug Formulation Research,Polymer Science,Predictive Modeling in Pharma,Drug Development Tools,Biopharmaceuticals
12
+ Classifier: Development Status :: 3 - Alpha
13
+ Classifier: Intended Audience :: Science/Research
14
+ Classifier: Intended Audience :: Healthcare Industry
15
+ Classifier: Intended Audience :: Developers
16
+ Classifier: Intended Audience :: Education
17
+ Classifier: License :: OSI Approved :: MIT License
18
+ Classifier: Topic :: Scientific/Engineering
19
+ Classifier: Topic :: Scientific/Engineering :: Bio-Informatics
20
+ Classifier: Topic :: Scientific/Engineering :: Chemistry
21
+ Classifier: Programming Language :: Python :: 3
22
+ Classifier: Programming Language :: Python :: 3 :: Only
23
+ Classifier: Programming Language :: Python :: 3.8
24
+ Classifier: Programming Language :: Python :: 3.9
25
+ Classifier: Programming Language :: Python :: 3.10
26
+ Classifier: Programming Language :: Python :: 3.11
27
+ Classifier: Programming Language :: Python :: 3.12
28
+ Classifier: Programming Language :: Python :: 3.13
29
+ Requires-Python: >=3.8
30
+ Description-Content-Type: text/markdown
31
+ License-File: LICENSE
32
+ Requires-Dist: numpy>=1.15
33
+ Requires-Dist: pandas>=1.0
34
+ Requires-Dist: scipy>=1.4
35
+ Requires-Dist: openpyxl>=3.0
36
+ Provides-Extra: examples
37
+ Requires-Dist: matplotlib>=3.0; extra == "examples"
38
+ Dynamic: description-content-type
39
+ Dynamic: license-file
40
+
41
+ # COSMOPharm
42
+
43
+ <p align="center">
44
+ <img src=https://github.com/ivanantolo/cosmopharm/raw/main/TOC.png alt="TOC Figure" width="500"/>
45
+ </p>
46
+
47
+
48
+ Welcome to the COSMOPharm repository, accompanying [our paper in *Molecular Pharmaceutics*](https://doi.org/10.1021/acs.molpharmaceut.4c00342). This project and its associated publication offer insights and a practical toolkit for researching drug-polymer and drug-solvent systems, aiming to provide the scientific community with the means to reproduce our findings and further the development of COSMO-SAC-based models.
49
+
50
+ ## About
51
+
52
+ COSMOPharm is a Python package designed to streamline the predictive modeling of drug-polymer compatibility, crucial for the development of pharmaceutical amorphous solid dispersions. Apart from that, it can also be used for the miscibility/solubility of drugs with/in common solvents. Leveraging the COSMO-SAC (Conductor-like Screening Model Segment Activity Coefficient) model, COSMOPharm offers a robust platform for scientists and researchers to predict solubility, miscibility, and phase behavior in drug formulation processes.
53
+
54
+ ## Features
55
+
56
+ - **Compatibility Prediction**: Utilize open-source COSMO-SAC model for prediction of drug-polymer compatibility.
57
+ - **Solubility Calculation**: Calculate drug-polymer solubilities to guide the selection of suitable polymers for drug formulations.
58
+ - **Miscibility and Phase Behavior Analysis**: Analyze the miscibility of drug-polymer pairs and understand their phase behavior under various conditions.
59
+ - **User-friendly Interface**: Easy-to-use functions and comprehensive documentation to facilitate research and development in pharmaceutical sciences.
60
+
61
+ ## Installation
62
+
63
+ ### Quick Installation
64
+ For most users, the quickest and easiest way to install COSMOPharm is via pip, which will manage all dependencies for you. Ensure you have already installed the `cCOSMO` library by following the instructions on the [COSMOSAC GitHub page](https://github.com/usnistgov/COSMOSAC).
65
+
66
+ Once `cCOSMO` is installed, you can install COSMOPharm directly from [PyPI](https://pypi.org/project/cosmopharm/):
67
+
68
+ ```
69
+ pip install cosmopharm
70
+ ```
71
+
72
+ ### Advanced Installation Options
73
+
74
+ For users who need more control over the installation process (e.g., for development purposes or when integrating with other projects), COSMOPharm can also be installed by cloning the repository and installing manually.
75
+
76
+ #### Step 1: Clone the Repository
77
+
78
+ First, clone the COSMOPharm repository. The project includes a submodule named "pharmaceuticals" that stores essential data files (.sigma, .cosmo, and .xyz files) for the pharmaceutical components. Use the --recurse-submodules option to ensure that the "pharmaceuticals" submodule is correctly initialized and updated along with the main project.
79
+ ```
80
+ git clone --recurse-submodules https://github.com/ivanantolo/cosmopharm
81
+ ```
82
+
83
+ #### Step 2: Navigate to the Repository Directory
84
+
85
+ ```
86
+ cd cosmopharm
87
+ ```
88
+
89
+ #### Option 1: Using pip to Install from Local Source
90
+
91
+ This method installs COSMOPharm and manages all dependencies efficiently:
92
+
93
+ ```
94
+ pip install .
95
+ ```
96
+
97
+
98
+ #### Option 2: Using setup.py for Installation
99
+
100
+ Alternatively, you can run the setup script directly:
101
+
102
+ ```
103
+ python setup.py install
104
+ ```
105
+
106
+ While this method is straightforward, using `pip` is generally preferred for its dependency management capabilities.
107
+
108
+ Please note: Before proceeding with either advanced installation option, ensure the `cCOSMO` library is installed as described at the beginning of this section.
109
+
110
+ ## Quick Start
111
+
112
+ Get started with COSMOPharm using the minimal example below, which demonstrates how to calculate the solubility of a drug in a polymer. This example succinctly showcases the use of COSMOPharm for solubility calculations:
113
+
114
+
115
+ ```python
116
+ import matplotlib.pyplot as plt
117
+ import cCOSMO
118
+ from cosmopharm import SLE, COSMOSAC
119
+ from cosmopharm.utils import create_components, read_params
120
+
121
+ # Define components
122
+ names = ['SIM','PLGA50']
123
+ params_file = "data/sle/table_params.xlsx"
124
+
125
+ # Load parameters and create components
126
+ parameters = read_params(params_file)
127
+ mixture = create_components(names, parameters)
128
+
129
+ # Initialize COSMO-SAC model - replace paths with your local paths to COSMO profiles
130
+ db = cCOSMO.DelawareProfileDatabase(
131
+ "./profiles/_import_methods/UD/complist.txt",
132
+ "./profiles/_import_methods/UD/sigma3/")
133
+
134
+ for name in names:
135
+ iden = db.normalize_identifier(name)
136
+ db.add_profile(iden)
137
+ COSMO = cCOSMO.COSMO3(names, db)
138
+
139
+ # Setup the COSMO-SAC model with components
140
+ actmodel = COSMOSAC(COSMO, mixture=mixture)
141
+
142
+ # Calculate solubility (SLE)
143
+ sle = SLE(actmodel=actmodel)
144
+ solubility = sle.solubility(mix='real')
145
+
146
+ # Output the solubility
147
+ print(solubility[['T', 'w', 'x']].to_string(index=False))
148
+
149
+ # Plot results
150
+ plt.plot(*solubility[['w','T']].values.T,'.-', label='Solubility (w)')
151
+
152
+ # Settings
153
+ plt.xlim(0,1)
154
+ plt.ylim(300,500)
155
+ # Adding title and labels
156
+ plt.title('Solubility vs. Temperature')
157
+ plt.ylabel("T / K")
158
+ xlabel = {'w':'Weight', 'x':'Mole'}
159
+ plt.xlabel(f"Weight fraction {mixture[0].name}")
160
+ plt.legend()
161
+ # Save the figure to a PNG or PDF file
162
+ plt.savefig('solubility_plot.png') # Saves the plot as a PNG file
163
+ # plt.savefig('solubility_plot.pdf') # Saves the plot as a PDF file
164
+ plt.show()
165
+ ```
166
+
167
+ For a more comprehensive demonstration, including advanced functionalities and plotting results, please see the [example_usage.py](https://github.com/ivanantolo/cosmopharm/blob/main/example_usage.py) script in this repository. This detailed example walks through the process of setting up COSMOPharm, initializing models, and visualizing the results of solubility and miscibility calculations.
168
+
169
+ ## Contributing / Getting Help
170
+
171
+ Contributions to COSMOPharm are welcome! We accept contributions via pull requests to the [GitHub repository](https://github.com/ivanantolo/cosmopharm).
172
+
173
+ For bugs, feature requests, or other queries, please [open an issue](https://github.com/ivanantolo/cosmopharm/issues) on GitHub.
174
+
175
+
176
+ ## Citation
177
+
178
+ We appreciate citations to our work as they help acknowledge and spread our research contributions. If you use COSMOPharm in your research, please cite the associated paper. Citation details are provided in the [`CITATION.cff`](https://github.com/ivanantolo/cosmopharm/CITATION.cff) file, and GitHub generates APA or BibTeX formats accessible under the "Cite this repository" dropdown on our repository page.
179
+
180
+ For convenience, here's the citation in BibTeX format:
181
+
182
+ ```bibtex
183
+ @article{Antolovic2024COSMOPharm,
184
+ title={COSMOPharm: Drug--Polymer Compatibility of Pharmaceutical Amorphous Solid Dispersions from COSMO-SAC},
185
+ author={Antolovic, Ivan and Vrabec, Jadran and Klajmon, Martin},
186
+ journal={Molecular Pharmaceutics},
187
+ year={2024},
188
+ volume={1}, # Will be adjusted accordingly
189
+ issue={1}, # Will be adjusted accordingly
190
+ month={3}, # Will be adjusted accordingly
191
+ pages={1--10}, # Will be adjusted accordingly
192
+ doi={10.1021/acs.molpharmaceut.3c12345} # Will be adjusted accordingly
193
+ }
194
+ ```
195
+
196
+ ### Gaussian Citation
197
+ **Permission from Gaussian, Inc.** was obtained to make the [.cosmo files](https://github.com/ivanantolo/cosmopharm/tree/main/profiles/polymers/cosmo) for the oligomers included in [our paper in *Mol. Pharm.*](https://doi.org/10.1021/acs.molpharmaceut.4c00342) available for academic and research (noncommercial) use. This is to enhance research transparency and facilitate the validation process.
198
+
199
+ When using COSMOPharm with the sigma-profiles provided therein, please also cite Gaussian as follows:
200
+
201
+ ```bibtex
202
+ @misc{g16,
203
+ author={M. J. Frisch and G. W. Trucks and H. B. Schlegel and G. E. Scuseria and M. A. Robb and J. R. Cheeseman and G. Scalmani and V. Barone and G. A. Petersson and H. Nakatsuji and X. Li and M. Caricato and A. V. Marenich and J. Bloino and B. G. Janesko and R. Gomperts and B. Mennucci and H. P. Hratchian and J. V. Ortiz and A. F. Izmaylov and J. L. Sonnenberg and D. Williams-Young and F. Ding and F. Lipparini and F. Egidi and J. Goings and B. Peng and A. Petrone and T. Henderson and D. Ranasinghe and V. G. Zakrzewski and J. Gao and N. Rega and G. Zheng and W. Liang and M. Hada and M. Ehara and K. Toyota and R. Fukuda and J. Hasegawa and M. Ishida and T. Nakajima and Y. Honda and O. Kitao and H. Nakai and T. Vreven and K. Throssell and Montgomery, {Jr.}, J. A. and J. E. Peralta and F. Ogliaro and M. J. Bearpark and J. J. Heyd and E. N. Brothers and K. N. Kudin and V. N. Staroverov and T. A. Keith and R. Kobayashi and J. Normand and K. Raghavachari and A. P. Rendell and J. C. Burant and S. S. Iyengar and J. Tomasi and M. Cossi and J. M. Millam and M. Klene and C. Adamo and R. Cammi and J. W. Ochterski and R. L. Martin and K. Morokuma and O. Farkas and J. B. Foresman and D. J. Fox},
204
+ title={Gaussian˜16 {R}evision {C}.01},
205
+ year={2016},
206
+ note={Gaussian Inc. Wallingford CT}
207
+ }
208
+ ```
209
+
210
+ ## License
211
+
212
+ COSMOPharm is released under the MIT License. See the [LICENSE](https://github.com/ivanantolo/cosmopharm/LICENSE) file for more details.
213
+
@@ -11,8 +11,8 @@ cosmopharm/utils/convert.py,sha256=V-7jY-Sb7C38N5bQcp1c27EOiVJfriP6zRbLAIKgrdE,2
11
11
  cosmopharm/utils/helpers.py,sha256=CXUTh3jVStHno_W_Z7o8RvQ6SveSjw_Ss31CkvfROfs,1460
12
12
  cosmopharm/utils/lle_scanner.py,sha256=So9FCxLLcHmBkuF6zggMo3W3gFBocEmuRzyxVGy69JM,6587
13
13
  cosmopharm/utils/spacing.py,sha256=vtM9b4wodpFGkZFGGLhiSXT51Zl6fNK2Og4oRcbLFH4,9222
14
- cosmopharm-0.1.2.dist-info/licenses/LICENSE,sha256=25ZCycfBgonIECGYnZTy72eJVfzcHCEOz3DM9sTx7do,1162
15
- cosmopharm-0.1.2.dist-info/METADATA,sha256=D_zX08jgnOexeqVxwOjb1xh2hGsNrlicM0znVmAWEmY,1899
16
- cosmopharm-0.1.2.dist-info/WHEEL,sha256=_zCd3N1l69ArxyTb8rzEoP9TpbYXkqRFSNOD5OuxnTs,91
17
- cosmopharm-0.1.2.dist-info/top_level.txt,sha256=MGniVgvs1yq4sn6HQ7ErDVYV_g3st3Fs8TTFHOJVQ9I,11
18
- cosmopharm-0.1.2.dist-info/RECORD,,
14
+ cosmopharm-0.1.2a0.dist-info/licenses/LICENSE,sha256=25ZCycfBgonIECGYnZTy72eJVfzcHCEOz3DM9sTx7do,1162
15
+ cosmopharm-0.1.2a0.dist-info/METADATA,sha256=Y40vqw4ejSbp2w-KMJQiPiBIlUaFN9HfCqdAETbMmcM,11024
16
+ cosmopharm-0.1.2a0.dist-info/WHEEL,sha256=_zCd3N1l69ArxyTb8rzEoP9TpbYXkqRFSNOD5OuxnTs,91
17
+ cosmopharm-0.1.2a0.dist-info/top_level.txt,sha256=MGniVgvs1yq4sn6HQ7ErDVYV_g3st3Fs8TTFHOJVQ9I,11
18
+ cosmopharm-0.1.2a0.dist-info/RECORD,,
@@ -1,39 +0,0 @@
1
- Metadata-Version: 2.4
2
- Name: cosmopharm
3
- Version: 0.1.2
4
- Summary: Predictive modeling for drug-polymer compatibility in pharmaceutical formulations using COSMO-SAC.
5
- Home-page: https://github.com/ivanantolo/cosmopharm
6
- Author: Ivan Antolovic
7
- Author-email: Ivan.Antolovic@tu-berlin.de
8
- Maintainer: Martin Klajmon
9
- Maintainer-email: Martin.Klajmon@vscht.cz
10
- License: MIT
11
- Keywords: Drug-Polymer Compatibility,Amorphous Solid Dispersions,Pharmaceutical Formulation,COSMO-SAC Model,Solubility Prediction,Miscibility Analysis,Phase Behavior Prediction,Pharmaceutical Sciences,Drug Formulation Research,Polymer Science,Predictive Modeling in Pharma,Drug Development Tools,Biopharmaceuticals
12
- Classifier: Development Status :: 3 - Alpha
13
- Classifier: Intended Audience :: Science/Research
14
- Classifier: Intended Audience :: Healthcare Industry
15
- Classifier: Intended Audience :: Developers
16
- Classifier: Intended Audience :: Education
17
- Classifier: License :: OSI Approved :: MIT License
18
- Classifier: Topic :: Scientific/Engineering
19
- Classifier: Topic :: Scientific/Engineering :: Bio-Informatics
20
- Classifier: Topic :: Scientific/Engineering :: Chemistry
21
- Classifier: Programming Language :: Python :: 3
22
- Classifier: Programming Language :: Python :: 3 :: Only
23
- Classifier: Programming Language :: Python :: 3.8
24
- Classifier: Programming Language :: Python :: 3.9
25
- Classifier: Programming Language :: Python :: 3.10
26
- Classifier: Programming Language :: Python :: 3.11
27
- Classifier: Programming Language :: Python :: 3.12
28
- Classifier: Programming Language :: Python :: 3.13
29
- Requires-Python: >=3.8
30
- Description-Content-Type: text/markdown
31
- License-File: LICENSE
32
- Requires-Dist: numpy>=1.15
33
- Requires-Dist: pandas>=1.0
34
- Requires-Dist: scipy>=1.4
35
- Requires-Dist: openpyxl>=3.0
36
- Provides-Extra: examples
37
- Requires-Dist: matplotlib>=3.0; extra == "examples"
38
- Dynamic: description-content-type
39
- Dynamic: license-file