NREL / bifacial_radiance

Toolkit for working with RADIANCE for the ray-trace modeling of Bifacial Photovoltaics
https://bifacial-radiance.readthedocs.io
BSD 3-Clause "New" or "Revised" License
90 stars 48 forks source link

how to solve this error AttributeError: 'ModuleObj' object has no attribute 'modulefile' #369

Closed kush987 closed 2 years ago

kush987 commented 2 years ago

Read all values

New bifacial_radiance simulation starting. Version: 0.4.0+0.g8e40416.dirty path = D:\b=new bif\bifacial_radiance\bifacial_radiance\TEMP analysisParamsDict['modWanted'] set to middle module by default analysisParamsDict['rowWanted'] set to middle row by default d:\b=new bif\bifacial_radiance\bifacial_radiance\main.py:732: FutureWarning: The frame.append method is deprecated and will be removed from pandas in a future version. Use pandas.concat instead. df = df.append(dftemp, ignore_index=True) Getting weather file: USA_AZ_Safford.AWOS.722747_TMY3.epw ... OK! Reading weather file EPWs\USA_AZ_Safford.AWOS.722747_TMY3.epw 8760 line in WeatherFile. Assuming this is a standard hourly WeatherFile for the year for purposes of saving Gencumulativesky temporary weather files in EPW folder. Coercing year to 2021 Saving file EPWs\metdata_temp.csv, # points: 8760 Calculating Sun position for Metdata that is right-labeled with a delta of -30 mins. i.e. 12 is 11:30 sunpos Loading albedo, 1 value(s), 0.620 avg 1 nonzero albedo values. Available module names: ['PrismSolar-Bi60', 'Prism_Solar_Bi60', 'basic-module', 'test-module']

Module Name: Prism_Solar_Bi60 Module Prism_Solar_Bi60 updated in module.json Pre-existing .rad file objects\Prism_Solar_Bi60.rad will be overwritten

Error: module name Prism Solar Bi60 doesnt exist Exception in Tkinter callback Traceback (most recent call last): File "C:\Users\kushal.kumar.conda\envs\bifi\lib\tkinter__init.py", line 1885, in call__ return self.func(*args) File "D:\b=new bif\bifacial_radiance\bifacial_radiance\gui.py", line 390, in runBifacialRadiance self.data, self.analysis = bifacial_radiance.modelchain.runModelChain(simulationParamsDict=simulationParamsDict, File "d:\b=new bif\bifacial_radiance\bifacial_radiance\modelchain.py", line 140, in runModelChain scene = demo.makeScene(module=simulationParamsDict['moduletype'], File "d:\b=new bif\bifacial_radiance\bifacial_radiance\main.py", line 2110, in makeScene self.scene = SceneObj(module) File "d:\b=new bif\bifacial_radiance\bifacial_radiance\main.py", line 2811, in init self.module = ModuleObj(name=module) File "d:\b=new bif\bifacial_radiance\bifacial_radiance\module.py", line 110, in init self._saveModule(savedata=None, json=False, File "d:\b=new bif\bifacial_radiance\bifacial_radiance\module.py", line 276, in _saveModule if rewriteModulefile & os.path.isfile(self.modulefile): AttributeError: 'ModuleObj' object has no attribute 'modulefile

shirubana commented 2 years ago

Kudos on finding our first bug!!

I wonder if it has something to do with the white spaces.. it saves "Prism Solar" but the Json has "Prism_Solar". Maybe while we fix this try using one word, or no spaces or dashes instead of spaces?

kush987 commented 2 years ago

In bifacial repo is there any flat mirror or curve mirrors are using for reflection

On Fri, 4 Feb, 2022, 6:49 pm Silvana Ovaitt, @.***> wrote:

Kudos on finding our first bug!!

I wonder if it has something to do with the white spaces.. it saves "Prism Solar" but the Json has "Prism_Solar". Maybe while we fix this try using one word, or no spaces or dashes instead of spaces?

— Reply to this email directly, view it on GitHub https://github.com/NREL/bifacial_radiance/issues/369#issuecomment-1029978798, or unsubscribe https://github.com/notifications/unsubscribe-auth/AXLHJZSPKWO7FBCFJTBX4VLUZPG5FANCNFSM5NRM33UQ . Triage notifications on the go with GitHub Mobile for iOS https://apps.apple.com/app/apple-store/id1477376905?ct=notification-email&mt=8&pt=524675 or Android https://play.google.com/store/apps/details?id=com.github.android&referrer=utm_campaign%3Dnotification-email%26utm_medium%3Demail%26utm_source%3Dgithub.

You are receiving this because you authored the thread.Message ID: @.***>

shirubana commented 2 years ago

There is mirror material on Radiance, or you can define a new material on bifacial radiance with very high reflectivity (addMaterial function).

The material can be defined for a flat surface or curved one, but specially for the curved surface you are going to have to go into the documentation of Radiance to find the right call and examples. Alternatively you could import a CAD. Our makeModule and makeScene support appended objects (code or cads), but not in the GUI.

Hope this helps

Sent via the Samsung Galaxy S10, an AT&T 5G Evolution capable smartphone Get Outlook for Androidhttps://aka.ms/AAb9ysg


From: Kushal @.> Sent: Friday, February 4, 2022 6:24:52 AM To: NREL/bifacial_radiance @.> Cc: Ayala, Silvana @.>; Comment @.> Subject: Re: [NREL/bifacial_radiance] how to solve this error AttributeError: 'ModuleObj' object has no attribute 'modulefile' (Issue #369)

CAUTION: This email originated from outside of NREL. Do not click links or open attachments unless you recognize the sender and know the content is safe.

In bifacial repo is there any flat mirror or curve mirrors are using for reflection

On Fri, 4 Feb, 2022, 6:49 pm Silvana Ovaitt, @.***> wrote:

Kudos on finding our first bug!!

I wonder if it has something to do with the white spaces.. it saves "Prism Solar" but the Json has "Prism_Solar". Maybe while we fix this try using one word, or no spaces or dashes instead of spaces?

— Reply to this email directly, view it on GitHub https://github.com/NREL/bifacial_radiance/issues/369#issuecomment-1029978798, or unsubscribe https://github.com/notifications/unsubscribe-auth/AXLHJZSPKWO7FBCFJTBX4VLUZPG5FANCNFSM5NRM33UQ . Triage notifications on the go with GitHub Mobile for iOS https://apps.apple.com/app/apple-store/id1477376905?ct=notification-email&mt=8&pt=524675 or Android https://play.google.com/store/apps/details?id=com.github.android&referrer=utm_campaign%3Dnotification-email%26utm_medium%3Demail%26utm_source%3Dgithub.

You are receiving this because you authored the thread.Message ID: @.***>

— Reply to this email directly, view it on GitHubhttps://gcc02.safelinks.protection.outlook.com/?url=https%3A%2F%2Fgithub.com%2FNREL%2Fbifacial_radiance%2Fissues%2F369%23issuecomment-1029983105&data=04%7C01%7Csilvana.ayala%40nrel.gov%7C623e37141162493d697808d9e7e1ba57%7Ca0f29d7e28cd4f5484427885aee7c080%7C0%7C0%7C637795778980882844%7CUnknown%7CTWFpbGZsb3d8eyJWIjoiMC4wLjAwMDAiLCJQIjoiV2luMzIiLCJBTiI6Ik1haWwiLCJXVCI6Mn0%3D%7C3000&sdata=fgw3Nk5a0qN6EU4avdwbRzOQJ81vvy3bq1Ax%2FZGOdYg%3D&reserved=0, or unsubscribehttps://gcc02.safelinks.protection.outlook.com/?url=https%3A%2F%2Fgithub.com%2Fnotifications%2Funsubscribe-auth%2FAFOEOZRWUGK52CURU5LGLZDUZPHSJANCNFSM5NRM33UQ&data=04%7C01%7Csilvana.ayala%40nrel.gov%7C623e37141162493d697808d9e7e1ba57%7Ca0f29d7e28cd4f5484427885aee7c080%7C0%7C0%7C637795778980882844%7CUnknown%7CTWFpbGZsb3d8eyJWIjoiMC4wLjAwMDAiLCJQIjoiV2luMzIiLCJBTiI6Ik1haWwiLCJXVCI6Mn0%3D%7C3000&sdata=eFRPWdSjmRmUEkDT9fMrEzEK9yeKRNvdghEpwMCVoyc%3D&reserved=0. Triage notifications on the go with GitHub Mobile for iOShttps://gcc02.safelinks.protection.outlook.com/?url=https%3A%2F%2Fapps.apple.com%2Fapp%2Fapple-store%2Fid1477376905%3Fct%3Dnotification-email%26mt%3D8%26pt%3D524675&data=04%7C01%7Csilvana.ayala%40nrel.gov%7C623e37141162493d697808d9e7e1ba57%7Ca0f29d7e28cd4f5484427885aee7c080%7C0%7C0%7C637795778980882844%7CUnknown%7CTWFpbGZsb3d8eyJWIjoiMC4wLjAwMDAiLCJQIjoiV2luMzIiLCJBTiI6Ik1haWwiLCJXVCI6Mn0%3D%7C3000&sdata=h1RPzLqE9VrX%2Fq26KlRcvk9TxaX22QlKoJxwSjBEuzU%3D&reserved=0 or Androidhttps://gcc02.safelinks.protection.outlook.com/?url=https%3A%2F%2Fplay.google.com%2Fstore%2Fapps%2Fdetails%3Fid%3Dcom.github.android%26referrer%3Dutm_campaign%253Dnotification-email%2526utm_medium%253Demail%2526utm_source%253Dgithub&data=04%7C01%7Csilvana.ayala%40nrel.gov%7C623e37141162493d697808d9e7e1ba57%7Ca0f29d7e28cd4f5484427885aee7c080%7C0%7C0%7C637795778980882844%7CUnknown%7CTWFpbGZsb3d8eyJWIjoiMC4wLjAwMDAiLCJQIjoiV2luMzIiLCJBTiI6Ik1haWwiLCJXVCI6Mn0%3D%7C3000&sdata=9BzblQa3qe05taB3uKMV9uAKuGEkthnfZrNB14m6KGk%3D&reserved=0. You are receiving this because you commented.Message ID: @.***>