Comments (10)
I am looking into this
Ken
from chiantipy.
Try:
defaults=chio.defaultsRead()
and see what you get for the values of the dict 'defaults'
one should be
'ioneqfile': 'chianti',
Ken
from chiantipy.
Hi Ken,
Here is the values of dict
{'abundfile': 'sun_photospheric_2015_scott',
'ioneqfile': 'chianti',
'wavelength': 'angstrom',
'flux': 'energy',
'gui': True}
from chiantipy.
next thing to try:
import ChiantiPy.tools.data as chdata
then chdata.Defaults
should look like what you got with chio.defaultsRead()
so , theck that.
Ken
from chiantipy.
I receive an error this time, similar to the original problem.
import ChiantiPy.tools.data as chdata
----> chdata.Defaults
AttributeError: module 'ChiantiPy.tools.data' has no attribute 'Defaults'
Also, I can add that I am running this in VSCode on macOS, and install ChiantiPy using pip
from chiantipy.
I have never tried VSCode.
can you try this in a Python console, or a jupyter notebook?
Ken
from chiantipy.
does chdata have any attributes such as
Xuvtop
Ip
MasterList
?
Ken
from chiantipy.
Hi, I also try to run it using IPython
Here is some results
In [3]: import os
In [4]: os.environ['XUVTOP'] = '/Users/nawinngampoopun/Desktop/CHIANTI/CHIANTI_10.1_database/'
In [5]: import ChiantiPy.tools.data as chdata
In [6]: chdata.Defaults
AttributeError Traceback (most recent call last)
Cell In[6], line 1
----> 1 chdata.Defaults
AttributeError: module 'ChiantiPy.tools.data' has no attribute 'Defaults'
In [7]: dir(chdata)
Out[7]:
['builtins',
'cached',
'doc',
'file',
'loader',
'name',
'package',
'spec',
'warningregistry',
'chio',
'glob',
'klnames',
'os',
'traceback',
'warnings']
from chiantipy.
Hi Ken,
I have found the problem now. It maybe because I import the ChiantiPy before define os.environ['XUVTOP']. Now the code is working now after I swap the code and restart the kernel and
Thank you for your help!
Nawin
from chiantipy.
glad you found your problem
Ken
from chiantipy.
Related Issues (20)
- Error on running provided jupyter notebooks in the repo HOT 3
- line identifications in spectrum plot HOT 13
- Ability to give custom abundance files HOT 8
- Error while using spectrum with elementList only when all the ions are not present in the masterlist HOT 7
- Unexpected behavior when setting minAbund lower than lowest abund HOT 3
- Error when giving "Zn" in elementlist HOT 2
- How much memory does the mspectrum process consumes? HOT 1
- Chianti is taking more threads than specified HOT 2
- Clarify emission measure units in the function documentations. HOT 2
- Question: Support for photons/keV completed? HOT 10
- Getting spectrum from Ch.spectrum without smoothing/filtering HOT 4
- IDL and ChiantiPy gives different results. HOT 4
- Possible typo in function's documentation HOT 1
- NaNs generated when calculating spectra under certain conditions HOT 9
- Upload 0.15.1 to PyPI HOT 3
- Non-ionization equilibrium? HOT 2
- Two-photon calculation? HOT 1
- Problem with mspectrum? HOT 9
- Unable to import ChiantiPy.core as ch HOT 2
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from chiantipy.