Giter Club home page Giter Club logo

pyscatmech's Issues

M1 Mac problem pySCATMECH implementation

Hi,

I am pretty new to Python and my computer is an M1 Mac. Could anybody help me run pySCATMECH in Python still?

There error I get is;
"Collecting pyscatmech
Using cached pySCATMECH-0.1.0.tar.gz (354 kB)
Preparing metadata (setup.py) ... error
error: subprocess-exited-with-error

× python setup.py egg_info did not run successfully.
│ exit code: 1
╰─> [7 lines of output]
Traceback (most recent call last):
File "", line 2, in
File "", line 34, in
File "/private/var/folders/0c/brm449sn4j539cjpxj46m2yw0000gn/T/pip-install-vynbs0il/pyscatmech_fa8e432ead0c4ae7a60509a3312f0eea/setup.py", line 172, in
extra_compile_args = extra_compile_args,
NameError: name 'extra_compile_args' is not defined
platform.system() = Darwin
[end of output]

note: This error originates from a subprocess, and is likely not a problem with pip.
error: metadata-generation-failed

× Encountered error while generating package metadata.
╰─> See above for output.

note: This is an issue with the package mentioned above, not pip.
hint: See above for details.
(base) o[NAME OF COMPUTER] ~ % "

Does anybody know the solution? You'll have my eternal gratitude!

Cannot find the material in RCW Module

From the website's example, the grating parameters can set by:

gratingParameters = {
None : 'Single_Line_Grating',
'period' : 10,
'medium_i' : 1,
'medium_t' : 'silicon',
'material' : 'silicon',
'space' : 1,
'height' : '0.5',
'topwidth' : '0.4',
'bottomwidth' : '0.15',
'offset' : '0',
'nlevels' : '10'}
But the error show : At SetParameter, SCATMECH: Cannot open file "silicon"

Are there any solution for this error? Or how can I use other parameter to replace the "silicon"?

The "density" parameter does not work in the BV local model

First of all, thank Germer @thomas-germer lot for this useful open source code project, which helped me in my work.

During my using local BRDF model, I found below issue.

particleModel = Local_BRDF_Model("Bobbert_Vlieger_BRDF_Model",parameters)

As for the above model, if we change the value for the 'density' key in the parameters dict, the result(DSC, or cross section) does not change, which I believe should be changed as the MIST sw does.

parameters = {'lambda' : 0.532,
'substrate' : Si,
'type' : 0,
'sphere' : SiO2,
'radius' : diameter/2,
'spherecoat' : spherecoat,
'stack' : stack,
'density': 1,
'delta' : 0,
'lmax' : 0,
'order' : -1,
'Norm_Inc_Approx' : 0,
'improve' : 3}

BTW, the default value for density is 1, but the DSC or cross section result with density=1 does not match with MIST output with the same parameters,

Issue with materials

Hi,
I have pip installed pySCATMECH in windows 10 PC.

I am trying to run the test example code (https://github.com/usnistgov/pySCATMECH/blob/master/tests/testPySCATMECH.py) and it is getting stuck at various materials like silicon, aluminum, gold etc.
Below is a copy of first error which I could resolve by downloading the silicon.txt file in the parent folder.

Is there a way to include other materials as well? How do I download/create these materials library?

`==========================
Testing pySCATMECH.fresnel

Traceback (most recent call last):
File "D:\Python\RCWA\test.py", line 243, in
plt.plot(wavelengths, [silicon(w).real for w in wavelengths], label="Si n")
File "D:\Python\RCWA\test.py", line 243, in
plt.plot(wavelengths, [silicon(w).real for w in wavelengths], label="Si n")
File "C:\Users\K-lab_manish\anaconda3\envs\test\lib\site-packages\pySCATMECH\fresnel.py", line 73, in call
return SCATPY.GetOpticalConstant(wavelength,self.name)
Exception: At GetOpticalConstant, SCATMECH: Cannot open file "silicon.txt"`

Cannot Calculate Jones matrices with RCW and CrossRCW models

In the documentation for the RCW_Model (https://pages.nist.gov/pySCATMECH/rcw.html) and CrossRCW_Model (https://pages.nist.gov/pySCATMECH/crossrcw.html), there is a method for calculating the Jones matrix for a given diffraction order. However, when I try to get the Jones matrix for a default set up, python returns an error:

model = RCW_Model()
print(model.DiffractionAmplitude(0))

AttributeError: 'RCW_Model' object has no attribute 'DiffractionAmplitude'

Using print(dir(model)), I can see that the model has DiffractionEfficiency and Direction as possible methods, but no DiffractionAmplitude method. Am I doing something wrong, or has the Jones matrix method been removed?

Recommend Projects

  • React photo React

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

  • Vue.js photo Vue.js

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

  • Typescript photo Typescript

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

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

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

  • web

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

  • server

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

  • Machine learning

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

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

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

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.