<div dir="ltr"><div class="gmail_default" style="font-family:arial,helvetica,sans-serif">Let me know how it goes.</div><div class="gmail_default" style="font-family:arial,helvetica,sans-serif"><br></div><div class="gmail_default" style="font-family:arial,helvetica,sans-serif">And a clarification: the --full option on `mkprof` doesn&#39;t hurt, but it&#39;s unnecessary since you&#39;re re-parsing the created profile.</div><div class="gmail_default" style="font-family:arial,helvetica,sans-serif"><br></div><div class="gmail_default" style="font-family:arial,helvetica,sans-serif">Also here&#39;s the bug report for the other thing, if you&#39;re interested in that use case: <a href="https://github.com/delph-in/pydelphin/issues/273">https://github.com/delph-in/pydelphin/issues/273</a></div></div><br><div class="gmail_quote"><div dir="ltr" class="gmail_attr">On Fri, Jan 17, 2020 at 10:37 AM Emily M. Bender &lt;<a href="mailto:ebender@uw.edu">ebender@uw.edu</a>&gt; wrote:<br></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 dir="auto">Thanks, Mike! I will give this a try. </div></div><div><br><div class="gmail_quote"><div dir="ltr" class="gmail_attr">On Thu, Jan 16, 2020 at 6:33 PM <a href="mailto:goodman.m.w@gmail.com" target="_blank">goodman.m.w@gmail.com</a> &lt;<a href="mailto:goodman.m.w@gmail.com" target="_blank">goodman.m.w@gmail.com</a>&gt; wrote:<br></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 class="gmail_default" style="font-family:arial,helvetica,sans-serif">Hi Emily,</div><div class="gmail_default" style="font-family:arial,helvetica,sans-serif"><br></div><div class="gmail_default" style="font-family:arial,helvetica,sans-serif">For (2), here is how you could do it with PyDelphin:</div><div class="gmail_default" style="font-family:arial,helvetica,sans-serif"><br></div><div class="gmail_default" style="font-family:arial,helvetica,sans-serif">    delphin process -g grm.dat original-profile/<br></div><div class="gmail_default" style="font-family:arial,helvetica,sans-serif">    delphin mkprof --full --where &#39;readings &gt; 0&#39; --source original-profile/ new-profile/</div><div class="gmail_default" style="font-family:arial,helvetica,sans-serif">    delphin process -g grm.dat --full-forest new-profile/<br></div><div class="gmail_default" style="font-family:arial,helvetica,sans-serif"><br></div><div class="gmail_default" style="font-family:arial,helvetica,sans-serif">Note that original-profile/ is first parsed in regular (non-forest) mode, because in full-forest mode the number of readings is essentially unknown until they are enumerated and thus the &#39;readings&#39; field is always 0. The second command not only prunes lines in the &#39;parse&#39; file with readings == 0, but also lines in the &#39;item&#39; file which correspond to those &#39;parse&#39; lines.  Once you have created new-profile/, you can parse again with --full-forest for use with FFTB (and of course you don&#39;t have to use PyDelphin for the parsing steps, if you prefer other means).<br></div><br><div><div style="font-family:arial,helvetica,sans-serif" class="gmail_default">Also note that this results in a profile with no edges for partial parses. I think this is what you want. There should be a way to prune the full-forest profile directly while keeping partial parses, but while investigating this use case I found a bug, so I don&#39;t recommend it yet.<br></div><br></div><div>Try `delphin mkprof --help` to see descriptions of these and other options. They map fairly directly to the function<span class="gmail_default" style="font-family:arial,helvetica,sans-serif"> </span>documented here: <span class="gmail_default" style="font-family:arial,helvetica,sans-serif"></span><a href="https://pydelphin.readthedocs.io/en/latest/api/delphin.commands.html" target="_blank">https://pydelphin.readthedocs.io/en/latest/api/delphin.commands.html</a><span class="gmail_default" style="font-family:arial,helvetica,sans-serif">#mkprof</span></div><div class="gmail_default" style="font-family:arial,helvetica,sans-serif"><br></div></div><br><div class="gmail_quote"><div dir="ltr" class="gmail_attr">On Fri, Jan 17, 2020 at 8:44 AM Emily M. Bender &lt;<a href="mailto:ebender@uw.edu" target="_blank">ebender@uw.edu</a>&gt; wrote:<br></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">Dear all,<div><br></div><div>We are doing some treebanking here at UW with fftb with grammars that have very low coverage over their associated test corpora. The current behavior of fftb with these profiles is to include all items for treebanking, but give a 404 for each one with no parse forest stored. This necessitates clicking the back button and tracking which one is next (since nothing changes color). In that light, two questions:</div><div><br></div><div>(1) Is there some option we can pass fftb so that it just doesn&#39;t present items with no parses?</div><div>(2) Failing that, is it fairly straightforward with pydelphin, [incr tsdb()] or something else to export a version of the profiles that only includes items which the grammar successfully parsed?</div><div><br></div><div>Thanks,</div><div>Emily</div><div><br></div><div><br></div><div>--<br><div dir="ltr"><div dir="ltr"><div><div dir="ltr"><div><div dir="ltr"><div dir="ltr"><div dir="ltr"><div dir="ltr"><div dir="ltr">Emily M. Bender (she/her)<br>Howard and Frances Nostrand Endowed Professor</div><div dir="ltr"><span style="font-size:12.8px">Department of Linguistics</span></div><div><span style="font-size:12.8px">Faculty Director, CLMS</span></div><div><span style="font-size:12.8px">University of Washington</span></div><div>Twitter: @emilymbender</div></div></div></div></div></div></div></div></div></div></div></div>
</blockquote></div><br clear="all"><br>-- <br><div dir="ltr">-Michael Wayne Goodman</div>
</blockquote></div></div>-- <br><div dir="ltr"><div dir="ltr"><div><div dir="ltr"><div><div dir="ltr"><div dir="ltr"><div dir="ltr"><div dir="ltr"><div dir="ltr">Emily M. Bender (she/her)<br>Howard and Frances Nostrand Endowed Professor</div><div dir="ltr"><span style="font-size:12.8px">Department of Linguistics</span></div><div><span style="font-size:12.8px">Faculty Director, CLMS</span></div><div><span style="font-size:12.8px">University of Washington</span></div><div>Twitter: @emilymbender</div></div></div></div></div></div></div></div></div></div>
</blockquote></div><br clear="all"><br>-- <br><div dir="ltr" class="gmail_signature">-Michael Wayne Goodman</div>