Sprite - Corpse (Including Variants)

SPRITE - CORPSE

@LatentArchitect @SpicySoju2k20 we need a generic corpse sprite or potentially a few variants. It doesn't necessarily have to be a "corpse" but what this object will be is the thing that spawns when the enemy dies so that you know you can loot them and also so that you have the reminder that the room was an "enemy room"

TASKS

[x] Sprite - player character corpse
[ ] Sprite - enemy corpse

[x] Sprite-Variant - 1
[x] Sprite-Variant - 2
[ ] Sprite-Variant - 3

remember to be vague in shape if possible as this will be used for any given enemy type

FOOTNOTE
NOTES

GREAT idea from @yooaudrey is to make a gravestone for this, could be in-place of or in-addtion-to depending on how the creation of the assets goes

LINKS
https://drive.google.com/drive/u/3/folders/1mNsCIBBRirYZiHeT5siVJBKyX3Cem4Lh
ASSETS

Player corpse = gravestone.png

absolutely fine with doing something else if we want
just did the first thing that came to mind
Enemy corpse variant 1 = skull-1.png
Enemy corpse variant 2 = skull-2.png


Anyone SVD RISC-V Architecture?

Is anyone using RISC-V? Yet*

I'm maintaining d1-pac. What do you want to ask?


ValueError: Shape must be rank 2 but is rank 3

Hi,
Thanks for answering my question here!
I'm building a two layered Bi-lstm with CRF for NER model, but I got the issues like this:

I'm not sure what is going on here. Hopefully, you can point it out to me. Thanks!

Hi,
I actually got the same issue here. I used to use
from keras_contrib.layers import CRF
but it was not there for tensorflow 2.x. Thank you so much for uploading you code. But I noticed that: if I have a dense layer with dimension of (None, 100, 20), then I pass this layer into the crf.  In this case, I would get a crf layer with a dimension of ((None, 100), (None, 100, 20)). And it will return the same issue as above. Because in the previous CRF function in keras_contrib, there is an attribute we need to assign with the number of tags and it's not here... which makes me even more confused...
max_len = 100
input_layer = Input(shape=(max_len,))
embedded_layer = Embedding(input_dim=5000 + 1, output_dim=20, input_length=max_len, mask_zero=True)(input_layer)
LSTM_layer = Bidirectional(LSTM(units=50, return_sequences=True, recurrent_dropout=0.1))(embedded_layer)
dense_layer = TimeDistributed(Dense(20, activation="relu"))(LSTM_layer)
crf = CRF(dtype='float32')
dense_layer = crf(dense_layer)
base_model = Model(input_layer, dense_layer)
final_model = ModelWithCRFLoss(base_model)
Please advise us how to solve it...
Thanks,
Guoyi

You can add a dense layer before the crf layer, whose dimension is the number of tag.  This is the same with the keras contrib when setting use_kernel to false. -------- 原始邮件 --------发件人： guoyi<EMAIL_ADDRESS>2020年12月29日周二 清晨5:35收件人： xuxingya/tf2crf<EMAIL_ADDRESS>Subscribed<EMAIL_ADDRESS>  题： Re: [xuxingya/tf2crf] ValueError: Shape must be rank 2 but is rank 3 (#27)
Hi,
I actually got the same issue here. I used to use
from keras_contrib.layers import CRF
but it was not there for tensorflow 2.x. Thank you so much for uploading you code. But I noticed that: if I have a dense layer with dimension of (None, 100, 20), then I pass this layer into the crf.  In this case, I would get a crf layer with a dimension of ((None, 100), (None, 100, 20)). And it will return the same issue as above. Because in the previous CRF function in keras_contrib, there is an attribute we need to assign with the number of tags and it's not here... which makes me even more confused...
max_len = 100
input_layer = Input(shape=(max_len,))
embedded_layer = Embedding(input_dim=5000 + 1, output_dim=20, input_length=max_len, mask_zero=True)(input_layer)
LSTM_layer = Bidirectional(LSTM(units=50, return_sequences=True, recurrent_dropout=0.1))(embedded_layer)
dense_layer = TimeDistributed(Dense(20, activation="relu"))(LSTM_layer)
crf = CRF(dtype='float32')
dense_layer = crf(dense_layer)
base_model = Model(input_layer, dense_layer)
final_model = ModelWithCRFLoss(base_model)
Please advise us how to solve it...
Thanks,
Guoyi
—You are receiving this because you are subscribed to this thread.Reply to this email directly, view it on GitHub, or unsubscribe.

You can add a dense layer before the crf layer, whose dimension is the number of tag.  This is the same with the keras contrib when setting use_kernel to false. -------- 原始邮件 --------发件人： guoyi<EMAIL_ADDRESS>2020年12月29日周二 清晨5:35收件人： xuxingya/tf2crf<EMAIL_ADDRESS>Subscribed<EMAIL_ADDRESS>题： Re: [xuxingya/tf2crf] ValueError: Shape must be rank 2 but is rank 3 (#27) Hi, I actually got the same issue here. I used to use from keras_contrib.layers import CRF but it was not there for tensorflow 2.x. Thank you so much for uploading you code. But I noticed that: if I have a dense layer with dimension of (None, 100, 20), then I pass this layer into the crf. In this case, I would get a crf layer with a dimension of ((None, 100), (None, 100, 20)). And it will return the same issue as above. Because in the previous CRF function in keras_contrib, there is an attribute we need to assign with the number of tags and it's not here... which makes me even more confused... max_len = 100 input_layer = Input(shape=(max_len,)) embedded_layer = Embedding(input_dim=5000 + 1, output_dim=20, input_length=max_len, mask_zero=True)(input_layer) LSTM_layer = Bidirectional(LSTM(units=50, return_sequences=True, recurrent_dropout=0.1))(embedded_layer) dense_layer = TimeDistributed(Dense(20, activation="relu"))(LSTM_layer) crf = CRF(dtype='float32') dense_layer = crf(dense_layer) base_model = Model(input_layer, dense_layer) final_model = ModelWithCRFLoss(base_model) Please advise us how to solve it... Thanks, Guoyi —You are receiving this because you are subscribed to this thread.Reply to this email directly, view it on GitHub, or unsubscribe.

Thanks for your reply!
But I still have not resolved this issue. The problem is, when I pass a layer with dimension of (none, 75, 17), which is my desired output format, I will get a wired dimension which seems like ((none, 75), (none, 75, 17)). Please see the code and model summary below.
input_layer = Input(shape=(max_len,))
embedded_layer = Embedding(input_dim=n_words + 1, output_dim=20,
                  input_length=max_len, mask_zero=True)(input_layer)  # 20-dim embedding
LSTM_layer = Bidirectional(LSTM(units=50, return_sequences=True,
                           recurrent_dropout=0.0))(embedded_layer)  # variational biLSTM
dense_layer = TimeDistributed(Dense(n_tags, activation="softmax"))(LSTM_layer)  # a dense layer as suggested by neuralNer
crf = CRF(dtype='float32')
out_layer = crf(dense_layer)
base_model = Model(input_layer, out_layer)
final_model = ModelWithCRFLoss(base_model)

base_model.compile(optimizer="adam", loss="categorical_crossentropy", metrics="accuracy")
base_model.summary()

Accurately there are four outputs. You can refer to the description of the
CRF layer. They are viterbi_sequence, inputs(the output of the previous
layer), sequence_lengths (mask), self.transitions (crf transmission
parameters). Usually you only need the first one. Sometimes you may want to
custom your own loss or accuracy, then other outputs are needed.
On Thu, Dec 31, 2020 at 1:06 AM guoyi<EMAIL_ADDRESS>wrote:

You can add a dense layer before the crf layer, whose dimension is the
number of tag.  This is the same with the keras contrib when setting
use_kernel to false. -------- 原始邮件 --------发件人： guoyi
<EMAIL_ADDRESS>2020年12月29日周二 清晨5:35收件人： xuxingya/tf2crf
<EMAIL_ADDRESS>Subscribed<EMAIL_ADDRESS>题：
Re: [xuxingya/tf2crf] ValueError: Shape must be rank 2 but is rank 3 (#27
https://github.com/xuxingya/tf2crf/issues/27) Hi, I actually got the
same issue here. I used to use from keras_contrib.layers import CRF but it
was not there for tensorflow 2.x. Thank you so much for uploading you code.
But I noticed that: if I have a dense layer with dimension of (None, 100,
20), then I pass this layer into the crf. In this case, I would get a crf
layer with a dimension of ((None, 100), (None, 100, 20)). And it will
return the same issue as above. Because in the previous CRF function in
keras_contrib, there is an attribute we need to assign with the number of
tags and it's not here... which makes me even more confused... max_len =
100 input_layer = Input(shape=(max_len,)) embedded_layer =
Embedding(input_dim=5000 + 1, output_dim=20, input_length=max_len,
mask_zero=True)(input_layer) LSTM_layer = Bidirectional(LSTM(units=50,
return_sequences=True, recurrent_dropout=0.1))(embedded_layer) dense_layer
= TimeDistributed(Dense(20, activation="relu"))(LSTM_layer) crf =
CRF(dtype='float32') dense_layer = crf(dense_layer) base_model =
Model(input_layer, dense_layer) final_model = ModelWithCRFLoss(base_model)
Please advise us how to solve it... Thanks, Guoyi —You are receiving this
because you are subscribed to this thread.Reply to this email directly,
view it on GitHub, or unsubscribe.
Thanks for your reply!
But I still have not resolved this issue. The problem is, when I pass a
layer with dimension of (none, 75, 17), which is my desired output format,
I will get a wired dimension which seems like ((none, 75), (none, 75, 17)).
Please see the code and model summary below.
input_layer = Input(shape=(max_len,))
embedded_layer = Embedding(input_dim=n_words + 1, output_dim=20,
              input_length=max_len, mask_zero=True)(input_layer)  # 20-dim embedding

LSTM_layer = Bidirectional(LSTM(units=50, return_sequences=True,
                       recurrent_dropout=0.0))(embedded_layer)  # variational biLSTM

dense_layer = TimeDistributed(Dense(n_tags, activation="softmax"))(LSTM_layer)  # a dense layer as suggested by neuralNer
crf = CRF(dtype='float32')
out_layer = crf(dense_layer)
base_model = Model(input_layer, out_layer)
final_model = ModelWithCRFLoss(base_model)
base_model.compile(optimizer="adam", loss="categorical_crossentropy", metrics="accuracy")
base_model.summary()
[image: image]
https://user-images.githubusercontent.com/29215691/103369148-5f0aea00-4a97-11eb-9126-d1c92a97c829.png
—
You are receiving this because you commented.
Reply to this email directly, view it on GitHub
https://github.com/xuxingya/tf2crf/issues/27#issuecomment-752692240, or
unsubscribe
https://github.com/notifications/unsubscribe-auth/ADFZVRBKNNZMBDKYLUJVKFDSXNMYRANCNFSM4VGALJDA
.

Hi,
Thanks for answering my question here!
I'm building a two layered Bi-lstm with CRF for NER model, but I got the issues like this:

I'm not sure what is going on here. Hopefully, you can point it out to me. Thanks!

I ran into the same issue today. The solution might be very easy.
Do you happen to  one hot encode your targets for training? Because you don't need to!
Simply have your target be a list of int.
I hope that solves your issue.
~Pol

Hi,
Thanks for answering my question here!
I'm building a two layered Bi-lstm with CRF for NER model, but I got the issues like this:

I'm not sure what is going on here. Hopefully, you can point it out to me. Thanks!

I ran into the same issue today. The solution might be very easy.
Do you happen to  one hot encode your targets for training? Because you don't need to!
Simply have your target be a list of int.
I hope that solves your issue.
~Pol

So anyone found a solution for it? Still struggling with the same problem

So anyone found a solution for it? Still struggling with the same problem

Check your input and y. The input to CRF layer should be (batch_size, sequence_len, tags_num), And the y true label should be (batch_size, sequence_len).

Thanks for your fast answer! My input should be fine, it is (BatchSize, 100, 3). 100 is the max_seq_length and 3 the tags. But my y are shaped in the same way (and one hot encoded). I have got almost the same model as user @GuoyiLi1991 with the same error message. There are 4 output tensors from the crf layer and I would say I need the second tensor by looking at it. How can I get the right tensor out of those 4?

But my y are shaped in the same way (and one hot encoded)

That is your problem right there.
You dont want to one-hot encode your labels.
It changes your shape for labels from (batchsize, sequence length) to (batchsize, sequence length, num_classes)
One-hot encoding your labels results in the shape mismatch in your error (ValueError: shape must be rank 2 but is rank 3)

Thank you, it finally worked! Unfortunately the f1-score got a lot worse, it was about 61% without CRF, with CRF it is only 57%. Does anyone have an idea why?

Isn't the model overfitting?
On Fri, Feb 5, 2021 at 3:04 AM RH1994R<EMAIL_ADDRESS>wrote:

Thank you, it finally worked! Unfortunately the f1-score got a lot worse,
it was about 61% without CRF, with CRF it is only 57%. Does anyone have an
idea why?
—
You are receiving this because you commented.
Reply to this email directly, view it on GitHub
https://github.com/xuxingya/tf2crf/issues/27#issuecomment-773536610, or
unsubscribe
https://github.com/notifications/unsubscribe-auth/ADFZVRC3AZMLXOMTMY7W7VDS5LVVFANCNFSM4VGALJDA
.

Why do you think the model is overfitting? Do you have any suggestions to avoid it? In my model I also included a dropout layer.

Do you calculate the F1 score on the test set? Because the F1 score is quite low, and usually CRF is helpful to NER task, I think there may other problem in your task.


Building a Rothko Painting - move syntax example from step 35 to step 34

Describe the Issue
It would make more sense for step 34 to have the filter syntax example, instead of it showing up in the next step.
Affected Page
https://www.freecodecamp.org/learn/2022/responsive-web-design/learn-the-css-box-model-by-building-a-rothko-painting/step-34
Your code
selector {
  filter: blur(3px);
}

Expected behavior
Explain and show the syntax.
Screenshots
No response
System

Device: [e.g. iPhone 6, Laptop]
OS: [e.g. iOS 14, Windows 10, Ubuntu 20.04]
Browser: [e.g. Chrome, Safari]
Version: [e.g. 22]

Additional context
https://forum.freecodecamp.org/t/rule-explanation-not-where-its-supposed-to-be-responsive-web-design-course/531328

Yes, that totally needs to be done
what about step 35? there I think the example is to remind people how to give same rules to multiple selectors. Should that be removed? double blur example?

Not sure if we need a selector list example as long as the hint text shows the selector. But I would like for the hint text to actually specify it as a selector list.

Hint You should have a .one, .two selector list.