<div dir="ltr">Hi Britton,<br><br>Thank you so much for your reply! I think I understand how LightRay works. What plan_cosmology_splice() does is to choose output redshifts so that comoving distance between them is approximately equal to but less than the comoving box size. So the light ray would not pass through the same structure in one dataset no matter how it travels. Is it right?<br>
<br>Also I would like to add support to the LightRay object for setting a fixed initial position. Since I never modified yt or any other large code before, could you please give me some advice? Is there any documentation or tutorials I could read?<br>
<br>Have a nice day!<br><br>Pengfei<br></div><div class="gmail_extra"><br><br><div class="gmail_quote">2013/9/9 Britton Smith <span dir="ltr"><<a href="mailto:brittonsmith@gmail.com" target="_blank">brittonsmith@gmail.com</a>></span><br>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div dir="ltr"><div><div>Hi Pengfei,<br><br></div>Thank you for catching all of those errors in the source and documentation.  As of now, they have all been fixed and if you do "yt update" the recipe should run as normal without the need to alter anything.<br>

<br></div>I can answer your additional questions here.<br><div class="gmail_extra"><br><div class="gmail_quote"><div class="im"><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex">

<div dir="ltr"><div>(1) What's the initial spectrum before any absorption? </div></div></blockquote><div><br></div></div><div>The spectrum generator only creates absorption features.  Essentially, it assumes that you have already subtracted off the continuum, so effectively the input spectrum is just f(lambda) = 1.0.<br>

</div><div class="im"><div> </div><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex"><div dir="ltr"><div>(2) Where does the light ray originate from? Is it shoot from a random position in the first dataset? Can we set it manually like on the surface of the box? Does it go out of the box and back into it until the next output redshift?</div>

</div></blockquote><div><br></div></div><div>The light ray originates in a random position inside the first dataset with a random trajectory.  This code assumes a periodic domain, so the ray will wrap around if it leaves the box.  Once it has traversed a distance equivalent to the comoving distance to the next dataset, it terminates and begins a new ray there.  Currently, you can not manually set the initial position of a LightRay, but you can also using the ray object (<a href="http://yt-project.org/doc/analyzing/objects.html#available-objects" target="_blank">http://yt-project.org/doc/analyzing/objects.html#available-objects</a>).  If you are interested in adding support to the LightRay object for setting a fixed initial position (and presumably a fixed end position), let me know and I can help you get started.  If you were to do this, we would be very pleased do have you contribute this code back to the main code base.<br>

</div><div class="im"><div> </div><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex"><div dir="ltr">
<div>(3) In the output file lightraysolution.txt, what do the parameters(dl/box, Start x/y/z, End x/y/z) mean?</div></div></blockquote><div><br></div></div><div>Since the start and stop positions are randomly chosen, this file shows what those random positions are for each dataset, in case you want to know that.  dl/box is the fraction of the box length that was used for a ray in that dataset.  For more information on this, I would suggest you check out this page: <br>

<a href="http://yt-project.org/doc/analysis_modules/light_ray_generator.html#light-ray-generator" target="_blank">http://yt-project.org/doc/analysis_modules/light_ray_generator.html#light-ray-generator</a><span class="HOEnZb"><font color="#888888"><br>
</font></span></div><span class="HOEnZb"><font color="#888888"><div><br></div><div>Britton<br>
</div></font></span><div><div class="h5"><div> </div><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex"><div dir="ltr"><div><br></div><div>Sorry that I have so many questions... I wonder if there is some existing documents or paper that have a more detailed description. </div>


<div><br></div><div>Thank you again for your help! Have a nice weekend!</div><span><font color="#888888"><div><br></div><div>Pengfei</div><div><br></div></font></span></div><div><div><div class="gmail_extra">
<br><br><div class="gmail_quote">2013/9/6 Britton Smith <span dir="ltr"><<a href="mailto:brittonsmith@gmail.com" target="_blank">brittonsmith@gmail.com</a>></span><br>
<blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex"><div dir="ltr"><div><div><div><div>Hi Pengfei,<br><br></div>The near_redshift and far_redshift are free parameters for you to set, and just control the redshift interval over which to make the light cone projection.  You might also want to look at the narrative documentation on the light cone generator, which you can find here:<br>



<a href="http://yt-project.org/doc/analysis_modules/light_cone_generator.html" target="_blank">http://yt-project.org/doc/analysis_modules/light_cone_generator.html</a><br></div>Note, that you need to use this with a simulation that made enough data outputs to connect the redshift interval you specify.  The "enzo_tiny_cosmology" dataset available at <a href="http://yt-project.org/data/" target="_blank">http://yt-project.org/data/</a> was configured to work with the light cone recipe in the cookbook, so I would suggest downloading that.<br>



<br></div>As for the error, this is happening because there is a line in your enzo parameter file that contains more than one "=" sign.  I have just submitted a pull request that fixes it, so this should be fixed soon.  In the mean time, you can simply comment out that line in your parameter file and everything should work fine.<br>



<br></div>Britton<br></div><div class="gmail_extra"><br><br><div class="gmail_quote"><div><div>On Fri, Sep 6, 2013 at 3:02 AM, Pengfei Chen <span dir="ltr"><<a href="mailto:madcpf@gmail.com" target="_blank">madcpf@gmail.com</a>></span> wrote:<br>



</div></div><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex"><div><div><div dir="ltr">Hi all,<br><br>I downloaded the example script of light cone projectoin(<a href="http://yt-project.org/doc/cookbook/cosmological_analysis.html#light-cone-projection" target="_blank">http://yt-project.org/doc/cookbook/cosmological_analysis.html#light-cone-projection</a>) to my laptop and changed the Enzo simulation parameter file and redshifts. But when I ran it the following error occurred:<br>




<br>  File "light_cone_projection.py", line 19, in <module><br>    find_outputs=False)<br>  File "/Users/madcpf/Documents/dev_yt/src/yt-hg/yt/analysis_modules/cosmological_observation/light_cone/light_cone.py", line 158, in __init__<br>




    find_outputs=find_outputs)<br>  File "/Users/madcpf/Documents/dev_yt/src/yt-hg/yt/analysis_modules/cosmological_observation/cosmology_splice.py", line 44, in __init__<br>    find_outputs=find_outputs)<br>  File "/Users/madcpf/Documents/dev_yt/src/yt-hg/yt/convenience.py", line 131, in simulation<br>




    find_outputs=find_outputs)<br>  File "/Users/madcpf/Documents/dev_yt/src/yt-hg/yt/frontends/enzo/simulation_handling.py", line 81, in __init__<br>    find_outputs=find_outputs)<br>  File "/Users/madcpf/Documents/dev_yt/src/yt-hg/yt/data_objects/time_series.py", line 343, in __init__<br>




    self._parse_parameter_file()<br>  File "/Users/madcpf/Documents/dev_yt/src/yt-hg/yt/frontends/enzo/simulation_handling.py", line 273, in _parse_parameter_file<br>    param, vals = (i.strip() for i in line.split("="))<br>




ValueError: need more than 1 value to unpack<br><br>Does the parameters "near_redshift" and "far_redshift" in LightCone need to be the same with "CosmologyFinalRedshift" and "CosmologyInitialRedshift" in enzo parameter file?<br>




Does anyone know how to solve this?<br><br>Thank you all!<span><font color="#888888"><br><br>Pengfei<br></font></span></div>
<br></div></div>_______________________________________________<br>
yt-users mailing list<br>
<a href="mailto:yt-users@lists.spacepope.org" target="_blank">yt-users@lists.spacepope.org</a><br>
<a href="http://lists.spacepope.org/listinfo.cgi/yt-users-spacepope.org" target="_blank">http://lists.spacepope.org/listinfo.cgi/yt-users-spacepope.org</a><br>
<br></blockquote></div><br></div>
<br>_______________________________________________<br>
yt-users mailing list<br>
<a href="mailto:yt-users@lists.spacepope.org" target="_blank">yt-users@lists.spacepope.org</a><br>
<a href="http://lists.spacepope.org/listinfo.cgi/yt-users-spacepope.org" target="_blank">http://lists.spacepope.org/listinfo.cgi/yt-users-spacepope.org</a><br>
<br></blockquote></div><br></div>
</div></div><br>_______________________________________________<br>
yt-users mailing list<br>
<a href="mailto:yt-users@lists.spacepope.org" target="_blank">yt-users@lists.spacepope.org</a><br>
<a href="http://lists.spacepope.org/listinfo.cgi/yt-users-spacepope.org" target="_blank">http://lists.spacepope.org/listinfo.cgi/yt-users-spacepope.org</a><br>
<br></blockquote></div></div></div><br></div></div>
<br>_______________________________________________<br>
yt-users mailing list<br>
<a href="mailto:yt-users@lists.spacepope.org">yt-users@lists.spacepope.org</a><br>
<a href="http://lists.spacepope.org/listinfo.cgi/yt-users-spacepope.org" target="_blank">http://lists.spacepope.org/listinfo.cgi/yt-users-spacepope.org</a><br>
<br></blockquote></div><br></div>