Science topic

Python - Science topic

Explore the latest questions and answers in Python, and find Python experts.
Questions related to Python
  • asked a question related to Python
Question
1 answer
I need help with the coding to prepare an inventory map for a specific region. I need help with using InSAR images as an input, or I need to know where I can get code quickly.
Relevant answer
Answer
For sentinel-1. Have a look at PySAR, geopandas or SARpy,
openCV features a detection module, more generally tensorFlow/PyTorch for the ML approach.
Briefly on the inital segmentation.
With radar surface data you need image recognition to locate whatever you want to trace. So you can either attach a machine learning module and train it on the necessary data or go with a fuzzy image recognition method, and tune the parameters of that until it matches. Decide if you want to create result imagery or numerical data without presentation layer. At minimum you create your own timeseries data with timestamps and absolute geoposition data of the objects ( most simple: center of object vs. inserted geometric approximations of the shape with rough orientation and position data, depends on what is tracked) . You have a related problem to solve, now - satellite positions at different times = different absolute positioning in the image vs. geoposition. So you can choose distinct objects as reference or compute the sat position and calculate the expected position of target objects relative to the timestamp of each image. How many images you have to compare has an upper limit in the orbital parameters and the lower limit depends on the time resolution you need for this. From the mission data I derive they have an orbital cycle of 27 days with 385 orbits per cycle ~1.7 hours per orbit but with a phase of 140deg, see the sentinel-1 website for the mission data. There is XML SAFE format metadata available with the exact orbital position with each image, you will need that to compensate the phase shift.
Best of luck
ThS
  • asked a question related to Python
Question
5 answers
  • Do you find it better to stick to Jupyter Notebooks for flexibility, or does a standalone GUI (e.g., using Tkinter or PyQt) significantly improve lab productivity?
  • How do you manage the trade-off between development time and research utility?
Relevant answer
Answer
Gökhan Ergen Dear Gökhan, Thank you for the detailed and thoughtful answer this resonates strongly with my experience as well. Thanks for sharing your workflow and tools; this is a very practical perspective.
  • asked a question related to Python
Question
12 answers
From research point of view, I want to try segmentation on medical radiology images. Can anyone suggest me related to coding platform to be used?
Like python, R, Matlab etc.
Which is suitable and some related to start over?
Relevant answer
Answer
Tools for Medical Image Segmentation in Research
When segmenting medical images for research purposes, you can choose from various platforms, tools, and programming languages. The optimal choice depends on your specific tasks, skill level, and preferred development ecosystem.
Python
Python is a popular choice for medical image processing due to its rich ecosystem of libraries and frameworks. Notable tools include:
  • MIScnn — an open‑source framework for rapidly setting up segmentation pipelines using convolutional neural networks (CNNs) and deep learning. It supports 2D and 3D segmentation and includes data I/O, preprocessing, augmentation, patch analysis, and full‑image processing. 6 8
  • PyMIC — a library for annotation‑efficient segmentation, focusing on imperfect annotations (partial or noisy labels). It supports semi‑supervised, weakly supervised, and robust learning in the presence of label noise. 7
  • CBIM‑Medical‑Image‑Segmentation — a PyTorch‑based framework for developing and evaluating deep learning models. It supports 2D/3D data, multiple modalities, and tasks, and includes implementations of modern architectures (MedFormer, UNet, TransUNet, etc.). 9
Additionally, Python offers libraries like SimpleITK (for image processing, including segmentation) and NumPy (for array manipulation). 11 10
MATLAB
MATLAB provides tools for medical image segmentation, covering both classical image processing techniques and deep learning approaches. Key features include:
  • Medical Segment Anything Model (MedSAM) — a deep learning algorithm for interactive 2D medical image segmentation. It can segment objects across multiple modalities without retraining on specific datasets. 16
  • Medical Imaging Toolbox — includes segmentation functions, as well as tools for accessing image formats (DICOM, NIfTI, etc.), preprocessing (background removal, denoising, intensity normalization). 17 18
  • Medical Image Labeler — an app for interactive data labeling and segmentation. 17
MATLAB is suitable for researchers already familiar with this environment or those requiring integration with other MathWorks tools. 18
Other Platforms
  • 3D Slicer — an open‑source, cross‑platform tool for medical image processing and 3D visualization. It includes the Segment Editor module with basic editing tools (brush, eraser) and support for custom modules, ideal for interactive data manipulation. 2
  • iSEG (Medical Image Segmentation Tool Set) — a tool for generating anatomical models from medical images. It offers a wide range of segmentation methods (region competition, fuzzy connectivity, level‑set methods, etc.), along with preprocessing and postprocessing support. 1 4
  • ITK‑SNAP — open‑source software for interactive 3D medical image segmentation. It implements two well‑known active contour methods: geodesic active contours and region competition. 2
Comparison and Recommendations
CriterionPythonMATLABOther PlatformsFlexibility and EcosystemRich ecosystem with numerous frameworks and librariesIntegrated environment with ready‑made toolsVaries by tool (e.g., 3D Slicer is open and extensible) 6 7 9 17 18 2ComplexityRequires knowledge of Python and librariesMay be easier for MATLAB usersVaries (ITK‑SNAP has a simpler interface; 3D Slicer is more complex) 6 7 18 2Community SupportActive community with many resources and code examplesStrong community in the medical fieldVaries (e.g., 3D Slicer has an active community) 6 7 17 2Deep Learning IntegrationDirect support via frameworks (PyTorch, TensorFlow)Supported via Deep Learning Toolbox and Computer Vision ToolboxVaries (some tools support DL integration) 7 9 17
Recommendations:
  • Choose Python if you prioritize flexibility, access to state‑of‑the‑art deep learning methods, and a large community.
  • Opt for MATLAB if you already have MATLAB experience or need integration with MathWorks tools.
  • Use 3D Slicer or ITK‑SNAP for interactive 3D image processing and visualization.
When selecting a tool, also consider data availability (formats, volume), required segmentation methods, and available resources for model training.
  • asked a question related to Python
Question
2 answers
I’m working on a PhD research project in Forestry Engineering at UFPR (Brazil), analyzing urban forests in Curitiba with a two-stage sampling approach (neighborhoods as primary units, plots as secondary). My recent submission to Silva Fennica used Landsat-derived tree cover index for biomass modeling via GLM. What validation techniques (e.g., cross-validation, AIC/BIC comparison, field data integration) do you recommend to strengthen model robustness, especially for publication in high-impact journals? Any R/Python code examples or key references appreciated. Data details: 75 neighborhoods, sample sizes m=17/n=221 for SE13%
Relevant answer
And sensitivity analysis and ask the journal what they require :)
  • asked a question related to Python
Question
6 answers
Is it possible to keep active the runtime of Google Colab all the time (even when there is no activity)? May be with paid version or some kind of coding? Also, to avoid such issues (including the RAM crash problem), shall we go for offline platforms like VS code, Anaconda, etc.?
Relevant answer
Answer
Dear Researchers, in my case the problem is as follows: I want to keep Google Colab running for a long time, but the session keeps disconnecting and I experience RAM crashes. Colab Pro or Pro+ helps a bit but does not completely solve the issue. Therefore, for long or heavy computations, local environments like VS Code, Anaconda, or Jupyter Notebook are much safer and more stable.
  • asked a question related to Python
Question
2 answers
how Python’s design and ecosystem affect its suitability for building scalable, high-performance software systems.
Relevant answer
Answer
Hi Muhammad,
I hope you're doing great!
The key challenges of using Python for scalable and performance-critical applications primarily stem from its design as an interpreted, dynamically typed language with a global lock.
  • Global Interpreter Lock (GIL): This is the most significant bottleneck for CPU-bound tasks. The GIL allows only one thread to execute Python bytecode at a time, effectively preventing multi-threaded Python programs from utilizing multiple CPU cores simultaneously.
  • Interpretation Overhead: As an interpreted language, Python executes code line-by-line, which is inherently slower than compiled languages like C++ or Rust that are optimized into machine code beforehand.
  • Dynamic Typing Costs: Python resolves variable types at runtime, requiring constant type checking and dispatching. This adds significant computational overhead compared to statically typed languages where types are resolved during compilation.
  • Memory Consumption: Python objects carry substantial metadata (headers, reference counts), leading to higher memory usage than raw data structures in lower-level languages. This can impact cache locality and overall performance in data-intensive applications.
To mitigate these, developers often rely on C-extensions (like NumPy), multiprocessing (to bypass the GIL), or asynchronous programming (for I/O-bound tasks), though these add complexity to the architecture.
Multi-threading is a myth in Python | GIL - https://www.youtube.com/watch?v=zvXU8jOMxoA
This YouTube video provides a quick, visual explanation of how the Global Interpreter Lock (GIL) prevents true parallelism in Python threads, which is central to understanding the language's performance limitations.
  • asked a question related to Python
Question
5 answers
Hi everyone, I’m an MSCS student in the U.S. preparing a MICCAI 2026 submission on histopathology self-supervised learning and label efficiency (benchmarking performance under 1–10% labeled regimes with strong baselines).
Due to international travel constraints, I may not be able to attend in person in Abu Dhabi. I’m looking for a collaborator who can contribute meaningfully before submission (experiments/analysis/writing/reproducibility) and, if accepted, potentially present on-site as an author.
If interested, please DM me with your background (medical imaging / SSL / PyTorch) and availability. Thanks!
Relevant answer
Answer
I’m a bit confused about how MATLAB relates to WSI annotations in label efficiency for histopathology, and also how this ties into presenting on-site at the conference.
  • asked a question related to Python
Question
1 answer
I have installed the python engine i-PI that helps with the REMD but and i am attaching the .xml script here can someone tell me where i m going wrong <simulation verbosity='high'>
<total_steps>20000</total_steps>
<prng>
<seed>9876</seed>
</prng>
<output prefix='TREMD'>
<properties filename='out' stride='10'>
step, time{femtosecond}, conserved{kelvin}, temperature{kelvin}, potential{kelvin}, kinetic_cv{kelvin}
</properties>
<trajectory filename='pos' stride='100' format='xyz' cell_units='angstrom'>
positions{angstrom}
</trajectory>
<checkpoint filename='checkpoint' stride='1000' overwrite='True'/>
</output>
<ffsocket mode='inet' name='driver'>
<address>localhost</address>
<port>12345</port>
<timeout>500</timeout>
</ffsocket>
<system>
<cell units='angstrom'>
10.0 0.0 0.0
0.0 10.0 0.0
0.0 0.0 10.0
</cell>
<initialize nbeads='2'>
<file mode='xyz'>water.xyz</file>
<velocities mode='thermal' units='kelvin'>300</velocities>
</initialize>
<forces>
<force forcefield='driver'/>
</forces>
<ensemble>
<temperature units='kelvin'>300.0</temperature>
</ensemble>
<ensemble>
<temperature units='kelvin'>400.0</temperature>
</ensemble>
<motion mode='REMD'>
<dynamics mode='nve'>
<timestep units='femtosecond'>0.5</timestep>
</dynamics>
<remd>
<stride>50</stride>
<exchange mode='temp'/>
</remd>
</motion>
</system>
</simulation>
This is a test case for a water molecule
Relevant answer
Answer
Your XML is invalid for REMD because:
You defined two <ensemble> sections in a single <system>
i-PI expects one ensemble per system
Each replica must be a separate <system>, each connected to its own CP2K instance
  • asked a question related to Python
Question
6 answers
Based on our current results, how can we improve the model. Does the RSS suggest overfitting? how can we further analyze PACF and ACF plots to determine which type of model is best? how can we improve the process of transforming the data to a stationary series? How do we interpret the parameters (roots-real/imaginary) to improve our model?
Relevant answer
Answer
Model correctness depends on proper preprocessing (trend removal, seasonal adjustment), robustness checks (rolling forecasts, cross-validation), residual analysis, and sensitivity to policy or economic shocks; failure to address nonstationarity, structural breaks, or omitted climate drivers often leads to misleading inference and poor forecasts.
  • asked a question related to Python
Question
6 answers
How public health professionals can specially researcher having python and machine learning knowledge?
Relevant answer
Answer
Public health in terms of most distinguished patterns of diseases, causes, remedies all such medical area will be ML most likely to be helpful for help in such a
  • asked a question related to Python
Question
5 answers
I have measured the transmittance and total reflectance spectrum of ZnO. I want to obtain the bandgap and other optical constants from these data. I have an idea about the thickness of the film (from the cross-sectional SEM image of the layer). Not all my spectra have the interference pattern, so I don't know if Swanepoel analysis can be done on them. Another method that I saw was using Transfer Matrix analysis. From what I understood, it would require computing abilities using Python or Matlab, is that so? Is there any software developed to do the analysis? Can someone suggest papers or guides which I can refer to understand how it can be done using Origin, if it would be possible? I am looking for a method which is more accurate than using the Beer-Lambert law, as I have thin film samples.
Relevant answer
Answer
Did you tried Kubelka-Munk Function ?
  • asked a question related to Python
Question
5 answers
I am a student in a Law–Economics dual program, building a simplified economic model of a fictional country. I want to simulate interactions between households, firms, markets, and institutions. I am considering combining an ABM with a Stock-Flow Consistent approach. Is this the most suitable framework for a small, pedagogical model? I would be extremely grateful for any references, methodological guides, or software recommendations.
keywords: agent-based modeling, stock-flow consistent, computational economics, macroeconomics, economic modeling, simulation, household-firm interaction, financial flows
Relevant answer
Answer
I recommend using a systems dynamics (SD) approach to create a simplified but realistic model of a hypothetical country. SD allows you to capture the fundamental interactions between sectors, populations, and policies through stocks, flows, and feedback loops, providing a dynamic and intuitive understanding of how the economy evolves over time. For added realism, you can combine elements of computational general equilibrium (CGE) modeling to simulate market interactions and sectoral responses, creating a hybrid model that balances simplicity with robust economic behavior.
  • asked a question related to Python
Question
1 answer
I have been struggling for the past few days with handling the PK-Sim. I have to finish a task of converting the model developed in PK-sim into a model developed in Python. I have the .pkml files for the developed model. Is that everything I need, or is any other information also required?
Any advice will be much appreciated.
Relevant answer
Answer
The .pkml file contains most of the information you need (compartments, flows, drug properties, and simulation settings). You may also need any experimental data or custom reactions not included in the file. In Python, you can parse the .pkml (XML format) using xml.etree.ElementTree or lxml and map the parameters to a PBPK ODE model for simulation.
  • asked a question related to Python
Question
3 answers
Hello everyone,
I’m a 4th-year undergraduate student in Electrical and Electronic Engineering (EEE), currently working on my undergraduate thesis that involves crop simulation using DSSAT.
I’ve been trying to find resources or tutorials on how to:
  1. Edit existing example files or datasets in DSSAT.
  2. Run DSSAT simulations directly through MATLAB or Python, so that I don’t have to manually open the DSSAT interface each time I run a simulation.
Unfortunately, I haven’t found any clear or detailed videos or articles explaining this process.
Can anyone please suggest any documentation, tutorials, or example codes related to this topic? Any guidance or reference materials would be greatly appreciated.
Thank you in advance for your help!
Tanvir
Relevant answer
Answer
You can! This is a very common way to automate experiments, sensitivity analysis, or run batch simulations.
The core approach is to call the DSSAT command-line executable from within a Python or MATLAB script, rather than opening the GUI.
@@ Core Principles
Instead of clicking the "Run" button in the DSSAT interface, you will use a function in Python/MATLAB to directly execute the DSSAT core program (e.g., DSCSM047.EXE for version 4.7).
The general process is as follows:
Preparation (Script): Your script (Python/MATLAB) automatically modifies the input files (e.g., FileX, fertilizer file, weather file) to set up the scenario you want to simulate.
Run (Script): The script calls the DSSAT executable in "batch mode".
Collect (Script): DSSAT runs in the background (no interface) and produces output files (e.g. Summary.OUT, PlantGro.OUT).
Analyze (Script): Your script reads these output files to extract results and analyze.
@@ How to do it in Python (Recommended)
Python is more powerful for this, especially with the subprocess library for running commands and pandas for processing output files.
1. Prepare the file
Executable: Locate your main executable. This is usually C:\DSSAT47\DSCSM047.EXE (the file name may vary depending on the version, e.g. DSCSM048.EXE for v4.8).
Batch Control File: DSSAT uses a file to know which tests to run, usually DSSBatch.v47 (or .v48, etc.). This file is located in the DSSAT root directory (e.g. C:\DSSAT47\).
Test File (FileX): You must ensure your FileX (.SNX, .WHX, .SCX, etc.) is set up correctly.
2. Python Script
Let's say you already have your test files (FileX) and just want to run them.
Python
import subprocess
import os
# --- 1. Configure path ---
dssat_dir = r"C:\DSSAT47"
# Model executable file name (varies with your version)
dssat_exe = "DSCSM047.EXE"
# Batch file name (varies with your version)
batch_file_name = "DSSBatch.v47"
# --- 2. (Optional) Modify Batch file ---
# The batch file (DSSBatch.v47) should contain the tests you want to run.
# You can use Python to override this file, for example:
# Sample DSSBatch.v47 file content:
# $BATCH(SN)
# ! FILEX TRTNO RP SQ OP CO
# SNX001 1 1 1 1 1
# SNX001 2 1 1 1 1
# Python code to create that file:
batch_content = """$BATCH(SN)
! FILEX TRTNO RP SQ OP CO
SNX001 1 1 1 1 1
SNX001 2 1 1 1 1
""
try:
with open(os.path.join(dssat_dir, batch_file_name), "w") as f:
f.write(batch_content)
except Exception as e:
print(f"Error writing batch file: {e}")
# --- 3. Run the simulation ---
# 'B' is an important flag to tell DSSAT to run in Batch mode
command = [os.path.join(dssat_dir, dssat_exe), "B", batch_file_name]
print(f"Running command: {' '.join(command)}")
# IMPORTANT: Run DSSAT with working directory (cwd) as the root directory of DSSAT
# DSSAT needs this to find weather, soil, etc. files
try:
# subprocess.run() will wait until DSSAT finishes running
result = subprocess.run(
command,
cwd=dssat_dir, # Set working directory
capture_output=True, # Get console output (if any)
text=True,
check=True # Report an error if DSSAT returns an error code
)
print("DSSAT ran successfully!")
# print(result.stdout) # Print output (if needed)
except subprocess.CalledProcessError as e:
print(f"DSSAT ran failed. Error:")
print(e.stderr)
except FileNotFoundError:
print(f"Error: File {dssat_exe} not found at {dssat_dir}")
# --- 4. Read the result ---
# Now you can use pandas to read Summary.OUT
import pandas as pd
summary_path = os.path.join(dssat_dir, "Summary.OUT")
if os.path.exists(summary_path):
# You may need to process the Summary.OUT file to read it properly
# Here is a simple example (may need tweaking)
print(f"Reading results from {summary_path}")
# (Reading the .OUT file can be tricky, usually use pandas' read_fwf)
else:
print(f"The Summary.OUT file was not found. Check if the simulation failed.")
@@ How to do it in MATLAB
Same principle, but you use MATLAB's system() function.
Matlab
% --- 1. Configure the path ---
dssatDir = 'C:\DSSAT47';
% Executable file name (varies by version)
dssatExe = 'DSCSM047.EXE';
% Batch file name (varies by version)
batchFile = 'DSSBatch.v47';
% --- 2. (Optional) Modify Batch File ---
% You can use MATLAB's fopen/fprintf to create/modify DSSBatch.v47 file
% (Similar to Python example)
% --- 3. Run simulation ---
% Save current directory
currentDir = pwd;
% Move to DSSAT directory (IMPORTANT)
cd(dssatDir);
% 'B' is flag for Batch mode
commandToRun = sprintf('"%s" B %s', fullfile(dssatDir, dssatExe), batchFile);
fprintf('Running command: %s\n', commandToRun);
% Call executable
[status, cmdout] = system(commandToRun);
% Return to the original directory
cd(currentDir);
if status == 0
disp('DSSAT run successfully!');
else
disp('DSSAT run failed. Error:');
disp(cmdout);
end
% --- 4. Read the result ---
summaryFile = fullfile(dssatDir, 'Summary.OUT');
if exist(summaryFile, 'file')
disp('Reading results from Summary.OUT...');
% Use readtable, textscan, or dlmread to read the file
% Example:
% T = readtable(summaryFile, 'FileType', 'text', ...); % (Options required)
else
disp('Summary.OUT file not found.');
end
@@ Important points to note
DSSAT version: The executable file name (DSCSM047.EXE) and batch file (DSSBatch.v47) vary by version (e.g. v4.7, v4.8). Check your DSSAT directory.
Working Directory: This is the most common error. DSSAT is very "sensitive" to the location it is run from. You must set the working directory (CWD) to the root directory of DSSAT (e.g. C:\DSSAT47\) before calling the .EXE file. Both examples above have handled this (cwd parameter in Python, cd command in MATLAB).
+Permissions: Make sure your script has write permission to the DSSAT directory (to create the DSSBatch.v47 file) and run the .EXE file. Sometimes you need to run the script as Administrator.
+Input Modification: The real power of this is to use the script to automatically modify the FileX file (e.g. change N amount, planting date) before calling subprocess.run(). This is how you do sensitivity analysis.
@@ Advanced Solution (Python)
If you use Python, there is a library called pydssat that does all the heavy lifting for you. It provides functions to:
- Read and modify FileX easily.
- Automatically find and run DSSAT.
- Read output files (like Summary.OUT, PlantGro.OUT) directly into pandas.DataFrame.
- You can install it with: pip install pydssat
This is the recommended way if you plan to work a lot with Python and DSSAT.
  • asked a question related to Python
Question
8 answers
“Will artificial intelligence put an end to the work of data analysts (SPSS, R, JASP, Jamovi, Python), or will it perform the analysis with its own algorithms and turn everyone into a data analyst?”
Relevant answer
Answer
Dear Tolga Sarıca , It's a great question. AI will not completely replace data analysts; it will transform their role. While AI can automate data cleaning, visualization, and even statistical modeling in tools like SPSS, R, Python, and Jamovi, it cannot replace human judgment in interpreting data or making ethical and strategic decisions. Data analysts understand business context, data limitations, and the story behind numbers-something algorithms alone can’t grasp. In the future, analysts will work alongside AI, using it to speed up routine tasks and focus on insights, problem-solving, and communication. So instead of ending data analysis as a profession, AI is redefining it from data processing to data intelligence.
  • asked a question related to Python
Question
3 answers
I have a problem in math task is to give a
mathematical equation which calculate optimal
solution of 3 rectangle, square shape object we
have there position in (x,y) coordination and there
size is define by length and height (l,g) now task is
give any mathematic eqation which give you
optimal solution without overlapping ech other in
2D dimention and have to minimum space
occupation means want to locate in (x,y) plane
where all the object have least space occupied
and give optimal space solution. now can anyone help to solve this problem with the using the NP-hard problem? or provide mesome guidence to get an idea to solve this with the using python programming,
Relevant answer
Answer
i solve it using cauchy logarithm integral.
its complex to solve in 255 characters. so you can read a work about with the apa:
AVILA CACERES, I. A. (2023). LOS NUMEROS PRIMOS, UNA HISTORIA QUE NO TERMINA.
traslate it and figure out how use integrals to solve optimizing. the work is imcomplete for security reasons. try to understand it the best you can. good day
  • asked a question related to Python
Question
3 answers
I am currently working on optimizing our inventory management system and need to calculate the monthly safety stock for various SKUs. I have already generated weekly safety stock values based on historical data and lead times. However, I need to adjust these values for a monthly period considering several factors:
1. SKU Contribution Ratio: This ratio indicates the importance of each SKU. A higher ratio means the SKU is more critical and should have a higher safety stock.
2. CCF Factor: This factor reflects our past ability to fulfill orders based on historical order and invoice data.
3. Monthly Stock Reduction Percentage: This percentage shows how much stock is typically left at the end of each month. If this value is 100% for four consecutive months, it indicates no need to keep that much inventory for the respective SKU. Conversely, if the values are decreasing, it suggests that the safety stock has been used and needs to be adjusted.
Given these factors, I need to determine a safety factor for the month, which will be used to adjust the weekly safety stock values to monthly values.
Could you suggest scientific methodologies or models that can effectively integrate these factors to calculate the monthly safety stock?
Relevant answer
Answer
To calculate monthly safety stock using SKU contribution ratios, CCF factors, and monthly stock reduction percentages, multiply the SKU’s demand variability or forecast error by its contribution ratio to weight its importance in the inventory pool, adjust this by the CCF factor to capture supply chain uncertainty or criticality, and then factor in the monthly stock reduction percentage to scale safety stock downward or upward based on planned inventory lean-down; the final formula essentially becomes: Safety Stock = (Forecast Error × Contribution Ratio × CCF) × (1 – Reduction %).
  • asked a question related to Python
Question
4 answers
Dear connections, there is a continuous error in VS for any command in the Python package.
Relevant answer
Answer
Thank you, Digonta Chandra Roy, for your response. I will try with the same. and let you know
  • asked a question related to Python
Question
2 answers
I'm building a machine learning model using data from existing papers. Manual extraction is slow, and using large language models requires repeated queries for accuracy. How can I streamline and automate this process for faster, more reliable results?
Relevant answer
Answer
To streamline and automate data extraction from research papers, consider a hybrid approach combining NLP pipelines, structured extraction tools, and quality assurance. Start by using PDF-to-text parsers (e.g., Grobid or ScienceParse) to convert articles into machine-readable formats. Then, apply named-entity recognition (NER) and regular expression patterns to extract key variables, tables, and figures relevant to your model. For repeated queries with large language models, use prompt templates and few-shot learning to improve consistency, and validate outputs against a curated dataset to reduce errors. Finally, integrating these steps into an automated workflow with version control (e.g., using Python scripts or Apache Airflow) allows scalable, reproducible extraction with minimal manual intervention. This approach balances speed with reliability while enabling efficient machine learning model building.
  • asked a question related to Python
Question
3 answers
It is possible here that we suggest new topics that are suitable as research, master’s theses, or doctoral dissertations on the application of artificial intelligence or programming in the Python language on demographic topics or population geography.
Relevant answer
Answer
I actually want research on this topic .
  • asked a question related to Python
Question
1 answer
what do you all think about model development
Relevant answer
Answer
Using Python libraries is easy. First you have to install the required libraries; this will vary according to your operating system, but you can find everything on the net. Second, you have to load the required library at the beginning of your code file. Then you can use it in the proper code syntax. I wish I understood your question correctly.
  • asked a question related to Python
Question
5 answers
How can I normalize a data set of spectrograms using Python coding?
Relevant answer
Answer
Min–Max normalization → scales each spectrogram to [0, 1]
  • asked a question related to Python
Question
4 answers
I am seeking comprehensive book recommendations to build a strong theoretical foundation in several advanced machine learning algorithms for my research. My focus is on understanding the underlying principles and statistical background, and the ultimate goal of implementing these methods in Python.
I am particularly interested in books that cover the following topics:
  1. Feature Selection & Noise Handling (Boruta, MDFS, and Vita)
  2. Imbalanced Data & Resampling Techniques (SMOTE, ENN, AdaSyn, and their hybrids (SMOTETomek, SMOTE-ENN))
  3. Deep Learning Architectures (MLPs, ANNs, DNNs, and CNNs)
  4. Hybrid Models (Hybrid machine learning and Hybrid deep learning models)
Could you suggest any textbooks covers the theory, statistical understanding, and algorithmic design of these topics using Python?
Thank you for your guidance and insights.
Relevant answer
Answer
Machine Learning: A Probabilistic Perspective (2nd edition) by Murphy
  • asked a question related to Python
Question
3 answers
Please share your publicly available transportation project(s) that use R, Python, Julia or other tools.
Relevant answer
Answer
Please do not spam this space with irrelevant responses. I have asked about transportation related open-source projects that people are working on. Please read the question again.
  • asked a question related to Python
Question
5 answers
What free resources (open access books, websites, YouTube channels, etc.) do you use to teach Julia programming language?
Please include hyperlinks in your answer.
Thanks.
Relevant answer
Answer
Rushan Ziatdinov , Some excellent free resources to teach the Julia programming language include the official Julia documentation (https://docs.julialang.org/) and the curated list of open books on the Julia Learning page (https://julialang.org/learning/books/) for foundational reference and advanced study. Julia Data Science (https://juliadatascience.io) is a comprehensive open-access book that integrates teaching on DataFrames, visualization, and reproducible research workflows. Quantitative Economics with Julia (https://julia.quantecon.org/) is a full online textbook that covers numerical methods and economic modeling, suitable for quantitative or scientific computing courses. The MIT 18.S191 Introduction to Computational Thinking course has complete Pluto notebook-based modules and a dedicated YouTube playlist (https://www.youtube.com/playlist?list=PLP8iPy9hna6Q2Kr16aWPOKE0dz9OnsnIJ) making it ideal for classroom or self-guided learners. JuliaCon’s official YouTube channel (https://www.youtube.com/c/TheJuliaLanguage) hosts lectures, tutorials, and workshops from world experts, useful for both introductory classes and specialized topics. The Exercism Julia track (https://exercism.org/tracks/julia) offers free, mentored coding exercises with automatic feedback and is a great resource for homework or skill-building practice.
  • asked a question related to Python
Question
11 answers
Hi everyone,
I'm working on a project where I need to compare the similarity between line curves on two separate charts, and I could use some guidance. Here’s the situation:
  1. First Chart Details: Contains two curves, both of which are moving averages. These curves are drawn on a browser canvas by a user. I have access to the x and y data points of these curves.
  2. Second Chart Details: Contains two curves, with accessible x and y data points. In this chart, the x-axis represents time, and the y-axis represents values.
Challenge:
  • The two charts do not share the same coordinate system values.
Goal:
  • I would like to compare the similarity in patterns between individual lines across the two charts (i.e., one line from the first chart vs. one line from the second chart).
  • Additionally, I want to compare the overall shape formed by both lines on the first chart to the shape formed by both lines on the second chart.
Could anyone provide advice on methodologies or algorithms that could help in assessing the similarity of these line curves?
Thank you for any help.
Lovro Bajc
I have attached
Relevant answer
Answer
@gabriel vinicius.
Yes i did, not sure if it is the best solution but i can present the steps?
  • asked a question related to Python
Question
8 answers
For my project, I am working on DWI data of 150 subjects and obtained connectivity matrices base on fa and adc in the pickle format . The matrix size is 124X124 and to avoid wasting time I need to obtain graph features such as small worldness and centrality using command line for all subjects.
I have worked with gretna, brain connectivity toolbox and BRAPH but as you know these toolboxes work with GUI and it takes a long time to run them for all subjects.
Thanks in advance to your attentions or maybe your helps
Relevant answer
Answer
I used PANTHEON for connectivity analyses. It is a Python toolbox that can be freely downloaded from GitHub. If you have any further questions regarding this, please feel free to contact me.
  • asked a question related to Python
Question
3 answers
I run experiments with optimization models and heuristics across thousands of scenarios, often producing many .txt or .csv outputs. I am looking for concrete workflows and tools to keep this manageable and reproducible.
What do you use to
  • organize runs and configurations
  • track metrics, random seeds, and code versions
  • parse and store large result sets at scale (for example SQLite or Parquet)
  • parallelize on a laptop or on a cluster
  • generate final tables and plots for papers and teaching
Stack I am considering: GAMSPy for modeling inside Python, pandas or polars for data handling. A few months ago I tested Dr. Tim Varelmann’s GAMSPy course and found the single-environment approach promising for research and teaching.
I would appreciate patterns that worked for you and common pitfalls to avoid. Example repositories are very welcome.
Relevant answer
Answer
Model freeze option in GAMSpy may also keep the model in memory and speeds up iterations over various parameter instances
  • asked a question related to Python
Question
3 answers
Importance of data augmentation in AI.
Relevant answer
Answer
Khadersab Adamsab , Data growth techniques such as randaugment and autoauaugment improve model performance by artificially increasing the variety of training data. They apply changes such as rotation, crop, flipping, or color changes, which helps the model to normalize in a better way for ignorant data. By highlighting the model in different versions of the same image, the growth reduces overfiting and prevents it from remembering examples of training. Randaugment simplifies the process by applying a certain number of random changes with controlled magnitude. On the other hand, the autoagment learns optimal growth policies using reinforcement learning, stitching them into a dataset. Overall, these methods improve the strength, accuracy and generalization of deep learning models in various tasks.
  • asked a question related to Python
Question
2 answers
I'm interested in applying Non-equilibrium Thermodynamcis for Glassy Polymer (NET-GP) [1] framework to Statistical Associating Fluid Theory (SAFT) variations. Although the NE-SAFT models were reported multiple times in the literature [2], none of them explained how to do this starting from equilibrium SAFT codes/programmes (such as Matlab, python). The papers generally just write "determined by numerical method" in MATLAB, which doesn't offer too much insights.
The biggest issue (that I can identify) is conventional equilibrium SAFT programmes takes temperature (T) and pressure (P) as independent variables, whereas in the NET-GP framework, the independent variables are instead be temperature (T) and another volume(V)-dependent variables (such as polymer volume or polymer density).
Given this information, how should I modify a conventional SAFT code to produce NE-SAFT? Is there a quick work around this (T,V) dependency? Or, would the only way be rewriting all SAFT equations to take (T,V) as indepedent variables?
Relevant answer
Answer
I’ve encountered the same problems as you. Have you managed to solve them already? If so, would you mind sharing your solutions with me?
  • asked a question related to Python
Question
5 answers
We are pleased to share that our new platform, GRAFFAIN, is now live and freely accessible to researchers.
GRAFFAIN is a Shiny-based web application designed to support AI-assisted qualitative data extraction and visualisation.
GRAFFAIN aims to assist and empower researchers with a no-code platform that simplifies complex workflows and makes high-level visualisations accessible to all.
🔗 Access the platform: https://graffain.com/
We would greatly appreciate your feedback and thoughts on how the tool functions, how it may support your research processes, and any features you'd like to see in the future.
Please feel free to test the platform and share your insights with us in this thread.
Your contributions will help us improve the tool and better serve the research community.
Contributors:
Sait Çüm
Elif Kübra Demir
Tolga Demir
Yasemin Kahyaoğlu Erdoğmuş
Relevant answer
Answer
Dear Madam..
First, thanks for your introductory video.
Thanks and Regards
Dr.Khader
  • asked a question related to Python
Question
2 answers
Hi all
I'm looking to accelerate some python code I have written using JAX just-in-time compilation, specifically using Dawson's integral of the first kind. Somewhat unhelpfully (damn you, SciPy!) the version available from SciPy.special does not work with JAX, so I have been looking for global approximations of high accuracy. My usual go-to implementation for non-python code, which is given in D. Roy's famous 2009 article "Global approximations of some functions", is only accurate to around 1%, which is not enough for my requirements. Does anyone know of a better/more recent implementation that improves on this level of accuracy, whilst remaining truly global (i.e. can be evaluated for any value of x)? Anyone who wants to DM me, please feel to look me up on ResearchGate or LinkedIn and get in touch.
Thanks!
Dave
Relevant answer
Answer
if(x< a) return approximation1; if(x>b) return approximation2; return integral(a,b); // a&b must be optimized to reach the best accuracy-to-speed ratio.
h t t p : / / d o i . o r g / 1 0 . 1 5 1 7 4 / a u . 2 0 1 9 . 2 1 2 4
  • asked a question related to Python
Question
3 answers
machine learning and python in discrete time systems.
Relevant answer
Answer
The convergence of machine learning and control theory is reshaping how we approach system dynamics in complex, uncertain environments—particularly for discrete-time systems where traditional model-based methods face limitations. Classical control design depends on precise mathematical models, which can be difficult to derive for nonlinear systems or scenarios with incomplete data. Machine learning, however, introduces a powerful alternative: data-driven system identification and adaptive control that learns directly from observations, bypassing the need for explicit analytical models.
At the core of this shift is the ability to approximate discrete-time state-space representations from input-output data, enabling control strategies that evolve with system behavior. Reinforcement learning (RL) further enhances this adaptability, allowing controllers to optimize performance through real-time interaction effectively "learning by doing" rather than relying on pre-defined dynamics. Python’s rich ecosystem scikit-learn for regression and classification, TensorFlow/PyTorch for deep learning-based modeling, and Stable-Baselines3 for RL implementations provides the computational tools to translate theory into practice efficiently.
Yet, this integration is not without challenges. While machine learning offers flexibility, it must reconcile with control theory’s rigor ensuring stability, interpretability, and robustness in safety-critical applications. Hybrid approaches, combining data-driven learning with model-based constraints, are emerging as a promising middle ground. For instance, neural networks can approximate system dynamics while Lyapunov-based methods guarantee stability, or RL policies can be trained within physically plausible bounds.
The implications are profound: adaptive controllers that generalize across operating conditions, reduced dependency on idealized models, and faster deployment in scenarios where first-principles modeling is impractical. As this field matures, the collaboration between control theorists and machine learning practitioners will be pivotal balancing innovation with reliability to advance next-generation control systems. The future lies not in replacing classical methods, but in augmenting them with learning-driven adaptability, all while maintaining the mathematical foundations that ensure safe and predictable behavior.
Key Takeaways:
  • Data-driven system identification bypasses the need for explicit analytical models in complex or uncertain environments.
  • Reinforcement learning enables adaptive control policies that optimize through interaction, ideal for nonlinear or evolving systems.
  • Python’s ML ecosystem (scikit-learn, TensorFlow, PyTorch, RL libraries) accelerates prototyping and deployment.
  • Hybrid approaches (learning + stability guarantees) address the trade-offs between flexibility and robustness.
  • The future of control lies in blending model-based rigor with data-driven adaptability, unlocking new capabilities in automation and optimization.
This synergy promises to redefine control systems engineering making it more responsive to real-world complexity while retaining the reliability that industrial applications demand.
  • asked a question related to Python
Question
1 answer
🚀 New Video Alert for Aspiring Quant Traders & RL Enthusiasts! 🎯 How to Build a Custom Trading Environment in OpenAI Gym | Step-by-Step Reinforcement Learning Tutorial 📺 Watch now 👉 https://youtu.be/qSaNqp8Bcy4
Are you ready to bridge the gap between financial markets and AI-driven decision-making?
In this hands-on tutorial, I walk you through: ✅ Building a custom trading environment using OpenAI Gym ✅ Implementing the core mechanics of a market simulation ✅ Preparing your environment for Reinforcement Learning agents ✅ Laying the foundation for your own AI trading bots
Whether you're a data scientist, algorithmic trader, or ML researcher, this tutorial will help you turn theoretical RL concepts into a practical market environment.
🔁 Like | 💬 Comment | 🔗 Share Let’s make finance smarter with AI!
#ReinforcementLearning #TradingBot #OpenAI #Gym #AIinFinance #MachineLearning #Python #QuantFinance #AlgorithmicTrading #CustomEnvironment #RLTrading #YouTubeTutorial
Relevant answer
As an industrial engineer at heart, I found this tutorial particularly compelling — especially in how reinforcement learning (RL) can help identify optimal buy and sell points in financial markets. After your video, I am thinking about the uncertainty or potential for failure. That is why a well-structured and efficiently implemented environment can significantly mitigate risks. And I am excited about using OpenAI Gym for better strategy testing and adaptation over time, even for entrepreneurship in many fields.
Excellent initiative and a great step toward bridging reinforcement learning and practical financial applications!
  • asked a question related to Python
Question
1 answer
DSTools is a Python library designed to assist data scientists and researchers by providing a collection of helpful functions for various stages of a data science project, from data exploration and preprocessing to model evaluation and synthetic data generation.
The library is built upon the author's extensive multi-decade experience (30+ years) in data science, statistical modeling, and enterprise software development. Drawing from real-world challenges encountered across diverse industries including finance, banking, healthcare, insurance, and e-commerce, this toolkit addresses common pain points that practitioners face daily in their analytical workflows.
The development philosophy emphasizes practical utility over theoretical complexity, incorporating battle-tested patterns and methodologies that have proven effective in production environments. Each function and module reflects lessons learned from managing large-scale data projects, optimizing computational performance, and ensuring code maintainability in collaborative team settings.
The library encapsulates best practices developed through years of consulting work, academic research collaborations, and hands-on problem-solving in high-stakes business environments. It represents a distillation of proven techniques, streamlined workflows, and robust error-handling approaches that have evolved through countless iterations and real-world applications.
This comprehensive toolkit serves as a bridge between theoretical data science concepts and practical implementation needs, offering developers and researchers a reliable foundation built on decades of field-tested expertise and continuous refinement based on community feedback and emerging industry requirements. This library with helper functions to accelerate and simplify various stages of the data science research cycle.
This toolkit is built on top of popular libraries like Pandas, Polars, Scikit-learn, Optuna, and Matplotlib, providing a higher-level API for common tasks in Exploratory Data Analysis (EDA), feature preprocessing, model evaluation, and synthetic data generation. It is designed for data scientists, analysts, and researchers who want to write cleaner, more efficient, and more reproducible code.
Relevant answer
Answer
DSTools is a valuable Python library that streamlines many stages of the data science workflow, from data exploration to model evaluation and synthetic data generation. Built on top of widely used libraries like Pandas and Scikit-learn, it offers practical, battle-tested functions derived from decades of real-world experience across multiple industries. This toolkit helps data scientists and researchers write cleaner, more efficient, and reproducible code, addressing common challenges in large-scale data projects.
It’s especially useful for those who want to bridge the gap between theoretical concepts and practical implementation, making it easier to handle tasks such as feature preprocessing, EDA, and hyperparameter optimization with Optuna integration
  • asked a question related to Python
Question
3 answers
Importance of data augmentation in AI.
Relevant answer
Answer
Data augmentation, including methods like RandAugment and AutoAugment, improves model performance by enhancing generalization and reducing overfitting. This is achieved through the following mechanisms:
Data augmentation is an essential component of deep learning. It not only improves generalization, but it is also a core component of many self- and semi-supervised learning algorithms. However, while data augmentation is ubiquitous for training deep neural networks on natural images (i.e., images of human-scale scenes captured by ordinary digital cameras), when it comes to training such models on medical images its proper usage is not as common and clearly understood
Regards,
Shafagat
  • asked a question related to Python
Question
8 answers
Dear researchers.
I have recently started my research in detecting and tracking brain tumors with the help of artificial intelligence, which includes image processing.
What part of this research is valuable, and what do you suggest for the most recent part that is still useful for a PhD. research proposal?
Thank you for participating in this discussion.
Relevant answer
Answer
Your research topic is both valuable and timely. Brain tumor detection and tracking using AI and image processing addresses a high-impact medical challenge where early and accurate diagnosis significantly influences patient outcomes. A good PhD proposal in this area should aim to contribute both clinically and technically.
From a value standpoint, developing robust AI models for segmentation (e.g., identifying tumor boundaries in MRI scans), classification (distinguishing tumor types such as glioma vs. meningioma), and tracking (monitoring tumor progression or regression over time) are all high-impact tasks. Incorporating multi-modal data (e.g., combining T1, T2, FLAIR MRI sequences) increases accuracy and relevance. One valuable direction is explainable AI (XAI), which helps clinicians trust and adopt AI tools by offering interpretable outputs.
For recent and still-evolving areas, consider integrating deep learning architectures such as Vision Transformers (ViTs) or hybrid CNN-RNN models for spatial-temporal analysis of tumor growth. Also, semi-supervised learning or federated learning methods can address the scarcity and sensitivity of labeled medical datasets. Lastly, aligning your research with clinical workflows (e.g., tumor grading, surgical planning) will increase translational impact and relevance for real-world application.
Make sure your proposal includes a clear research question, defined datasets (e.g., BraTS dataset), performance benchmarks, and a plan for validation using clinical expert feedback or prospective studies. Collaboration with a medical institution or hospital will significantly enhance the credibility and applicability of your work.
  • asked a question related to Python
Question
3 answers
’ve come to believe that the most urgent conversations in science, ethics, and innovation are no longer about capability, but about intention.
We know how to build powerful systems: artificial intelligence, global platforms, biotech. But do we know how to build systems that protect the vulnerable, that honour human dignity, and that centre ethical intelligence alongside technical genius?
In my own work at the intersection of mental health, entrepreneurship, and rights (both human and post-human) I’ve seen how intellectual brilliance without empathy creates structures that exclude. Especially for those already marginalised.
That’s why I believe the future needs more than clever minds. It needs courageous ones. Minds that question power. That challenge ego. That embrace feminist principles not as slogans, but as design values: equity, voice, agency, and care.
I’ve always admired those who can lead and listen. Who can take apart systems by morning, and build community by night. And I’m convinced that some of the most visionary thinkers alive today, especially women are working quietly, strategically, and far from the spotlight.
If you're one of those voices I’d be honoured to connect, collaborate, or simply exchange ideas. Some revolutions begin with papers and code. Others begin with one honest conversation between minds willing to see each other clearly.
answer here or send me an email: henrik.arvidsson@viamareconsulting.com
#AIethics #FeministDesign #Neurodiversity #Entrepreneurship #FutureOfRights #MentalHealthInnovation #DeepConversations #LeadershipRedefined
Relevant answer
Answer
Your reflection resonates deeply. I, too, have found that the critical fault line in our age is not the boundary of what we can build, but the clarity of why we build it, and for whom. The question is no longer one of engineering capacity — it's one of ethical direction, epistemic humility, and moral imagination.
In my own work straddling AI ethics, systems design, and philosophical inquiry, I’ve often seen how progress detached from empathy leaves a subtle but profound trail of exclusion. Intelligence without care can produce sleek systems that optimize efficiency while quietly eroding agency, dignity, and voice. And often, those most affected are the very people least included in their creation.
I agree — we don’t just need clever minds; we need minds willing to be vulnerable, critical, and accountable. Feminist principles as design values — equity, care, voice, agency — are not mere philosophical gestures, but the very scaffolding of a livable future. In fact, I believe we are entering an era where moral architecture must precede technical architecture.
Let’s connect. I’d welcome an honest conversation — not about showcasing what we’ve done, but about asking together what still needs to be done, and how we might do it differently. Some systems fail silently because no one had the courage to ask: Whose future are we building, and who is missing from the table?
Warm regards,
Kwan Hong TAN
  • asked a question related to Python
Question
3 answers
I am currently working on an image compression-encryption algorithm that employs the Daubechies wavelet transform (db2) in a quantum computing framework. We have already designed and implemented the quantum version of the Daubechies wavelet transform using Qiskit in Python.
Now, I am looking to simulate the same algorithm in MATLAB. However, I am unsure how to implement the Daubechies wavelet transform (db2), particularly in a way that aligns with our quantum-based design.
If anyone has experience or insights on how to effectively replicate or approximate the quantum Daubechies wavelet transform in MATLAB, your guidance would be greatly appreciated.
Is there any built-in function available in MATLAB for this transformation?
Relevant answer
Answer
I want to use this wavelet transformation for image sparsification purpose before the image data compression using measurement matrix.
  • asked a question related to Python
Question
1 answer
Artificial Neural Network Modeling in combination with Genetic Algorithm is used for the optimization of process parameters. Can anyone provide the python code for ANN-GA.
Relevant answer
Answer
The following Python libraries you'll need, but the exact nature of the optimization of process parameters involved in data is also significant.
  • numpy, matplotlib, scikit-learn: For ANN and data handling
  • deep or genetic algorithm, or pymoo: For GA implementation
  • asked a question related to Python
Question
7 answers
I am currently exploring the application of machine learning (ML) and deep learning (DL) techniques in the healthcare domain, specifically focused on cancer detection and diagnosis. I would like to implement models using Python and am seeking guidance on:
  1. Suitable datasets for different types of cancer (e.g., breast, lung, brain, skin).
  2. Appropriate ML/DL algorithms for classification, segmentation, or survival prediction tasks.
  3. Preprocessing techniques for medical data (e.g., histopathology images, MRI scans, clinical records).
  4. Python libraries and frameworks commonly used (e.g., Scikit-learn, TensorFlow, Keras, PyTorch).
  5. Example projects or GitHub repositories to refer to.
Relevant answer
Answer
Hello, do your database need a large number of small molecule compounds' pharmacological properties and application protocols?
We (MedChemExpress, MCE) have many small molecule drugs and disease-inducing drugs in mainstream fields such as cancer and immunity. For example, the following product information is introduced. If you are willing to cooperate further, please contact us.
The answer to this question comes from MedChemExpress (MCE) Technical Support.
  • asked a question related to Python
Question
18 answers
hi my thesis is about myocardial infarction detection. do you know how to import entire database for simulation of research papers?
Relevant answer
ECG Database on Physionet
Physionet link: https://physionet.org
Files format for ECG databse on Physionet
a) *.atr: Reference Annotation
b) *.dat: Data file (Signal)
c) *.hea: Header file (contains basic info of ECG signal)
MATLAB not compatible for above files format
To read in Matlab
Using WFDB SWIG Toolbox (not easy way): https://physionet.org/content/wfdb-swig-matlab/1.0.0/
Using PhysioNet ATM (easy way) to get ECG signal in MATLAB compatible format (*.mat) : https://archive.physionet,org/cgi-bin/atm/ATM
Proposed Discrete Wavelet Transform(DWT) based Method (Without Deep CNN)
uses undecimated DWT and Symlet4 wavelet for decomposition
  • asked a question related to Python
Question
8 answers
I would like to know if Aspen Plus can be linked with MATLAB or Python?
Relevant answer
  • asked a question related to Python
Question
5 answers
I have prepared a paper on Quantum Algorithm Simulation: Deutsch-Jozsa & Grover Search using Python and QuTiP.
Tell me how to upload my paper.
Relevant answer
Answer
OK, we should probably differentiate two things here:
a) You have already published your paper somewhere else -> do what Peter Breuer said.
b) It is not published yet -> publish first with a real publisher and then upload here assuming RG doesn't add it automatically.
If you only upload a document here without associating it to a serious publisher, you could as well just burn it. Serious researchers will not cite that.
  • asked a question related to Python
Question
5 answers
I want to implement a python code to perform protein protein docking using fast fourier transform in python with visualization of correlation maps for the two grids for educational purposes. i tried to use AI to help me in implementing the code, but the shifts produced make the two proteins away from each other.
this is a link for the receptor protein and the ligand protein with their center of mass set to the origin: https://drive.google.com/drive/folders/17cUuyD3bkfo5sXBn9LQ7dsoeFvvkPfLS
just upload the two files and run the cells to see that the correlation has high values at the corners
Relevant answer
Answer
Hamming tapers the signal at around 0.08 of the signal, which might not be enough. Therefore, trying with a Hanning function might be better.
Additionally, after windowing and before rfftn, the amount of padding is crucial for reducing side effects, the standard padding is size calculation is 2n-1.
  • asked a question related to Python
Question
2 answers
my research is differentiate gbm and cns lymphoma cancer in brain using MRI Scan with deep learning python or matlab could any one help me to do this
Relevant answer
Answer
What problem you are facing? Do you have the dataset?
  • asked a question related to Python
Question
2 answers
I propose the development of an integrated learning platform utilizing Simulink, CODESYS, Python IDLE, and a custom GPT model. This platform will serve multiple educational purposes:
  1. Simulink: Employed for plant modeling.
  2. CODESYS: Utilized for process control.
  3. Python IDLE: Used for tracking learner progress.
  4. :
: Functions as an AI
These components will be interconnected via OPC UA, with CODESYS WebVisu serving as the user interface, which includes an AI tutor
This setup aims to provide students with a seamless transition from modeling and controller design to control loop performance analysis. During their use of the platform, students can seek guidance from the AI tutor on fundamental control theory questions. Additionally, the analytics derived from Python IDLE will help identify areas where students may need further assistance, enabling targeted
Incorporating hardware into this platform could further enhance its utility, offering both virtual and remote lab
Relevant answer
Answer
@Khadersab Adamsab Thanks for your input to this great mission.
  • asked a question related to Python
Question
2 answers
This is basically a Matrix decomposition technique which can be applied to spectroscpic data in order to extract the spectra of the components involved in the reaction that your spectroscopic data represents. At the same time the respective concentration orofiles of those components can also be extracted against a particular variable say like temperature.
Relevant answer
Answer
MCR-ALS is a chemometric technique used to decompose complex multivariate data (like spectroscopic data from chemical mixtures) into a set of "pure" component profiles (e.g., spectra) and their corresponding concentration profiles over time or space. The "alternating least squares" part refers to an iterative optimization algorithm that alternates between estimating the pure component profiles and the concentration profiles until convergence.
Here's a breakdown of how to approach MCR-ALS in MATLAB, Python, and R, along with considerations:
Core Concept of MCR-ALS
Imagine you have a series of measurements (e.g., UV-Vis spectra) taken from a chemical reaction over time. Each spectrum is a mixture of the individual components (reactants, intermediates, products). MCR-ALS aims to:
  • Resolve the pure spectrum of each component.
  • Determine the concentration of each component at every measurement point.
It does this by decomposing the data matrix D (where rows are measurements, columns are variables like wavelength) into the product of a concentration matrix C and a pure component spectra matrix ST:
D=CST
During the iterative process, various constraints can be applied to C and S (e.g., non-negativity, unimodality, closure, known profiles) to ensure physically meaningful solutions and improve convergence.
How to do MCR-ALS in MATLAB, Python, or R
While the core algorithm is the same, the implementation and available libraries vary.
1. MATLAB
MATLAB has a strong history in chemometrics, and it's quite common to find MCR-ALS implementations here.
  • Dedicated Toolboxes:PLS_Toolbox (Eigenvector Research, Inc.): This is the gold standard for chemometrics in MATLAB. It includes a highly robust and feature-rich MCR-ALS function (mcr_als) with extensive options for constraints, cross-validation, and visualization. It's a commercial toolbox, but widely used in industry and academia. Raman Toolbox (e.g., RAMAN_Toolbox): Some specialized toolboxes for spectroscopic data analysis might include MCR-ALS.
  • Custom Implementation:You can certainly implement the MCR-ALS algorithm yourself in MATLAB. This is often done for research or educational purposes to understand the mechanics.Basic Algorithm Steps (Conceptual):Initialize: Estimate initial concentration profiles (C) or pure component spectra (S). This is often done using techniques like PCA, SIMPLISMA, or EFA. Iterate (Alternating Least Squares):Step 1 (Estimate S): Given D and current C, estimate S by solving D = C * S_transpose (e.g., S_transpose = pinv(C) * D). Apply constraints to S. Step 2 (Estimate C): Given D and new S, estimate C by solving D = C * S_transpose (e.g., C = D * pinv(S_transpose)). Apply constraints to C. Repeat until C and S converge (e.g., change in explained variance or profiles falls below a threshold). Evaluate: Check the residuals, explained variance, and plausibility of the resolved profiles. Example (Conceptual MATLAB Code Snippet without actual implementation):Matlab% D: your experimental data matrix (e.g., spectra, time points x wavelengths) % n_components: number of pure components to resolve % 1. Initialization (e.g., using PCA for initial C) % [U, S_val, V] = svd(D); % C_initial = U(:, 1:n_components); % Or use SIMPLISMA etc. % 2. MCR-ALS Iteration % C = C_initial; % for iter = 1:max_iterations % % Solve for S_transpose: D = C * S_transpose => S_transpose = pinv(C) * D % S_transpose = C \ D; % More robust than pinv for least squares % % Apply constraints to S (e.g., non-negativity) % S_transpose(S_transpose < 0) = 0; % Example: non-negativity % % Solve for C: D = C * S_transpose => C = D * pinv(S_transpose) % C = D / S_transpose; % More robust % % Apply constraints to C (e.g., non-negativity, closure, unimodality) % C(C < 0) = 0; % Example: non-negativity % % Check for convergence (e.g., change in C or S, or explained variance) % % if converged, break % end % result_C = C; % result_S = S_transpose'; % Transpose back to get S
2. Python
Python has rapidly become a powerful environment for scientific computing and chemometrics, with several libraries supporting MCR-ALS.
  • PyImSp (Python Imaging Spectroscopy): This library (formerly PyMCR) is specifically designed for MCR-ALS and related techniques, particularly in the context of imaging spectroscopy. It's well-maintained and provides robust implementations of various constraints.Installation: pip install pyimsp Usage:Pythonfrom pyimsp.mcr import MCR import numpy as np import matplotlib.pyplot as plt # Example data (replace with your actual data) # D: your experimental data matrix (rows: observations/time, cols: variables/wavelengths) # For demonstration: create some synthetic data np.random.seed(0) n_observations = 100 n_variables = 50 n_components = 2 # Synthetic pure spectra s1 = np.sin(np.linspace(0, 10, n_variables)) + 1 s2 = np.exp(-np.linspace(0, 5, n_variables)) S_true = np.array([s1, s2]) # Synthetic concentrations c1 = np.linspace(0, 1, n_observations) c2 = 1 - c1 C_true = np.array([c1, c2]).T D = np.dot(C_true, S_true) + np.random.normal(0, 0.1, (n_observations, n_variables)) # Initialize MCR object mcr_obj = MCR(n_components=n_components) # Fit the model mcr_obj.fit(D, st_constraints=[['non_neg']], c_constraints=[['non_neg']]) # Access results C_resolved = mcr_obj.C_opt S_resolved = mcr_obj.ST_opt.T # Transpose back for spectra in rows print("Resolved Concentrations (first 5 rows):\n", C_resolved[:5]) print("\nResolved Spectra (first component):\n", S_resolved[0, :5]) # Plotting (optional) plt.figure(figsize=(12, 5)) plt.subplot(121) plt.plot(C_resolved) plt.title('Resolved Concentrations') plt.xlabel('Observation') plt.ylabel('Concentration') plt.subplot(122) plt.plot(S_resolved.T) # Transpose for plotting spectra plt.title('Resolved Pure Spectra') plt.xlabel('Variable (Wavelength)') plt.ylabel('Intensity') plt.tight_layout() plt.show()
  • sklearn_chemo: This library aims to provide scikit-learn compatible chemometric tools, including MCR-ALS. It's built on top of scikit-learn's conventions.Installation: pip install sklearn-chemo Usage: Similar to pyimsp but follows scikit-learn's fit/transform API.
  • Custom Implementation (using NumPy/SciPy): You can also implement MCR-ALS from scratch using NumPy for array operations and SciPy for linear algebra functions (scipy.linalg.lstsq for least squares, scipy.linalg.pinv for pseudoinverse). This gives you maximum control.
3. R
R is widely used in statistics and increasingly in chemometrics.
  • mdatools package: This is a comprehensive package for multivariate data analysis, including MCR-ALS.Installation: install.packages("mdatools") Usage:Rlibrary(mdatools) library(ggplot2) # For plotting # Example data (replace with your actual data) # D: your experimental data matrix (rows: observations/time, cols: variables/wavelengths) set.seed(0) n_observations <- 100 n_variables <- 50 n_components <- 2 # Synthetic pure spectra s1 <- sin(seq(0, 10, length.out = n_variables)) + 1 s2 <- exp(-seq(0, 5, length.out = n_variables)) S_true <- rbind(s1, s2) # Synthetic concentrations c1 <- seq(0, 1, length.out = n_observations) c2 <- 1 - c1 C_true <- cbind(c1, c2) D <- C_true %*% S_true + matrix(rnorm(n_observations * n_variables, 0, 0.1), nrow = n_observations, ncol = n_variables) # Perform MCR-ALS # Constraints are typically applied during initialization or iteration # Refer to mdatools documentation for detailed constraint options mcr_result <- mcrals(D, ncomp = n_components, c.constr = list(nonneg = TRUE), # Non-negativity for concentrations s.constr = list(nonneg = TRUE)) # Non-negativity for spectra # Access results C_resolved <- mcr_result$c.rec # Reconstructed concentrations S_resolved <- mcr_result$s.rec # Reconstructed spectra (rows are components) cat("Resolved Concentrations (first 5 rows):\n") print(head(C_resolved)) cat("\nResolved Spectra (first component):\n") print(head(S_resolved[1,])) # Plotting (optional) # Convert to data frame for ggplot c_df <- as.data.frame(C_resolved) names(c_df) <- paste0("C", 1:n_components) c_df$Observation <- 1:n_observations ggplot(c_df, aes(x = Observation)) + geom_line(aes(y = C1, color = "Component 1")) + geom_line(aes(y = C2, color = "Component 2")) + labs(title = "Resolved Concentrations", y = "Concentration") + theme_minimal() s_df <- as.data.frame(t(S_resolved)) names(s_df) <- paste0("S", 1:n_components) s_df$Variable <- 1:n_variables ggplot(s_df, aes(x = Variable)) + geom_line(aes(y = S1, color = "Component 1")) + geom_line(aes(y = S2, color = "Component 2")) + labs(title = "Resolved Pure Spectra", y = "Intensity") + theme_minimal()
  • chemometrics package: This is another package with some chemometric functions, though mdatools might be more comprehensive for MCR-ALS.
Key Considerations for MCR-ALS
  • Number of Components (n_components): This is often the most critical parameter. It's usually determined by methods like PCA (looking at explained variance or scree plots), or by prior chemical knowledge.
  • Initialization: The choice of initial C or S can influence the convergence and quality of the solution, especially for noisy or complex data.
  • Constraints: These are crucial for obtaining chemically meaningful and unique solutions. Common constraints include:Non-negativity: Concentrations and absorbances/intensities must be non-negative. Normalization: Sum of concentrations at each time point equals 1 (e.g., for closed systems). Unimodality: Concentration profiles should have a single peak (for certain kinetic processes). Closure: Total concentration is constant. Equality: Known pure spectra or concentration profiles can be fixed. Shape constraints: Specific peak shapes or functional forms.
  • Convergence Criteria: When to stop iterating (e.g., small change in the profiles, minimal change in explained variance, maximum iterations).
  • Local Minima: MCR-ALS is an iterative optimization algorithm and can converge to local minima. Running it multiple times with different initializations can help.
  • Pre-processing: Data often needs pre-processing (e.g., baseline correction, scaling, noise reduction) before MCR-ALS.
  • asked a question related to Python
Question
3 answers
Regular Expressions in NLP Explained! | Power of Patterns
Understanding how text is processed in Natural Language Processing (NLP) often begins with mastering one powerful tool — Regular Expressions (Regex).
🔍 Want to extract specific patterns from text?
🔡 Clean and preprocess large volumes of unstructured data?
💡 Detect trends, emails, hashtags, or even sarcasm?
Regex is the unsung hero behind it all. Whether you're new to NLP or brushing up on text processing techniques, this video breaks it down in a simple, clear, and practical way.
🎥 Watch here:
✅ Perfect for:
NLP & ML beginners
Data Scientists
Python Developers
Anyone curious about the power of pattern matching
Let’s decode the language of text with the power of patterns!
#NLP #Regex #DataScience #MachineLearning #TextProcessing #Python #RegularExpressions #AI #PatternMatching #CleanData #NaturalLanguageProcessing
Relevant answer
Answer
Dear Rahul Jain ,
Natural language processing is a large and multidisciplinary field as it contains infinitely many sentences. NLP began in the 1950s as the intersection of artificial intelligence and linguistics. Also there is much ambiguity in natural language. There are many words which have several meanings, such as can, bear, fly, orange, and sentences have meanings different in different contexts. This makes creation of programs that understands a natural language, a challenging task
Regards,
Shafagat
  • asked a question related to Python
Question
3 answers
NLP Fundamentals | Syntax: Regex, Morphology, Parse Trees & Python Parsing Explained
Understanding language starts with understanding syntax — the structure that gives meaning to words and phrases. In my latest video, we dive deep into some of the most foundational NLP concepts:
✅ Regular Expressions (Regex) in Python ✅ Morphological Analysis ✅ Parse Trees & Syntactic Structure ✅ Python Libraries for Parsing (like NLTK & spaCy)
Whether you're a machine learning engineer, linguist, or just exploring natural language processing, this tutorial will equip you with essential tools to parse and analyze language effectively.
Let me know your thoughts in the comments, and feel free to share with others learning NLP! #NLP #MachineLearning #DataScience #Python #Regex #ParseTrees #NaturalLanguageProcessing #AI #DeepLearning #NLPwithPython
Relevant answer
Answer
Natural Language Processing (NLP) is a subfield of artificial intelligence (AI) that focuses on enabling computers to understand, interpret, and generate human language. At its core, NLP involves breaking down language into its fundamental components and analyzing their relationships. This process relies heavily on understanding syntax, which deals with the structural rules of a language.
Syntax in NLP: The Rules of Language
Syntax refers to the rules governing the structure of sentences and phrases in a language. It's about how words combine to form grammatically correct and meaningful expressions. In NLP, understanding syntax is crucial for tasks like:
  • Grammar Checking: Identifying grammatical errors in text.
  • Machine Translation: Ensuring that translated sentences maintain correct grammatical structure.
  • Information Extraction: Pinpointing specific pieces of information within text by understanding sentence patterns.
  • Sentiment Analysis: Identifying the relationships between words to better understand the overall sentiment.
Let's delve into some key components of syntax in NLP:
1. Regular Expressions (Regex)
Regular Expressions are powerful tools for pattern matching within text. While not a full-fledged syntactic parser, regex is a fundamental building block for many NLP tasks, especially in the initial stages of text processing.
How Regex Works in NLP:
Regex defines search patterns using a sequence of characters. It allows you to:
  • Find specific words or phrases: e.g., finding all occurrences of "cat" or "natural language processing."
  • Extract specific information: e.g., extracting email addresses, phone numbers, or dates from a document.
  • Clean and normalize text: e.g., removing extra spaces, punctuation, or unwanted characters.
  • Tokenization: Splitting text into smaller units (tokens) like words or sentences based on defined delimiters.
Basic Regex Syntax Examples:
  • . (dot): Matches any single character (except newline).
  • * (asterisk): Matches zero or more occurrences of the preceding character or group.
  • + (plus): Matches one or more occurrences of the preceding character or group.
  • ? (question mark): Matches zero or one occurrence of the preceding character or group (makes it optional).
  • [abc]: Matches any one character inside the brackets (a, b, or c).
  • [a-z]: Matches any lowercase letter from a to z.
  • \d: Matches any digit (0-9).
  • \w: Matches any alphanumeric character (letters, numbers, and underscore).
  • ^: Matches the beginning of a string.
  • $: Matches the end of a string.
Example: To find all email addresses, you might use a regex like \b[A-Za-z0-9._%+-]+@[A-Za-z0-9.-]+\.[A-Z|a-z]{2,}\b.
2. Morphology
Morphology is the study of the internal structure of words and how they are formed. It analyzes morphemes, the smallest meaningful units in a language. Understanding morphology helps NLP systems to:
  • Normalize text: Reduce words to their base forms, which is crucial for consistency in analysis.
  • Improve information retrieval: When searching for "run," you might also want to find "running," "runs," or "ran."
  • Enhance machine translation: Accurately translating inflected words.
Key Concepts in Morphology:
  • Morpheme: The smallest unit of meaning.Free Morphemes: Can stand alone as words (e.g., "cat," "run," "happy"). Bound Morphemes: Must be attached to other morphemes (e.g., prefixes like "un-", suffixes like "-s," "-ed," "-ly").
  • Stemming: A process of reducing words to their "stem" or root form by chopping off suffixes (and sometimes prefixes). The stem may not always be a valid word.Example: "running" -> "run", "cats" -> "cat", "happily" -> "happili" (note: "happili" isn't a real word).
  • Lemmatization: A more sophisticated process than stemming that reduces words to their base or dictionary form (lemma). The lemma is always a valid word. It uses vocabulary and morphological analysis.Example: "running" -> "run", "cats" -> "cat", "happily" -> "happy", "better" -> "good".
  • Inflectional Morphology: Deals with grammatical variations of a word that don't change its core meaning or part of speech (e.g., "cat" vs. "cats" for plural, "run" vs. "ran" for tense).
  • Derivational Morphology: Deals with word formation where new words are created from existing ones, often changing their part of speech or meaning (e.g., "happy" -> "happiness," "compute" -> "computer").
3. Parse Trees (Syntactic Parsing)
Parse trees, also known as syntax trees or derivation trees, are hierarchical data structures that visually represent the grammatical structure of a sentence. They show how words are grouped into phrases and how those phrases combine to form a complete sentence according to a particular grammar.
Types of Parse Trees:
  • Constituency Parse Trees (Phrase Structure Grammars):Break down a sentence into its constituent phrases (e.g., Noun Phrase, Verb Phrase). Nodes represent grammatical categories (e.g., S for Sentence, NP for Noun Phrase, VP for Verb Phrase, N for Noun, V for Verb). Terminal nodes (leaves) are the words of the sentence. Example: For "John hit the ball." S (Sentence) NP (Noun Phrase)N (Noun) - John VP (Verb Phrase)V (Verb) - hit NP (Noun Phrase)D (Determiner) - the N (Noun) - ball
  • Dependency Parse Trees:Focus on the grammatical relationships (dependencies) between words. Each word in the sentence (except the root) is linked to another word (its "head") by a directed arc, representing a dependency relation. The arcs are labeled with the type of dependency (e.g., "nsubj" for nominal subject, "obj" for object). Generally simpler and contain fewer nodes than constituency trees. Example: For "John hit the ball." hit (root)John (nsubj of hit) ball (obj of hit)the (det of ball)
Importance of Parse Trees:
  • Understanding Sentence Structure: Provides a formal representation of how words are organized.
  • Ambiguity Resolution: Helps in identifying and resolving structural ambiguities in sentences.
  • Feature Engineering for ML: The structural information from parse trees can be used as features for various NLP machine learning models.
  • Question Answering: Understanding the relationships between words helps in extracting answers from text.
Python Parsing Explained
Python offers powerful libraries for performing NLP tasks, including parsing. The most popular ones are NLTK and spaCy.
1. NLTK (Natural Language Toolkit)
NLTK is a comprehensive library for NLP research and education. It provides a wide range of tools and resources for tasks like tokenization, stemming, lemmatization, Part-of-Speech (POS) tagging, and parsing.
Key NLTK Parsing Features:
  • Tokenization: nltk.word_tokenize(), nltk.sent_tokenize()
  • POS Tagging: nltk.pos_tag()
  • Stemming: nltk.stem.PorterStemmer(), nltk.stem.SnowballStemmer()
  • Lemmatization: nltk.stem.WordNetLemmatizer() (requires WordNet corpus)
  • Constituency Parsing: NLTK allows you to define a grammar using a context-free grammar (CFG) and then parse sentences based on that grammar using parsers like nltk.ChartParser or nltk.RecursiveDescentParser.
NLTK Example (Constituency Parsing):
Python
import nltk # Define a simple grammar grammar = nltk.CFG.fromstring(""" S -> NP VP NP -> Det N | N VP -> V NP Det -> 'the' | 'a' N -> 'cat' | 'dog' | 'boy' | 'ball' V -> 'chased' | 'ate' """) # Create a parser parser = nltk.ChartParser(grammar) sentence = "the cat chased a dog".split() # Parse the sentence for tree in parser.parse(sentence): tree.pretty_print()
This would output a tree-like structure representing the sentence's constituents.
2. spaCy
spaCy is a more modern and production-ready NLP library known for its speed and efficiency. It offers pre-trained models for various languages and provides a streamlined API for common NLP tasks, including tokenization, POS tagging, named entity recognition (NER), and dependency parsing.
Key spaCy Parsing Features:
  • Efficient Tokenization: Automatically handles various tokenization nuances.
  • Statistical Models: Comes with pre-trained statistical models for different languages, enabling highly accurate POS tagging, dependency parsing, and NER out-of-the-box.
  • Dependency Parsing: Provides easy access to dependency relationships between words.
spaCy Example (Dependency Parsing):
Python
import spacy # Load a pre-trained English model nlp = spacy.load("en_core_web_sm") text = "The quick brown fox jumps over the lazy dog." doc = nlp(text) # Iterate over tokens and print dependency information for token in doc: print(f"{token.text} -- {token.lemma_} -- {token.pos_} -- {token.dep_} -- {token.head.text}") # Visualize the dependency tree (requires displacy) # from spacy import displacy # displacy.serve(doc, style="dep")
Output for the spaCy example would look something like:
The -- the -- DET -- det -- fox quick -- quick -- ADJ -- amod -- fox brown -- brown -- ADJ -- amod -- fox fox -- fox -- NOUN -- nsubj -- jumps jumps -- jump -- VERB -- ROOT -- jumps over -- over -- ADP -- prep -- jumps the -- the -- DET -- det -- dog lazy -- lazy -- ADJ -- amod -- dog dog -- dog -- NOUN -- pobj -- over . -- . -- PUNCT -- punct -- jumps
This output shows each word, its lemma (base form), its Part-of-Speech tag, its dependency relation, and its head word in the dependency tree.
Conclusion
Understanding syntax is fundamental to NLP. Regular expressions provide basic pattern matching, morphology delves into word structure, and parse trees offer a hierarchical representation of sentence structure. Python libraries like NLTK and spaCy provide the tools to implement these concepts, enabling computers to process and understand human language with increasing sophistication. As NLP continues to evolve, a strong grasp of these fundamental syntactic concepts will remain essential for building effective language processing applications.
  • asked a question related to Python
Question
1 answer
I am trying to get raw EEG data from Emotive Epoch+ (Latest Version) by using python (emokit and Cykit libraries). But all my approaches have been failed. Is there any way to get raw eeg data from Emotive Epoch+ without using their research SDK? Is it possible to use Emotive Epoch+ for real time data analysis? If it is possible , how will I do it?
Any Information about this will be a great help for me and my teammates.
Thanks in advance.
  • asked a question related to Python
Question
1 answer
Hi everyone, I’d like to ask for advice on how to generate a plot like the one shown in J. Am. Chem. Soc. 2019, 141, 7014−7027. It seems to combine features of both stacked plots and contour plots. I’m wondering whether this can be done using Origin or Python, and if so, how to implement it. Any suggestions or examples would be greatly appreciated!
Relevant answer
Answer
There is "Y-Value: Color Mapping" feature in "Color" drop-down menu in Origin.
  • asked a question related to Python
Question
3 answers
Hi,
I have a protein sequence file (about 14.9 GB) in FASTA format. Each sequence has an ORF ID in the header line. I want to find the KEGG Orthology (KO) IDs that match these ORFs.
Can someone please suggest a tool or workflow that can handle large files and help me map ORF IDs to KO IDs?
Thanks in advance!
Relevant answer
Answer
  • asked a question related to Python
Question
2 answers
Dear ResearchGate Community,
Recently, I shared an article, a source code and a dataset under MIT license. The topic of this paper is about the idea of ​​translation from formal mathematical system Metamath to Python, with the purpose of bridging LLM and the formal mathematical proofs. Article passed the short review of my team-lead who is Ph.D in Mathematics, but we could not find anyone we knew to endorse publication on Arxiv.
I think that the topic can be attributed to both Machine Learning and Artificial Intelligence, so I am attaching the code for both the first and second theme:
and asking you for the endorsement. Feel free to reach out via ResearchGate.
Also, attaching following links:
with good (as it seems to me) readme, if you are interested
Best regards, Pavel Kamenev
Relevant answer
Answer
To publish on arXiv in the cs.LG (Machine Learning) or cs.AI (Artificial Intelligence) categories, you need an endorsement from an established arXiv author. Here’s how to get one:
Steps for Endorsement:
  1. Find an Endorser – Contact: Co-authors/advisors with prior arXiv publications. Researchers in your network (e.g., via LinkedIn, academic email). arXiv moderators (if your work aligns with their expertise).
  2. Request Politely – Share your paper’s abstract and explain its relevance to cs.LG/cs.AI.
  3. Alternative Routes: Publish in a conference/journal first (e.g., NeurIPS, ICML), then submit to arXiv. Use OpenReview (e.g., ICLR submissions) to get feedback before arXiv.
Note:
  • First-time submitters must be endorsed.
  • Endorsers must have ≥5 arXiv submissions in the same category.
  • asked a question related to Python
Question
8 answers
Humor in Philosophy and Ethics
There are many philosophical conundrums in American culture: Why does "slow down" and "slow up" mean the same thing? Why does "fat chance" and "slim chance" mean the same thing? Why do "tug" boats push their barges? Why do we sing "Take me out to the ball game" when we are already there? Why is it called "after dark" when it is really "after light"? Doesn't "expecting the unexpected" make the unexpected expected? Why are a "wise man" and a "wise guy" opposites? Why do "overlook" and "oversee" mean opposite things? Why is “bra” singular and “panties” plural? Why do we drive on a parkway and park on a driveway?
The attached PowerPoint tells what each of the following philosophers have said about humor: Plato (424-348 BCE), Aristotle (384-322 BCE), Cicero (Born in 106 BCE), Seneca (4 BCE-AD 65), St. Thomas Aquinas (1225-1274 A.D.), René Descartes (1595-1650 A.D.), Immanuel Kant (1724-1804), William Spencer (1769-1834), William Hazlitt (1778-1830), Soren Kierkegaard (1813-1855), Friedrich Nietsche (1844-1900), Sigmund Freud (1856-1939), Henri Bergson, (1859-1941), Franz Kafka (1883-1924), Jean-Paul Sartre (1905-1980), and Albert Camus (1913-1960).
John Morreall, a Professor of Religious Studies at William and Mary College points to the philosophical differences associated with having a Comic Vision vs. a Tragic Vision of Life. He also lists these Social Differences and says that most “new” religions promote the Comic Vision.
Anti-Heroism vs. Heroism
Pacifism vs. Militarism
Forgiveness vs. Vengeance
Social Equality vs. Inequality
Questioning vs. Acceptance of Authority
Situation Ethics vs. Duty Ethics
Social Integration vs. Social Isolation
Monte Python’s The Holy Grail:
Monte Python’s The Life of Brian:
Monte Python’s The Meaning of Life:
International Society for Humor Studies: http://www.humorstudies.org/
Relevant answer
Answer
Chris: Good point. Thanks.
  • asked a question related to Python
Question
4 answers
Hello, can I easily convert MATLAB code to Python code? Through a specific website? (Without using AI programs)
Relevant answer
Answer
Hello Ali,
There are some open source tools for that.
But MATLAB provides two-way integration with Python. The MATLAB Engine API for Python (https://www.mathworks.com/help/matlab/matlab-engine-for-python.html) allows you to call MATLAB functions from Python. You can also build Python packages from MATLAB programs by using MATLAB Compiler SDK (https://www.mathworks.com/help/compiler_sdk/python_packages.html)
  • asked a question related to Python
Question
3 answers
Hi, what is the Python equivalent for R step() function of stepwise regression with AIC as criteria?
Is there an existing function in statsmodels.api?
Relevant answer
Answer
My Python functions called stepAIC and stepBIC perform stepwise regression to find the optimum set of predictors to minimize the AIC or BIC, and optionally eliminate non-significant predictors. The stepAIC and stepBIC functions are available at the following github link:
  • asked a question related to Python
Question
6 answers
Hello.
I downloaded sea surface temperature (SST) data from the ERA5 reanalysis products, which has a 3-hour temporal resolution (i.e., 8 times per day).
Naturally, I expect to see different values for different times of day (e.g., 00, 03, 06, 09, etc.), but that’s not the case. For example, the value at 00:00 is 301 K, and at 15:00 it is also 301 K. Why is that?
Moreover, I checked other variables like relative humidity, mean sea level pressure, geopotential, etc. For all of these variables, I do observe different values across different times of day — except for sea surface temperature.
(Just to mention, I am using Python.)
Thank you.
Relevant answer
Answer
Thank you.
  • asked a question related to Python
Question
2 answers
Want to break into Machine Learning but don’t know where to start?
This step-by-step guide is exactly what you need.
✅ Beginner-friendly
✅ Structured roadmap
✅ Covers key concepts, tools & projects
✅ Designed to take you from zero to job-ready
🚀 Just Dropped: The Ultimate Machine Learning Roadmap 🎯
📺 Watch here 👉 https://youtu.be/47wBU-SNulE
Whether you're a student, career switcher, or just curious about ML — this video will give you a clear path forward.
Let’s decode the world of data and algorithms, one step at a time. 💻📊
If you find it helpful, drop a like, share with a friend, or let me know what you'd like to see next!
#MachineLearning #AI #DataScience #LearningPath #MLRoadmap #CareerSwitch #Python #LinkedInLearning #Education #Tech
The Ultimate Machine Learning Roadmap | Step-by-Step Beginner’s Guide
Relevant answer
Answer
Dear Rahul Jain ,
Machine Learning (ML) is one of the most sought-after skills in the tech industry today. Whether you are a beginner looking to get started or an experienced professional aiming to advance, havMachine Learning (ML) is one of the most sought-after skills in the tech industry today. Whether you are a beginner looking to get started or an experienced professional aiming to advance, having a structured roadmap is crucial.
Regards,
Shafagat
  • asked a question related to Python
Question
6 answers
Instead of python or R, what tools can be used to generate heat map for sequencing data?
Relevant answer
Answer
Hi
This is my tool designed specially for gene expression heatmap generation: matheat.org
It is python based and lets you perform several preprocessing options and other post-processing options like pathway enrichment.
  • asked a question related to Python
Question
3 answers
For clarity, I'm processing daily rainfall data from a CORDEX regional climate model.
Relevant answer
Answer
It took a little tweaking but did exactly what I needed it to do.
  • asked a question related to Python
Question
2 answers
HUMOR IN GOTHIC CATHEDRALS: Notre Dame Cathedral is on the Isle de la Cité in Paris France. At the entrance is the sculpture of a beheaded Christian martyr (St. Denis) holding his own head. Winchester Cathedral is a Gothic Cathedral in England. In the rafters is the Winchester Imp, placed there by the masons, and smiling down on the congregation below.
CLASSICAL GRAFFITI AND IRONIC ORATORY: In ancient Greece and Rome, there are examples of graffiti, many of which are very funny. Classical Oratory also contained many examples of Irony, Paradox, Parody, and Ridicule.
HISTORY OF COMEDY: Greek comedies were often bawdy or ribald and ended happily for everyone. To Chaucer, Shakespeare, and other writers of the Middle Ages and Renaissance, a comedy was a story (but especially a play) with a happy ending, whether humorous or not.
OLD COMEDY, MIDDLE COMEDY, AND NEW COMEDY: Old Comedy of the 6th & 5th Centuries BC often made fun of a specific person and of current political issues. Middle Comedy of the 5th & 4thCenturies BC made fun of more general themes such as literature, professions, and society. New Comedy of the 4th& 3rd Centuries BC usually revolved around the bawdy adventures of a blustering soldier, a young man in love with an unsuitable woman, or a father figure who cannot follow his own advice.
COURT JESTERS FROM THE MIDDLE AGES TO THE RENAISSANCE: During the Middle Ages, Kings’ Court Jesters were not to be in competition with the Kings. So most often they were deformed midgets with humped backs and bug eyes. They acted stupidly and wore strange clothing—cap and bells, motley clothes, and pointed shoes. Their scepters were made from pig bladders as parodies of the King’s scepter of power. In many plays, the fool is smarter than the King, but because of his appearance he could be critical of the King and the Kingdom.
FOOLS DURING THE RENAISSANCE AND BEHOND: During the Middle Ages, Kings’ Court Jesters were not to be in competition with the Kings. So most often they were deformed midgets with humped backs and bug eyes. They acted stupidly and wore strange clothing—cap and bells, motley clothes, and pointed shoes. Their scepters were made from pig bladders as parodies of the King’s scepter of power. In many plays, the fool is smarter than the King, but because of his appearance he could be critical of the King and the Kingdom.
THE EIGHTEENTH CENTURY: The eighteenth century saw the rise of a new kind of humorous author: the wit. A wit is usually a person who can make quick, wry comments in the course of conversation. Swift is best known for his novel Gulliver’s Travels in which sailor Lemuel Gulliver recounts his visits to strange lands inhabited by fantastic peoples. Gulliver’s last voyage finds him in a land where horses are the dominant species. They keep dumb, barbaric humans (called Yahoos) as beasts of burden. This novel is a humorous reflection on the failings of civilization.
THE NINETEENTH CENTURY: Jane Austen’s characters are simultaneously true-to-life and ridiculous. All of her novels can simultaneously be read as scorching satires of human nature, comedies of humours and comedies of manners. Charles Dickens is famous for the eccentrics that he portrays in his novels. For example, the characterizations of Silas Wegg and Mr. Venus in Our Mutual Friend make us laugh in delight at the recognition and exaggeration of a ‘type’ of person that we ourselves have met in real life.
THE MID AND LATE NINETEENTH CENTURY: James Russell Lowell’s Birdofreedum Sawin said, “at any rate, I’m so used up I can’t do no more fightin’ / The only chance thet’s left to me is politics or writin’.” On the western frontier, wise fools, con-men, and tricksters like Johnson J. Hooper’s Simon Suggs and George Washington Harris’s Sut Lovingood were employed to portray the rough and unsophisticated American as an ironic hero. Suggs was lazy and dishonest, and he knew it was “good to be shifty in a new country.” The late nineteenth century brought us such writers as Mark Twain, and Oscar Wilde
THE TWENTIETH CENTURY: The twentieth Century brought us suich writers as P. G. Woodehouse, E. B. White, George Orwell, Isaacv Asmov, and Joseph Heller. Such writers developed a contrast between satire (which tells society how to change), and gallows humor (which says that none of us are going to get out of this alive, so lay back and enjoy it).
TELEVISION: Television opened huge new vistas for performing arts in general, and humor in particular. Early TV featured humorous variety shows like Laugh In, and Saturday Night Live (still being aired). There was also much sketch humor in such shows as Monty Python’s Flying Circus.
THE FIRST COMIC STRIPS: The early strips such as “The Yellow Kid” were curious combinations of down-to-earth slapstick, topical joking, and rather abstract referencing. In the hands of a Windsor McCay (“Little Nemo in Slumberland,” “The Adventures of the Rare-bit Fiend,”) they were creative indeed, and could border on the surreal and handle social satire at the same time. George Herriman’s “Krazy Kat” mostly settled on a domestic humor involving marital conflict and bratty kids.
THE GOLD AGE OF HUMOR: The golden age of humor was often considered to be the 1920s but would be more accurately placed from the end of WWI to the early 1930s. During this golden age, we see the development of the “little man” in Casper Milquetoast, Andy Gump, Jiggs, Mutt (of “Mutt and Jeff”), and Dagwood (of “Blondie and Dagwood”).
THE 1940s: The humorous comic strips that were revived after the Second World War included Walt Kelly’s “Pogo,” and Al Capp’s “Li’l Abner.” Kelly’s swamp fables were allegorical ‘swamps’ themselves, loaded with social and political commentary lurking behind the antics and interactions of the familiar cast of animal characters. Al Capp’s “hillbillies” gave access to Capp’s views on topical events, government, and American values.
1950s TO THE PRESENT: THE AGE OF GALLOWS HUMOR AND SKEPTICISM: The “Peanuts” comic strip uses kids to reflect adult neuroses: Lucy uses her meanness to compensate for the unrequited love she has for Schroeder (who keeps trying to play Beethoven on a toy piano with painted-on black keys). Linus has his blanket to comfort him when his childhood fears and fantasy get in the way of his intellect, and the dog, Snoopy, deals with the limitations of his ‘dogness’ by pretending to be the Red Baron, or a lawyer, writer, hockey player, detective or the resident of a deluxe doghouse complete with a pool table and rare paintings. Charlie Brown, the consummate loser, little man character, reflects all the fears, weaknesses, and failures of modern man. He knows that Lucy will pull the football away from him when he tries to kick it, yet every year he tries again.
Relevant answer
Answer
Adnan: I love your response. Very insightful and thought provoking.
  • asked a question related to Python
Question
2 answers
Would you like to create a Python package using simple prompts?
With Pygen, you can easily do it.
Pygen is a system through which you can provide details about your package description and the features you want to include. Pygen will automatically generate a package structure along with a boilerplate code to initiate your package.
The motivation for designing this system is:
  1. To give LLM/Agents the ability to generate their own tools.
  2. If a tool is not available in the arsenal, agents can build their own tools and enhance innovation.
  3. To promote open-source innovation and democratize AI advancement.
Relevant answer
Answer
"Pygen" refers to tools that leverage artificial intelligence, particularly large language models (LLMs), to automate the creation of Python packages from simple prompts. There are a couple of distinct uses of the name Pygen, so I will discuss both.
Here's a breakdown of what Pygen entails:
Key Concepts:
  • Automation of Package Creation:The core idea is to reduce the manual effort involved in setting up and structuring a Python package. This includes generating the necessary files, writing code, and even producing documentation.
  • Prompt-Based Generation:Users provide natural language descriptions of the desired package's functionality. The AI then interprets these prompts and generates the corresponding code.
  • LLM Integration:Large language models are crucial for understanding the user's intent and generating coherent and functional code. These LLM's are also used to generate documentation, which is very helpful.
  • Increased Productivity:Pygen aims to accelerate the development process, allowing developers to focus on higher-level tasks.
Two main uses of the name Pygen that I found:
  • Research Project "PyGen: A Collaborative Human-AI Approach to Python Package Creation"This research project explores the use of LLMs to fully create python packages from user prompts. This is an ongoing research project, and is very interesting for the future of software development.
  • Cognite PygenThis is a tool offered by Cognite, which is used to generate Python SDK's based on data models. This is a tool used in a specific industrial setting.
General Benefits:
  • Accessibility:Pygen can make Python package development more accessible to users with varying levels of coding expertise.
  • Efficiency:Automating repetitive tasks can significantly improve development speed.
  • Standardization:Pygen can help ensure that packages adhere to best practices and coding standards.
  • asked a question related to Python
Question
2 answers
HUMOR IN GOTHIC CATHEDRALS: Notre Dame Cathedral is on the Isle de la Cité in Paris France. At the entrance is the sculpture of a beheaded Christian martyr (St. Denis) holding his own head. Winchester Cathedral is a Gothic Cathedral in England. In the rafters is the Winchester Imp, placed there by the masons, and smiling down on the congregation below.
CLASSICAL GRAFFITI AND IRONIC ORATORY: In ancient Greece and Rome, there are examples of graffiti, many of which are very funny. Classical Oratory also contained many examples of Irony, Paradox, Parody, and Ridicule.
HISTORY OF COMEDY: Greek comedies were often bawdy or ribald and ended happily for everyone. To Chaucer, Shakespeare, and other writers of the Middle Ages and Renaissance, a comedy was a story (but especially a play) with a happy ending, whether humorous or not.
OLD COMEDY, MIDDLE COMEDY, AND NEW COMEDY: Old Comedy of the 6th & 5th Centuries BC often made fun of a specific person and of current political issues. Middle Comedy of the 5th & 4thCenturies BC made fun of more general themes such as literature, professions, and society. New Comedy of the 4th& 3rd Centuries BC usually revolved around the bawdy adventures of a blustering soldier, a young man in love with an unsuitable woman, or a father figure who cannot follow his own advice.
COURT JESTERS FROM THE MIDDLE AGES TO THE RENAISSANCE: During the Middle Ages, Kings’ Court Jesters were not to be in competition with the Kings. So most often they were deformed midgets with humped backs and bug eyes. They acted stupidly and wore strange clothing—cap and bells, motley clothes, and pointed shoes. Their scepters were made from pig bladders as parodies of the King’s scepter of power. In many plays, the fool is smarter than the King, but because of his appearance he could be critical of the King and the Kingdom.
FOOLS DURING THE RENAISSANCE AND BEHOND: During the Middle Ages, Kings’ Court Jesters were not to be in competition with the Kings. So most often they were deformed midgets with humped backs and bug eyes. They acted stupidly and wore strange clothing—cap and bells, motley clothes, and pointed shoes. Their scepters were made from pig bladders as parodies of the King’s scepter of power. In many plays, the fool is smarter than the King, but because of his appearance he could be critical of the King and the Kingdom.
THE EIGHTEENTH CENTURY: The eighteenth century saw the rise of a new kind of humorous author: the wit. A wit is usually a person who can make quick, wry comments in the course of conversation. Swift is best known for his novel Gulliver’s Travels in which sailor Lemuel Gulliver recounts his visits to strange lands inhabited by fantastic peoples. Gulliver’s last voyage finds him in a land where horses are the dominant species. They keep dumb, barbaric humans (called Yahoos) as beasts of burden. This novel is a humorous reflection on the failings of civilization.
THE NINETEENTH CENTURY: Jane Austen’s characters are simultaneously true-to-life and ridiculous. All of her novels can simultaneously be read as scorching satires of human nature, comedies of humours and comedies of manners. Charles Dickens is famous for the eccentrics that he portrays in his novels. For example, the characterizations of Silas Wegg and Mr. Venus in Our Mutual Friend make us laugh in delight at the recognition and exaggeration of a ‘type’ of person that we ourselves have met in real life.
THE MID AND LATE NINETEENTH CENTURY: James Russell Lowell’s Birdofreedum Sawin said, “at any rate, I’m so used up I can’t do no more fightin’ / The only chance thet’s left to me is politics or writin’.” On the western frontier, wise fools, con-men, and tricksters like Johnson J. Hooper’s Simon Suggs and George Washington Harris’s Sut Lovingood were employed to portray the rough and unsophisticated American as an ironic hero. Suggs was lazy and dishonest, and he knew it was “good to be shifty in a new country.” The late nineteenth century brought us such writers as Mark Twain, and Oscar Wilde
THE TWENTIETH CENTURY: The twentieth Century brought us suich writers as P. G. Woodehouse, E. B. White, George Orwell, Isaacv Asmov, and Joseph Heller. Such writers developed a contrast between satire (which tells society how to change), and gallows humor (which says that none of us are going to get out of this alive, so lay back and enjoy it).
TELEVISION: Television opened huge new vistas for performing arts in general, and humor in particular. Early TV featured humorous variety shows like Laugh In, and Saturday Night Live (still being aired). There was also much sketch humor in such shows as Monty Python’s Flying Circus.
THE FIRST COMIC STRIPS: The early strips such as “The Yellow Kid” were curious combinations of down-to-earth slapstick, topical joking, and rather abstract referencing. In the hands of a Windsor McCay (“Little Nemo in Slumberland,” “The Adventures of the Rare-bit Fiend,”) they were creative indeed, and could border on the surreal and handle social satire at the same time. George Herriman’s “Krazy Kat” mostly settled on a domestic humor involving marital conflict and bratty kids.
THE GOLD AGE OF HUMOR: The golden age of humor was often considered to be the 1920s but would be more accurately placed from the end of WWI to the early 1930s. During this golden age, we see the development of the “little man” in Casper Milquetoast, Andy Gump, Jiggs, Mutt (of “Mutt and Jeff”), and Dagwood (of “Blondie and Dagwood”).
THE 1940s: The humorous comic strips that were revived after the Second World War included Walt Kelly’s “Pogo,” and Al Capp’s “Li’l Abner.” Kelly’s swamp fables were allegorical ‘swamps’ themselves, loaded with social and political commentary lurking behind the antics and interactions of the familiar cast of animal characters. Al Capp’s “hillbillies” gave access to Capp’s views on topical events, government, and American values.
1950s TO THE PRESENT: THE AGE OF GALLOWS HUMOR AND SKEPTICISM: The “Peanuts” comic strip uses kids to reflect adult neuroses: Lucy uses her meanness to compensate for the unrequited love she has for Schroeder (who keeps trying to play Beethoven on a toy piano with painted-on black keys). Linus has his blanket to comfort him when his childhood fears and fantasy get in the way of his intellect, and the dog, Snoopy, deals with the limitations of his ‘dogness’ by pretending to be the Red Baron, or a lawyer, writer, hockey player, detective or the resident of a deluxe doghouse complete with a pool table and rare paintings. Charlie Brown, the consummate loser, little man character, reflects all the fears, weaknesses, and failures of modern man. He knows that Lucy will pull the football away from him when he tries to kick it, yet every year he tries again.
Relevant answer
Answer
The evolution of humor over centuries is a fascinating reflection of shifting societal values, technological advancements, and cultural norms. Here's a breakdown of some key changes:
From Ancient Times to the Middle Ages:
  • Early Forms:Early humor was often physical and practical, relying on slapstick, gestures, and simple wordplay. Ancient civilizations like Greece and Rome used humor for social and political commentary, with satire playing a prominent role. In the Middle Ages, humor was often intertwined with religious themes, and court jesters provided social commentary through wit and absurdity.
  • Key shifts: The development of written language allowed for more complex forms of humor, such as satire and wordplay, to flourish.Social hierarchies influenced humor, with different classes having their own distinct forms of comedic expression.
The Renaissance and Enlightenment:
  • Increased Sophistication: The Renaissance saw a revival of classical humor, with playwrights like Shakespeare incorporating wit, wordplay, and social satire into their works. The Enlightenment brought a focus on reason and wit, with satirical writers like Jonathan Swift using humor to critique social and political issues.
  • Key shifts: The printing press increased the accessibility of humorous texts, contributing to the spread of comedic ideas.The rise of secularism led to a shift away from religiously focused humor.
The 19th and 20th Centuries:
  • New Forms of Media:The rise of mass media, including newspapers, magazines, radio, and film, led to the development of new comedic forms, such as stand-up comedy, sitcoms, and animated cartoons. Technological advancements, particularly in film and television, allowed for the widespread dissemination of visual and auditory humor.
  • Changing Sensibilities:Social and political movements influenced humor, with comedians addressing issues such as gender equality, racial discrimination, and political corruption. Humor became increasingly diverse, reflecting the changing demographics and cultural landscape.
  • Key shifts:The growth of mass media democratized humor, making it accessible to wider audiences. Increased social awareness led to a greater sensitivity to offensive humor, with a growing emphasis on inclusivity.
The Digital Age:
  • Internet and Social Media: The internet and social media have revolutionized humor, with memes, viral videos, and online communities creating new forms of comedic expression.Humor has become more immediate and interactive, with people sharing and remixing content in real time.
  • Globalized Humor: The internet has facilitated the exchange of humor across cultures, leading to a more globalized comedic landscape.Humor is now more easily spread, and influenced by a far larger number of sources than ever before.
  • Key shifts: The internet has accelerated the pace of humor, with trends and memes emerging and fading rapidly. The lines between creators and consumers of humor have become blurred, with everyone having the potential to contribute to the comedic landscape.
In essence, humor has evolved alongside society, reflecting our changing values, beliefs, and technologies.
  • asked a question related to Python
Question
6 answers
Hello, fellow researchers and professionals!
I am a logistics and supply chain management student, eager to deepen my technical knowledge and practical skills in the field. I'm particularly interested in hands-on projects that address real-world challenges, such as optimizing last-mile delivery, improving warehouse efficiency, or leveraging data analysis for better inventory forecasting.
I would greatly appreciate your insights, ideas, or recommendations for project topics that could help me enhance my understanding of logistics and supply chain processes. Suggestions involving tools like Python, Excel, simulation software, or even case studies are highly welcome!
Thank you in advance for your valuable contributions. I look forward to learning from your expertise!
Relevant answer
Answer
A logistics student should work on projects like inventory optimization, last-mile delivery solutions, warehouse automation, green logistics, demand forecasting, blockchain in supply chains, reverse logistics, route optimization, cold chain management, and AI-driven supply chain analytics.
  • asked a question related to Python
Question
2 answers
What are the online MD simulation servers available for assessing models generated by Alphafold?
My protein is 680 residues long. I was trying to model it in ITASSER and Alphafold.
The model generated by ITASSER could be subjected to simulation on WebGro but the one generated by ALphafold could not, because it contains "more than 150000 atoms."
Being a complete novice in MD simulations and no experience of Python or other programming languages or interfaces, any suggestions for MD simulation of such large protein structures which could provide me results for Radius of gyration, RMSD and SASA, would be appreciated.
Relevant answer
Answer
If you’re looking to run molecular dynamics (MD) simulations for large protein structures, like those generated by AlphaFold, Here are some options to consider:
1.CHARMM-GUI
This is a user-friendly, web-based platform that helps you set up and run MD simulations. It works well with large systems and integrates seamlessly with popular MD engines like CHARMM, NAMD, GROMACS, and AMBER.
Check it out here: [CHARMM-GUI](https://www.charmm-gui.org)
2.GROMACS Online
If you’re a fan of GROMACS, this cloud-based service is perfect for running simulations on large protein structures. It even offers pre-configured workflows to make your life easier.
Visit their site: [GROMACS](https://www.gromacs.org)
3. **AMBER MD Web Portal**:
AMBER’s web interface is another excellent choice for running MD simulations on large systems. It also provides handy tools for preparing and analyzing your structures.
Explore it here: [AMBER](https://ambermd.org)
4.HADDOCK
While HADDOCK is mainly known for docking, it also supports MD simulations for large protein complexes. It’s a versatile tool worth checking out.
5.MDWeb
This web-based platform uses GROMACS for MD simulations and is designed to handle large structures. It also offers automated workflows to streamline the process.
6.Google Colab with OpenMM
For those who are comfortable with a bit more advanced setup, Google Colab can be a powerful and free option. Using OpenMM, you can run scalable MD simulations for large systems.
These tools should give you options to work with, CHARMM-GUI is great choice Hope it helps :]
  • asked a question related to Python
Question
7 answers
if you have your csv or excel file u ca perform your multiple regression only by uploading it then u get your output
u can get the python file in my repo github (https://github.com/M-nachid/Regression.git)
Relevant answer
Answer
I just said that i made it for the people that they are not familial with python or econometrics ,
I added restrictions in the choose of explanatory variables that it chooses only numeric variables
Essentially thanks for your remarques sir i will take with consediration in the next time
  • asked a question related to Python
Question
1 answer
Hello,
I have been using python library SEMOPY to conduct structural equation modeling for TAM model validation with external factors on ChatGPT adoption.
Unfortunately, I think this model only provides direct effect modeling.
I would like to ask if there would perhaps be reasons to justify the scope of research and explain the value of it if ONLY direct effects are examined, and If there would perhaps be any sources supporting this claim.
Thank you in advance.
Relevant answer
Answer
Follow@
  • asked a question related to Python
Question
3 answers
I am analyzing fatigue behavior in multifunctional composites and need to compute the hysteresis loop area from stress-strain data. My plan is to use numerical integration in Python, considering:
🔹 Trapezoidal Rule (numpy.trapz) 🔹 Simpson’s Rule (scipy.integrate.simps) 🔹 Other advanced numerical techniques?
What’s the best approach for accuracy and efficiency? Have you worked on similar calculations before? Any preferred method for noisy experimental data?
Relevant answer
Answer
Trapezoidal rule is okay however, it's hard to comment without understanding the nature of data.
  • asked a question related to Python
Question
4 answers
...then you might be interested in the `nupaac` package. It contains a `pandas.Series` accessor which acts as a wrapper for the `radioactivedecay` package (written and maintained by Alex Malins) to retrieve data for series containing nuclide strings. Besides acting as a wrapper, the package provides an accessor method to determine specific activities for the listed nuclides and a function to retrieve Inventory(HP) objects.
Have a look at this file to get an impression of the functionality of my package: https://codeberg.org/Cs137/NuPaAc/src/branch/main/tutorial.md
If you find it useful and want to install it, use its latest version from PyPI: https://pypi.org/project/nupaac/
Comments are welcome!
Relevant answer
I recommend using a dedicated virtual environment for nupaac, this will avoid conflicts with packages on your host machine. Since `radioactivedecay` is a dependency of `nupaac`, you can use the virtual env to explore the capabilities of both packages.
There are plenty of different use-cases, have a look at the tutorial file that I linked in the initial post for `nupaac` (https://codeberg.org/Cs137/NuPaAc/src/branch/main/tutorial.md), and for `radioactivedecay` at it's documentation: https://radioactivedecay.github.io/
The latter provides also information about the accuracy and methodology applied to perform decay calculations.
  • asked a question related to Python
Question
4 answers
How effective is Python in plotting XRD when compared to other software like origin and xpert highsquare?
Relevant answer
Answer
I use a program called GSAS II (B.H. Toby and R.B. Von Dreele, J. Appl. Cryst. 46, 544-549 (2013)) for Rietveld analysis of materials using XRD data which is python based. The plotting functions are useful for group presentations but for external presentations or publications my boss prefers plots from Origin. I have used HighScore in the past and find it brilliant for phase ID but again I would use Origin to produce a plot for dissemination.
  • asked a question related to Python
Question
7 answers
I am trying to develop mixed logit model for my data, my data is in the format shown in the image. I am getting errors while running the model like data format, alt name cannot be same as columns etc. in packages like xlogit in python and mlogit, apollo in R
My question is does one need to convert their data into the format shown even if RP data is available and only one specific choice out of few is for each individual.
If the data size is a bit large how does one convert this data to the formal using code.
Also, what happens in the case all my variable are categorical and there is no varing variables across each individual
Relevant answer
Answer
Inès François I am trying to develop mixed logit model for my data, my data is in the format shown in the image. I am getting errors while running the model like Preparing the Data for Analysis—specifically, converting the data for mlogit.
  • asked a question related to Python
Question
3 answers
I am using the open-source Python package, pygfunction, to model a BTES system to meet heating demands in a district heating network. Apart from obtaining fluid temperature profiles inside the borehole and inlet/outlet temperatures, I am interested in investigating the development of temperature outside the bore field in the surrounding soil.
Relevant answer
Answer
Yet another late reply...
It is not possible at the moment - February 2025 - but it will be a feature in v3.0 once it gets released. No idea when that's going to happen.
However, it is not difficult to implement it yourself if you have some understanding of the problem. If you have only vertical boreholes, you can use the infinite line source model. But if you want inclined boreholes, you have to implement the inclined finite line source solution. Even that is fairly simple to do. But this takes effort of course.
  • asked a question related to Python
Question
3 answers
Hi I'm using a dynamic programming tool for my research written in matlab.
However I want to shift my work in python, is it available a open source dynamic programming tool in python?
Where I can find it?
I need to implement a problem defined by 400 lines of code featured by 5 state variables, 4 output variables and 20 input time series.
Thanks!
Relevant answer
Answer
Yes, there are several open-source dynamic programming tools available for Python. One popular library is PuLP, which is used for linear programming and optimization problems, including dynamic programming applications. Another option is Pyomo, a more comprehensive tool that supports optimization problems, including those that can be solved using dynamic programming. NumPy and SciPy also offer useful utilities for implementing custom dynamic programming algorithms, particularly for numerical optimization tasks. These libraries enable users to solve complex problems involving decision-making over time, such as in resource allocation or sequential optimization scenarios.
  • asked a question related to Python
Question
2 answers
Currently I am trying to model plastic packaging waste management scenarios and analyze the effect of interventions at the local level and policy implementation at the macro level. I have reviewed some articles and see that in some cases they have done the ABM and SD model integration using Python. However, I see that software like Anylogic and Stella (to some extent) can also combine these models.
Without considering the license price (Anylogic is more expensive than Stella), I would like to know which of these two software would be more recommendable for this integration purpose.
Relevant answer
Answer
I used anylogic, the tool is good visualization, and powerful to combine the ABM and SD
  • asked a question related to Python
Question
2 answers
Hello everyone,
I have been trying to get VASCo to work for the last couple of weeks with no avail. I have all the required packages and python up-to-date and utilizing the Windows installer it seemed to run right. However, when ever I try to run the TestRun this is the output I receive
C:\Users\MY_NAME\Desktop\VASCo_1.0.2\win>py VASCo.py –testrun
File "C:\Users\MY_NAME\Desktop\VASCo_1.0.2\win\VASCo.py", line 181
print "PPIX Convert Requirements massage"
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
SyntaxError: Missing parentheses in call to 'print'. Did you mean print(...)?
Any suggestions would be wonderful
Relevant answer
Answer
It shows your python file contains coding error. Recheck it again or if you aren't familiar with python syntax, you can use AI application to check for you and fix if any problem would be found.
  • asked a question related to Python
Question
9 answers
I started a new project on ABM for criminology and bumped on GIS and crowds movements. What I need is to simulate the movement of people commuting to work every day in a map extracted from OpenStreetMaps (OMS) platform. I program in Python, so a solution in Python would be ideal (and very convenient) for me. What library/toolbox/guide would you suggest for a newbie in GIS and simulation of crowds?
Relevant answer
Answer
Crowds suck people into a vortex — surprising physicists
Studying crowd dynamics could inform strategies that help to prevent dense gatherings from becoming dangerous...
"In densely-packed crowds, people form swirling ‘vortex’ patterns, with individuals moving in circles. Researchers studied crowds gathered for the famed Feast of San Fermín celebrations in Pamplona, Spain. They found that, as a central plaza filled up in the morning, the crowd reached a critical density of around four people per square metre, beyond which it started — initially very slowly — to form rotating vortices, each involving hundreds of people, that pushed against one another. The vortices completed a rotation in 18 seconds once the plaza reached its maximum density, of around 9 people packed in each square metre..."
  • asked a question related to Python
Question
3 answers
Assuming I want to use Gromacs, what do I need to pull a molecule thorugh a protein. The molecule is already in there, I just need to see if it can freely go from one part to another. I can write a script in python to do it, but I don't know if there is a general procedure or not. A good article about this would help a lot. Is it enough to start pulling an atom? Or all of them? Do I need to pull the protein the other way? Or should I fix the molecule to stay within a box?
Any help is appreciated :D
Relevant answer
Answer
o pull a molecule through a protein in GROMACS:
  1. Use gmx dist to monitor the distance between the molecule and protein over time.
  2. Use gmx pull: Apply a pulling force (e.g., pulling on a heavy atom of the molecule) along a defined axis.
  3. Fix the protein: Keep the protein fixed or restrained, depending on whether you want to pull the molecule through it.
  4. Optionally, pull the protein in the opposite direction if desired.
Check relevant GROMACS documentation or articles on "Pulling simulations" for detailed guidance.
all of which can we easily done at mdsim360.com, a new platform that lets you run MD simulations entirely online without local installation.
  • asked a question related to Python
Question
5 answers
Key skills include proficiency in programming languages ​​such as Python and R, expertise in statistics and mathematics, experience with machine learning algorithms, knowledge of data visualization tools, and strong analytical and problem-solving abilities.
Relevant answer
Answer
Following@
  • asked a question related to Python
Question
1 answer
Hello,
I am using watem-sedem version 5.0.2
I read the Github documentation on how to set up the model and did the tutorial which worked fine. My question is.... How do I format the raster so theres no data values in it? On their page they have "Note
WaTEM/SEDEM does not take nodata values (e.g. -9999) into account. When a nodata value in the DTM raster is encountered, it is considered as an elevation value. Consequently, slopes will be calculated wrongly. Thus, the user must ensure that all pixels in the model domain have an elevation value, and that at least two pixels outside the model domain have a valid elevation value."
I am using ArcGIS Pro, Python, and QGIS for spatial mapping and manipulation. I have a raster shaped like a watershed and there's no data values surrounding it, which is expected. thanks!
Relevant answer
Answer
How about a link to your data source, the extents of your raster ( and other info like cell size ), and even better, a screen shot(s).
  • asked a question related to Python
Question
3 answers
My co-author and I are working on a Python script for automatic family reconstitution using historical civil registration. Currently, we use the Jaro-Winkler algorithm and fuzzy logic to match data (birth, marriage, and death records). While both approaches have their strengths, neither provides perfect results. Has anyone worked on similar challenges and can recommend alternative methods to improve linkage accuracy?
Relevant answer
Answer
Hi dear Szymon Antosik,
I hope this answer find you well. Szymon Antosik
To improve the accuracy of linking historical civil registration data, consider exploring alternative methods like Levenshtein distance for more flexible string matching, or machine learning techniques such as Random Forests or Gradient Boosting Machines, which can incorporate multiple features like dates and locations. Probabilistic record linkage, as implemented in tools like PyRecordLinkage, assigns match probabilities based on various attributes. Additionally, using more contextual information (e.g., birth dates or parental names) and preprocessing steps like blocking or clustering can reduce false matches. Libraries like Dedupe also offer machine learning-powered record linkage, which could help refine your results. Combining these approaches may lead to better overall accuracy.
  • asked a question related to Python
Question
4 answers
A computer program begins its life cycle as text that follows the rules of a selected programming language, such as C#, Java, Python, etc. To decrease costs and improve the performance of the development process, the program text is often organized into autonomous fragments addressing specific responsibilities. There are many design patterns applicable to implementing typical algorithms, but the layered architecture is well-suited to be applied to the program as a whole. The main challenge is understanding the outcomes of applying the layered design pattern to programs, namely to a text compliant with a selected programming language. System architecture and application architecture topics are out of this discussion scope.
Assuming that a program is just text how to implement layered architecture?
Relevant answer
Answer
Define Layers
  • Identify Core Functionality: Determine the essential functions of your system. These will likely form the core layers. Example: In a web application:Presentation Layer: Handles user interface (UI) and user interaction (e.g., HTML, CSS, JavaScript). Application Layer: Contains business logic, coordinates interactions between other layers, and manages application flow (e.g., controllers, services). Domain Layer: Represents core business objects and rules (e.g., entities, value objects, repositories). Infrastructure Layer: Provides supporting services like database access, messaging, and external integrations (e.g., database connectors, message queues).
2. Establish Clear Dependencies
  • Unidirectional Flow: Layers should depend only on layers below them. This creates a clear hierarchy and reduces tight coupling. Example:Presentation Layer depends on Application Layer. Application Layer depends on Domain Layer. Domain Layer depends on Infrastructure Layer.
3. Define Interfaces and Contracts
  • Abstract Interactions: Define interfaces between layers to specify how they interact with each other.
  • Contract Enforcement: Ensure that all interactions adhere to the defined contracts. This improves maintainability and testability.
4. Implement and Test Layers Independently
  • Modular Development: Develop and test each layer in isolation as much as possible.
  • Mock Dependencies: Use mock objects to simulate the behavior of lower-level layers during testing.
5. Example with Python and Flask
Python
# app/__init__.py from flask import Flask from .controllers import main_bp app = Flask(__name__) app.register_blueprint(main_bp) # app/controllers/__init__.py from flask import Blueprint from .main import main_views main_bp = Blueprint('main', __name__) main_bp.add_url_rule('/', view_func=main_views.index, methods=['GET']) # app/controllers/main.py from flask import render_template from app.services import get_user_data def index(): user_data = get_user_data() return render_template('index.html', user_data=user_data) # app/services/__init__.py from app.repositories import UserRepository def get_user_data(): user_repo = UserRepository() user = user_repo.get_user_by_id(1) return user.to_dict() # app/repositories/__init__.py from app.models import User class UserRepository: def get_user_by_id(self, user_id): # Logic to fetch user data from database user = User(id=1, name="John Doe") return user # app/models/__init__.py class User: def __init__(self, id, name): self.id = id self.name = name def to_dict(self): return {'id': self.id, 'name': self.name}
Key Considerations:
  • Trade-offs: Layered architecture can increase complexity. Carefully evaluate the benefits against the potential drawbacks for your specific project.
  • Flexibility: Design your layers to be flexible and adaptable to future changes.
  • Maintainability: Prioritize clear separation of concerns and well-defined interfaces to improve long-term maintainability.
Benefits of Layered Architecture
  • Improved Maintainability: Changes in one layer have minimal impact on other layers.
  • Increased Reusability: Components within a layer can be more easily reused in other parts of the system or even in other projects.
  • Enhanced Testability: Layers can be tested independently, making it easier to identify and isolate bugs.
  • Better Scalability: Layers can be scaled independently to meet changing performance requirements.
  • asked a question related to Python
Question
33 answers
Hello fellow researchers and devs. First of all, I would like to thank you for taking the time to participate in this discussion.
Based on your experience of programming with Python, which IDE do you currently prefer for programming with Python?
In my case and after testing other IDE's for Python like VScode, right now I am using a lot of the Spyder IDE for Python 3, mostly for its quick feedback at the time of experimentation and amazing collaborative github community.
So I would like to know your preferred Python IDE.
Regards.
Relevant answer
Answer
I recommend Visual Studio Code. Its the best
  • asked a question related to Python
Question
1 answer
How to configure HFSS with PyCharm for HFSS Scripting ? Anyone ?
Relevant answer
Answer
1st you have to install HFSS library (HFSS comes with a Python library called (pyaedt)).then open pycham terminal and install it using command like(pip install pyaedt).Create a Python script in PyCharm to test the connection with HFSS
  • asked a question related to Python
Question
1 answer
Hi All,
I am actively seeking research assistant opportunities in molecular biology or bioinformatics. I recently completed my Master’s in Molecular Biology and Bioinformatics and have extensive experience analyzing NGS data and am proficient in Python, R, and Bash scripting. I'm keen on bioinformatics, data analysis, and data science opportunities where I can apply my skills. I'm open to both onsite and offsite opportunities. Any leads will be greatly appreciated. Thanks!
Relevant answer
Answer
A Research Assistant (RA) in Molecular Biology and Bioinformatics often plays a crucial role in conducting experiments, managing data, and supporting the research team. Here’s a breakdown of their typical responsibilities in these fields:
Roles in Molecular Biology
1. Laboratory Work
• Perform experiments like PCR, qPCR, cloning, gel electrophoresis, and Western blotting.
• Maintain and grow cell cultures, perform transfections, and prepare competent cells.
• Extract DNA, RNA, and proteins from various samples.
2. Experimental Design and Optimization
• Assist in designing experiments and troubleshooting protocols.
• Optimize reaction conditions (e.g., PCR, enzyme digestions) for improved efficiency.
3. Data Collection and Analysis
• Record experimental results accurately in lab notebooks or software.
• Use image analysis software (e.g., ImageJ) for Western blot or microscopy data.
4. Lab Maintenance
• Maintain lab stocks, order reagents, and ensure equipment is calibrated.
• Follow safety and compliance protocols (e.g., biosafety level requirements).
5. Documentation and Reporting
• Prepare reports and summaries for supervisors or publications.
• Participate in lab meetings and present findings.
Roles in Bioinformatics
1. Data Management
• Analyze genomic, transcriptomic, or proteomic data.
• Work with large datasets (e.g., RNA-Seq, ChIP-Seq) and databases (e.g., NCBI, Ensembl).
2. Programming and Tools
• Develop or use pipelines for data analysis (e.g., using Python, R, or Bash).
• Work with bioinformatics tools like BLAST, Clustal Omega, or Bioconductor.
3. Visualization
• Create visualizations of data using tools like ggplot2 (R) or Matplotlib (Python).
• Generate heatmaps, volcano plots, or phylogenetic trees.
4. Collaboration
• Work with biologists to interpret results and guide experiments.
• Assist in integrating experimental data with computational findings.
5. Documentation and Reporting
• Write detailed reports and summaries of computational analyses.
• Contribute to manuscripts or grant applications with bioinformatics insights.
Essential Skills
• Molecular Biology: Pipetting accuracy, protocol adherence, and troubleshooting.
• Bioinformatics: Coding skills (Python, R, Linux), data analysis, and visualization.
• Soft Skills: Communication, teamwork, and problem-solving.
  • asked a question related to Python
Question
4 answers
Dear Researcher,
I hope this message finds you well. My professor and I are looking for a skilled and advanced programmer proficient in Python and MATLAB to join our research group. Our focus is on publishing high-quality, Q1 papers in the field of Artificial Intelligence-based Structural Health Monitoring in Civil Engineering.
The ideal candidate should have expertise in:
  • Deep Learning and Machine Learning
  • Signal and Image Processing
  • Optimization Algorithms
  • Coding and Programming with Python/MATLAB
If you are passionate about research, enjoy publishing, and have sufficient time to dedicate to our projects, we would be delighted to invite you to join us.
Please send your CV to hosein_saffaryosefi@alumni.iust.ac.ir .
Best regards, Hossein Safar Yousefifard School of Civil Engineering Iran University of Science and Technology
Relevant answer
Answer
Hossein Safar Yousefifard I have attached my resume below for your review. Please let me know if you need any additional information. Thank you....
  • asked a question related to Python
  • asked a question related to Python
Question
4 answers
Hi I want to do iterative simulation between Sentaurus TCAD and programs like MATLAB or python.
I've made a metal-ferroelectric-metal structure (MFM). I will ramp up the gate voltage with transient command.
so I want to temporarily stop the simluation at each time step. and I want to calculate polarization of ferroelectric material (InsulatorX) based on average z-axis E-field with matlab or python. Then, put the polarization back in the Sentaurus TCAD and go to the next time step based on the polarization. (above simulation will be specifically in sdevice)
but I don't know how to realize it.
there are no commands in sdevice_ug.pdf.
So anyone who knows how to do simulation iteratively btw TCAD and matlab or python, please give me some help.
Thank you
Relevant answer
Answer
import numpy as np
# 1. Read data from Sentaurus TCAD output file
data = np.loadtxt("sentaurus_output.txt")
# 2. Analyze data and calculate new parameter
new_parameter = calculate_new_parameter(data)
# 3. Write new parameter to file
np.savetxt("new_parameter.txt", new_parameter)
# 4. Run Sentaurus TCAD with updated parameter
# (Use a command-line interface or a Python library to interact with Sentaurus TCAD)
  • asked a question related to Python
Question
3 answers
Hi everyone, I am using Autodock and I'm fairly new and unskilled in it. I was performing a protein-ligand dock. I prepared the protein and ligand, saved them in pdbqt, prepared the gpf file and set the autogrind.exe and parameter file for running autogrid. But when I click on launch, it doesnt generate the glg and map files.
I'm not sure if this is of context but when I choose my ligand to set map types, it shows me a warning and a python shell errow, both of which I have attached below,
What should I do? Can anyone help me?
Relevant answer
Answer
im facing the same issue, have you find a way around it?
  • asked a question related to Python
Question
1 answer
  • Standardize data formats during cleaning, using consistent units (e.g., "12 years").
  • Employ automated tools (e.g., Excel macros or software like Python) to detect and correct inconsistencies.
  • Include clear data entry guidelines during collection to prevent inconsistencies. For example, unify entries under a single format, ensuring "12y" and "twelve years" are standardized to "12 years."
Citation: Pyle, D. (1999). Data preparation for data mining. Morgan Kaufmann.
Relevant answer
Answer
To deal inconsistency in data is important for ensuring data quality and consistency in data analysis. Data inconsistencies like missing values, outliers, and irregular arrangements create barriers for effective data analysis; there are a few key strategies:
1. First, determine what factors are causing the inconsistencies. Common sources include human error during data entry, errors in collection systems and instrumentation etc
2. By standardizing data values and representations can help resolve many inconsistencies.
3. To identify outliers, use statistical techniques like the IQR rule or z-scores to identify unusual values then correct, remove, or pick out extreme outliers based on domain knowledge.
4. Use descriptive statistics to detect anomalies like missing values, outliers, or duplicates. These can then be investigated and addressed.
  • asked a question related to Python
Question
7 answers
I analyzed alphafold prediction of receptor and want to docking, previously, I optimized the receptor with openbabel in python but the result wasn't good. I optimized chemical ligand and want to start protein- ligand docking with MD and how to start?
Relevant answer
Answer
First of all, before going towards MD Simulation, you need to Dock your protein with a specific ligand with a protein of interest via Vina, Autodock, etc. After that, you make complexes and go through the process of preprocessing your Complexes and making them ready for MD Simulation via Amber, GROMACS, etc.
If you have any more questions, feel free to ask.
Thank you
  • asked a question related to Python
Question
1 answer
Data Visualization and Tools Explained
In this video, I dive into:
✅ What is Data Visualization?
✅ The importance of telling stories with data.
✅ A breakdown of top tools like Tableau, Power BI, and Python libraries.
✅ Tips to choose the right tool for your needs.
Whether you're a beginner trying to make sense of charts or a pro looking to sharpen your skills, this video has something for everyone! 🌟
Let me know your thoughts, and feel free to share your favorite data visualization tools or tips in the comments! 👇
#DataVisualization #Analytics #DataTools #Tableau #PowerBI #Python
Relevant answer
Answer
Great video Rahul Jain
I've used both Power BI and Tableau, and I like both.
  • asked a question related to Python
Question
5 answers
I am attempting to plot a Boudouard diagram using Python in Google Colab. However, the results do not match the diagrams typically found in textbooks. Could anyone advise on how to obtain accurate thermodynamic data for the calculations and ensure the diagram is correctly drawn? Any suggestions or resources would be greatly appreciated.
The image from and the one I drawn.
Relevant answer
Answer
It seems OK now. I will try to add data from other sources.
  • asked a question related to Python
Question
1 answer
Hello folks, I want to find a simple model to simulate landslide. Do anyone know any software or open source written by python?
Relevant answer
Answer
There are a few open-source tools and models, some of which are implemented in Python, can aid in this process. You can explore following resources may be helpful:
  • PyLandslide is an open-source Python library designed for simulating landslide susceptibility.
  • SHALSTAB is a widely used model for simulating shallow landslides, particularly those triggered by heavy rainfall.
  • LANDSLIP is another tool for simulating and analyzing landslides.
  • The Finite Element Method (FEM) is often used in more complex landslide models, especially when studying slope failure and the mechanics of landslides.
  • GeoPandas is an open-source Python library for working with geospatial data. It is not a landslide simulation tool, still, It might helpful for you.
  • asked a question related to Python
Question
2 answers
Relevant answer
Answer
To provide feedback on your Python package's documentation, I'll need more information. Please share:
  • A link to the documentation: This will allow me to directly assess its clarity, organization, and comprehensiveness.
  • Specific areas of concern: Are you unsure about the clarity of certain sections, the completeness of the examples, or the overall structure?
  • Target audience: Understanding who you're writing for (experienced developers, beginners, etc.) will help me tailor my feedback.
Here are some general tips for writing effective documentation:
Clarity and Conciseness:
  • Clear and concise language: Avoid jargon and technical terms that might confuse users.
  • Well-structured content: Organize information logically, using headings and subheadings to guide the reader.
  • Consistent formatting: Use consistent fonts, colors, and spacing to improve readability.
Comprehensive Content:
  • Installation instructions: Provide detailed instructions for installing the package using pip or other methods.
  • API reference: Document all functions, classes, and modules, including their parameters, return values, and usage examples.
  • Tutorials and examples: Offer step-by-step tutorials and practical examples to help users get started quickly.
  • Troubleshooting guide: Include common issues and solutions to help users resolve problems independently.
User-Friendliness:
  • Search functionality: Implement a robust search feature to help users quickly find information.
  • Interactive elements: Consider using interactive elements like code snippets and interactive demos to enhance the user experience.
  • Cross-referencing: Link to relevant sections within the documentation to improve navigation.
  • asked a question related to Python
Question
6 answers
Hi,
I am trying to find a way to fit Log Pearson3 distribution to my streamflow data but I can't find the way how to! Any tips will be much appreciated. Here is the problem:
Both scipy and lmoment3 packages have Pearson3 but they don't have Log Pearson3 distributions to fit! scipy uses the Maximum Likelihood Estimation (MLE) method to fit the distribution and lmoment3 package fits the distributions by using the l-moment method. But as said, they both only have the Pearson3 distribution among their statistical distributions' list.
I calculate the Annual Maximum Flow (AMF) data which returns a time series of say 50 years of streamflow data. Then I use scipy and lmoment3 packages to fit distributions. I thought if I calculate the log of my AMF and then fit Pearson3 and then calculate the antilog in the end, it would be like fitting Log Pearson3, but it seems like its not! There are differences in how parametrs are being estimated in Pearson3 and Log Pearson3!
and I can't find any proper guide online!
Any thoughts on this?
Relevant answer
Answer
Thank you Asghar Azizian for the revised code. As I see in your recent uploaded code, the scale parameter (after fitting pearson3 on the log transformed data) is not replaced by its exponential value like exp(scale). That is why the quantiles obtained from the log-pearson3 fit is reasonable now. and yes, as you explained, it makes sense to get higher quantiles from lp3 compared to p3, due to their nature and different approaches.
So my conclusion: to fit the log-pearson3, one just needs to get the log transformation of the streamflow data and then fit pearson3, and in the end calculate exponent of the quantiles. No need to further adjust the distribution parameters.
Thank you both Asghar Azizian and Lekia Nkpordee for contributing to this question! Very much appreciate your time and support.
Cheers,
Navid
  • asked a question related to Python
Question
1 answer
Dear friends,
I am a researcher who study on oxides and I am interested in hydrogen bond analysis.
Unfortunately, the most software I can find to perform hydrogen bond analysis only support PDB file. But my common file is XYZ format.
I try ASE and turn my XYZ file into PDB format.
Buy when I load such PDB file in MDtraj python modules, I find the Topology always contain no bonds!
Here is my code.
python will return :<mdtraj.Topology with 1 chains, 1 residues, 96 atoms, 0 bonds>
since no bonds, there is no way to continue to do hydrogen bond analysis.
How can I generate bonds between my interested atoms?
Any advice will be appreciated !
Relevant answer
Answer
PDB files primarily contain atomic coordinates and connectivity information may lack. Visualization tools, such as Chimera, VMD, and PyMOL, infer bonds based on the covalent radii of elements and predefined distance thresholds to determine which atoms are likely bonded. For VMD it is "when VMD is forced to guess the connectivity, it considers a bond to be formed whenever two atoms are within R1*R2*0.6 of each other, where R1 and R2 are the respective radii of candidate atoms."
For further details, refer to this discussion.
  • asked a question related to Python
Question
2 answers
I have amassed decades long data on bird populations and need help in calculating their population trends. There is a great bulk of research published worldwide where a variety of statistical packages (e.g TrendSpotter, rTrim here) were used to index population trends, however, I found none that would do this job using Python. While I have a profficient Python developer, the latter is having hard time deciding on the choice of appropriate statistical methods that could be used to analyse data. Anyone can help?
Relevant answer
Answer
thank you for your feedback
  • asked a question related to Python
Question
2 answers
I am from Egypt and have a strong interest in digital chemistry, particularly cheminformatics. However, there are no academic programs in cheminformatics available in my country. I have a good grasp of Python and have experience with chemistry-related libraries like RDKit and Openbabel.
What steps can I take to build a career in cheminformatics and advance in this field?
Relevant answer
Answer
To build a career in cheminformatics, you can:
  1. Leverage Online Resources: Take online courses in cheminformatics, data science, and machine learning (e.g., Coursera, edX, Udemy).
  2. Master Advanced Python Tools: Deepen your knowledge of RDKit, OpenBabel, and explore other libraries like ChemPy or PySCF.
  3. Engage in Projects: Contribute to open-source cheminformatics projects or create your own, such as building molecular databases or prediction models.
  4. Network with Experts: Join online communities (e.g., ChemRxiv, RDKit mailing list) and attend virtual conferences to learn from professionals.
  5. Pursue Grad Studies: Consider pursuing a master's or PhD in computational chemistry or data science abroad, where cheminformatics is a focus.
  6. Collaborate with Industry: Work on internships or freelance projects related to drug discovery, materials science, or biotechnology.
  7. Stay Updated: Follow journals and blogs like Journal of Cheminformatics to stay up to date with the latest research.
  • asked a question related to Python
Question
1 answer
Hello there! I’m new to Pyansys (APDL),
What I’m want to do is modal analysis of a single piezoelectric piece.
But when I’m try to redisplay the result in APDL (fig.1), it’s different then Workbench (fig.2), although I’ve checked the setting seem to be the same(file.1).
Can anyone explain to me why ? That would be great!
I put the Workbench setup process in the fig.3.
The code for Pyansys (APDL) is as follows
Process outline:
1. Build piezoelectric geometry by using block.
2. Run material_Piezo() to generate piezo material
3. Using vsel & vatt apply the material.
4. Creating mesh.
5. Select nodes by nsel, and use d to all dof = 0
6. Run modal analysis.
from ansys.mapdl.core import launch_mapdl
mapdl = launch_mapdl()
offset_x = 0.01
class Design_Parameter :
def __init__(self , mapdl):
self.mapdl = mapdl
# PZT material properties
self.pzt_mp_desnity = 7400
# permittivity
self.pzt_mp_perx = 2206.4
self.pzt_mp_pery = 2206.4
self.pzt_mp_perz = 1235.13
# stress matrix
self.pzt_mp_e13 = -16.98
self.pzt_mp_e23 = -16.98
self.pzt_mp_e33 = 19.16
self.pzt_mp_e52 = 15.34
self.pzt_mp_e61 = 15.34
# stiffness matris
self.pzt_mp_d11 = 8.0887e10
self.pzt_mp_d21 = 2.4506e10
self.pzt_mp_d22 = 8.0887e10
self.pzt_mp_d31 = 1.876e10
self.pzt_mp_d32 = 1.876e10
self.pzt_mp_d33 = 5.552e10
self.pzt_mp_d44 = 2.819e10
self.pzt_mp_d55 = 2.3204e10
self.pzt_mp_d66 = 2.3204e10
def build_pzt(self , mapdl):
self.mapdl.block(0.001 , 0.002 , 0 + offset_x , 0.06 + offset_x , 0.005 , 0.035)
def element_beam(self , mapdl):
self.mapdl.et (1 , "solid186")
self.mapdl.sectype (1 , "BEAM" , "RECT")
self.mapdl.secdata(0.005 , 0.04 , 2 , 2 )
self.mapdl.secoffset ("CENT")
def material_Aluminum(self , mapdl):
self.mapdl.mp("EX" , 1 , Parameter.beam_mp_elastic_moudulu)
self.mapdl.mp("PRXY" , 1 , Parameter.beam_mp_pusson_ratio)
self.mapdl.mp("DENS" , 1 , Parameter.beam_mp_destiny)
def material_Piezo(self , mapdl):
self.mapdl.et(2 , "solid226" , kop1=1001)
self.mapdl.mp(lab="DENS" , mat="2" , c0=Parameter.pzt_mp_desnity)
# permittivity
self.mapdl.mp(lab="PERX" , mat="2" , c0=Parameter.pzt_mp_perx)
self.mapdl.mp(lab="PERY" , mat="2" , c0=Parameter.pzt_mp_pery)
self.mapdl.mp(lab="PERZ" , mat="2" , c0=Parameter.pzt_mp_perz)
# stress matrix
self.mapdl.tb(lab="PIEZ" , mat="2" , tbopt="0")
self.mapdl.tbdata(stloc='3' , c1=Parameter.pzt_mp_e13)
self.mapdl.tbdata(stloc='6' , c1=Parameter.pzt_mp_e23)
self.mapdl.tbdata(stloc='9' , c1=Parameter.pzt_mp_e33)
self.mapdl.tbdata(stloc='14' , c1=Parameter.pzt_mp_e52)
self.mapdl.tbdata(stloc='16' , c1=Parameter.pzt_mp_e61)
# stiffness matrix
self.mapdl.tb(lab="ANEL" , mat="2" , tbopt="0" , temp="295.15")
self.mapdl.tbdata(stloc="1" , c1=Parameter.pzt_mp_d11 , c2=Parameter.pzt_mp_d21 , c3=Parameter.pzt_mp_d31 , c4=0 , c5=0 , c6=0)
self.mapdl.tbdata(stloc="7" , c1=Parameter.pzt_mp_d22 , c2=Parameter.pzt_mp_d32 , c3=0 , c4=0 , c5=0 ,c6=Parameter.pzt_mp_d33)
self.mapdl.tbdata(stloc="13" , c1=0 , c2=0 , c3=0 , c4=Parameter.pzt_mp_d44 , c5=0 ,c6=0)
self.mapdl.tbdata(stloc="19" , c1=Parameter.pzt_mp_d55 , c2=0 , c3=Parameter.pzt_mp_d66 )
Parameter = Design_Parameter(mapdl)
mapdl.clear()
mapdl.prep7()
mapdl.units("SI")
#---create material---
Parameter.material_Piezo(mapdl)
#---create geometry---
Parameter.build_pzt(mapdl)
mapdl.vsel("ALL")
mapdl.vatt(mat=2 , type_=2)
mapdl.vplot()
mapdl.esize(0.008)
mapdl.vsel("ALL")
mapdl.vsweep("ALL")
#---boundary conditio---
# 1. Face boundary
mapdl.nsel("S" , "LOC" , "Y" , "0.01")
mapdl.d("ALL" , "ALL" , 0)
mapdl.allsel()
mapdl.finish()
mapdl._solution()
mapdl.antype('MODAL')
mapdl.modopt(method="LANB" , nmode=10)
mapdl.solve()
#---post---
mapdl.post1()
result = mapdl.result
for i in range(1, 10): # 使用for loop print 模態頻率
freq = mapdl.get(entity="MODE", entnum=i, item1="FREQ")
print(f"Mode {i}: Frequency = {freq:.2f} Hz")
# ---EXIT---
mapdl.finish()
mapdl.exit()
print(f"All finish!")
Relevant answer
Answer
Did you find the answer? I was having the same issue Kw Lin